<feed xmlns='http://www.w3.org/2005/Atom'>
<title>notmuch/bindings/python-cffi/notmuch2, branch 0.33.1</title>
<subtitle>thread-based email index, search, and tagging</subtitle>
<id>https://git.notmuchmail.org/git/notmuch/atom?h=0.33.1</id>
<link rel='self' href='https://git.notmuchmail.org/git/notmuch/atom?h=0.33.1'/>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/'/>
<updated>2021-03-27T12:26:14Z</updated>
<entry>
<title>lib: add NOTMUCH_STATUS_NO_DATABASE</title>
<updated>2021-03-27T12:26:14Z</updated>
<author>
<name>David Bremner</name>
<email>david@tethera.net</email>
</author>
<published>2021-02-23T19:56:47Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=2e39ce6eb5d5e5ae2a2a4ed419190003f47e566e'/>
<id>urn:sha1:2e39ce6eb5d5e5ae2a2a4ed419190003f47e566e</id>
<content type='text'>
This will allow more precise return values from various open related functions.
</content>
</entry>
<entry>
<title>lib: add NOTMUCH_STATUS_DATABASE_EXISTS</title>
<updated>2021-02-06T23:46:46Z</updated>
<author>
<name>David Bremner</name>
<email>david@tethera.net</email>
</author>
<published>2021-01-03T12:50:12Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=55f5e87096fda96280ccc4b191393c7e59b4df57'/>
<id>urn:sha1:55f5e87096fda96280ccc4b191393c7e59b4df57</id>
<content type='text'>
It is desirable to distinguish between attempting to create a database
that already exists, and more fatal errors like permission problems.
</content>
</entry>
<entry>
<title>lib: add NOTMUCH_STATUS_NO_CONFIG</title>
<updated>2021-02-06T23:43:11Z</updated>
<author>
<name>David Bremner</name>
<email>david@tethera.net</email>
</author>
<published>2021-01-03T12:30:46Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=eea258c0c9386a5eecae48a98b552113a3584a7d'/>
<id>urn:sha1:eea258c0c9386a5eecae48a98b552113a3584a7d</id>
<content type='text'>
This will allow client code to provide more meaningful diagnostics. In
particular it will enable "notmuch new" to continue suggsting the user
run "notmuch setup" to create a config after "notmuch new" is
transitioned to the new  configuration framework.
</content>
</entry>
<entry>
<title>bindings/notmuch2: add missing crypto error status codes</title>
<updated>2021-02-06T23:37:50Z</updated>
<author>
<name>David Bremner</name>
<email>david@tethera.net</email>
</author>
<published>2021-01-03T01:50:24Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=baf1202fbc3b27790d0ff347e29589188d5644a5'/>
<id>urn:sha1:baf1202fbc3b27790d0ff347e29589188d5644a5</id>
<content type='text'>
These are needed so that the later codes line up numerically.
</content>
</entry>
<entry>
<title>python/notmuch2: fix exclude tag handling</title>
<updated>2020-12-25T15:25:25Z</updated>
<author>
<name>Johannes Larsen</name>
<email>mail@johslarsen.net</email>
</author>
<published>2020-12-25T15:21:45Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=f01f6405c962e27de52eb777ac3f19ee655b71ba'/>
<id>urn:sha1:f01f6405c962e27de52eb777ac3f19ee655b71ba</id>
<content type='text'>
A typo in Database._create_query lost the exclude_tag names during the
string to utf-8 conversion.

Amended by DB: fixed patch format and updated commit message.
</content>
</entry>
<entry>
<title>Fix typos</title>
<updated>2020-08-10T00:14:36Z</updated>
<author>
<name>Jonas Bernoulli</name>
<email>jonas@bernoul.li</email>
</author>
<published>2020-08-08T11:49:55Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=6c84dee53193a78cf797b44d3febcc14488ea6b1'/>
<id>urn:sha1:6c84dee53193a78cf797b44d3febcc14488ea6b1</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Support aborting the atomic context</title>
<updated>2020-06-16T11:17:39Z</updated>
<author>
<name>Floris Bruynooghe</name>
<email>flub@devork.be</email>
</author>
<published>2020-06-14T15:23:19Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=776a54a0e437651abd69a03b9f7d591ea1f992cb'/>
<id>urn:sha1:776a54a0e437651abd69a03b9f7d591ea1f992cb</id>
<content type='text'>
Since it is possible to use an atomic context to abort a number of
changes support this usage.  Because the only way to actually abort
the transaction is to close the database this must also do so.

Amended by db: Note the limitation requiring close is a limitation of
the underlying notmuch API, which should be fixed in a future notmuch
release.
</content>
</entry>
<entry>
<title>Make messages returned by Thread objects owned</title>
<updated>2020-06-16T11:02:02Z</updated>
<author>
<name>Floris Bruynooghe</name>
<email>flub@devork.be</email>
</author>
<published>2020-06-15T20:58:50Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=2d895a0119b423b117d10e890c9e0eb5d2a9cdf8'/>
<id>urn:sha1:2d895a0119b423b117d10e890c9e0eb5d2a9cdf8</id>
<content type='text'>
This reverses the logic of StandaloneMessage to instead create a
OwnedMessage.  Only the Thread class allows retrieving messages more
then once so it can explicitly create such messages.

The added test fails with SIGABRT without the fix for the message
re-use in threads being present.
</content>
</entry>
<entry>
<title>python/notmuch2: do not destroy messages owned by a query</title>
<updated>2020-06-16T11:02:02Z</updated>
<author>
<name>Anton Khirnov</name>
<email>anton@khirnov.net</email>
</author>
<published>2020-06-15T20:58:49Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=131757907907380213b32934d9e73cec942ace43'/>
<id>urn:sha1:131757907907380213b32934d9e73cec942ace43</id>
<content type='text'>
Any messages retrieved from a query - either directly via
search_messages() or indirectly via thread objects - are owned by that
query. Retrieving the same message (i.e. corresponding to the same
message ID / database object) several times will always yield the same
C object.

The caller is allowed to destroy message objects owned by a query before
the query itself - which can save memory for long-lived queries.
However, that message must then never be retrieved again from that
query.

The python-notmuch2 bindings will currently destroy every message object
in Message._destroy(), which will lead to an invalid free if the same
message is then retrieved again. E.g. the following python program leads
to libtalloc abort()ing:

import notmuch2
db   = notmuch2.Database(mode = notmuch2.Database.MODE.READ_ONLY)
t    = next(db.threads('*'))
msgs = list(zip(t.toplevel(), t.toplevel()))
msgs = list(zip(t.toplevel(), t.toplevel()))

Fix this issue by creating a subclass of Message, which is used for
"standalone" message which have to be freed by the caller. Message class
is then used only for messages descended from a query, which do not need
to be freed by the caller.
</content>
</entry>
<entry>
<title>python config access: fix style and KeyError bug</title>
<updated>2020-06-16T00:50:03Z</updated>
<author>
<name>Floris Bruynooghe</name>
<email>flub@devork.be</email>
</author>
<published>2020-06-15T21:55:53Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=1bca41698a03980b701558fb5c481ef0a340460d'/>
<id>urn:sha1:1bca41698a03980b701558fb5c481ef0a340460d</id>
<content type='text'>
This fixes some minor style/pep8 things and adds tests for the new
config support.  Also fixes a bug where KeyError was never raised
on a missing key.
</content>
</entry>
</feed>
