unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* difficulties with notmuch2 python bindings for alot
@ 2020-06-09 13:19 Daniel Kahn Gillmor
  2020-06-14 19:53 ` Floris Bruynooghe
  0 siblings, 1 reply; 4+ messages in thread
From: Daniel Kahn Gillmor @ 2020-06-09 13:19 UTC (permalink / raw)
  To: Notmuch Mail


[-- Attachment #1.1: Type: text/plain, Size: 495 bytes --]

Hi all--

I see over on github that alot is trying to port to the notmuch2
bindings, and having a few problems with it:

 https://github.com/pazz/alot/pull/1511

alot is an important consumer of the notmuch python bindings, and it
would be really great to see them successfully transition to the
notmuch2 module.

Floris, if you (or anyone else with this particular knowledge) has a
chance to take a look and help them sort out the remaining issues, that
would be much appreciated!

      --dkg

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: difficulties with notmuch2 python bindings for alot
  2020-06-09 13:19 difficulties with notmuch2 python bindings for alot Daniel Kahn Gillmor
@ 2020-06-14 19:53 ` Floris Bruynooghe
  2020-06-14 22:44   ` David Bremner
  0 siblings, 1 reply; 4+ messages in thread
From: Floris Bruynooghe @ 2020-06-14 19:53 UTC (permalink / raw)
  To: Daniel Kahn Gillmor, Notmuch Mail

Hi Daniel,

On Tue 09 Jun 2020 at 09:19 -0400, Daniel Kahn Gillmor wrote:
> I see over on github that alot is trying to port to the notmuch2
> bindings, and having a few problems with it:
>
>  https://github.com/pazz/alot/pull/1511
>
> alot is an important consumer of the notmuch python bindings, and it
> would be really great to see them successfully transition to the
> notmuch2 module.
>
> Floris, if you (or anyone else with this particular knowledge) has a
> chance to take a look and help them sort out the remaining issues, that
> would be much appreciated!

Thanks for the pointer, I've pinged the issue offering help with the
bindings and had a look through the existing things they discussed.

One thing that they encountered and don't yet understand is that they
reported issues with leaking filedescriptors.  They used the bindings in
a way where I expect it to only call notmuch_database_destroy() when
they are done with it.  From reading notmuch.h I think that's correct
and there's no need to call notmuch_database_close() first.  Yet someone
reported that explicitly calling close helped.  Is the assumption I made
of only calling destroy correct?

Cheers,
Floris

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: difficulties with notmuch2 python bindings for alot
  2020-06-14 19:53 ` Floris Bruynooghe
@ 2020-06-14 22:44   ` David Bremner
  2020-06-15 19:42     ` Floris Bruynooghe
  0 siblings, 1 reply; 4+ messages in thread
From: David Bremner @ 2020-06-14 22:44 UTC (permalink / raw)
  To: Floris Bruynooghe, Daniel Kahn Gillmor, Notmuch Mail

Floris Bruynooghe <flub@devork.be> writes:

> One thing that they encountered and don't yet understand is that they
> reported issues with leaking filedescriptors.  They used the bindings in
> a way where I expect it to only call notmuch_database_destroy() when
> they are done with it.  From reading notmuch.h I think that's correct
> and there's no need to call notmuch_database_close() first.  Yet someone
> reported that explicitly calling close helped.  Is the assumption I made
> of only calling destroy correct?

The first thing destroy does is call close. My read of the
notmuch_database_close code is that it is idempotent (calling multiple
times does not change anything).

d

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: difficulties with notmuch2 python bindings for alot
  2020-06-14 22:44   ` David Bremner
@ 2020-06-15 19:42     ` Floris Bruynooghe
  0 siblings, 0 replies; 4+ messages in thread
From: Floris Bruynooghe @ 2020-06-15 19:42 UTC (permalink / raw)
  To: David Bremner, Daniel Kahn Gillmor, Notmuch Mail

On Sun 14 Jun 2020 at 19:44 -0300, David Bremner wrote:

> Floris Bruynooghe <flub@devork.be> writes:
>
>> One thing that they encountered and don't yet understand is that they
>> reported issues with leaking filedescriptors.  They used the bindings in
>> a way where I expect it to only call notmuch_database_destroy() when
>> they are done with it.  From reading notmuch.h I think that's correct
>> and there's no need to call notmuch_database_close() first.  Yet someone
>> reported that explicitly calling close helped.  Is the assumption I made
>> of only calling destroy correct?
>
> The first thing destroy does is call close. My read of the
> notmuch_database_close code is that it is idempotent (calling multiple
> times does not change anything).

Thanks for confirming, so that should be fine.

Cheers,
Floris

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-06-15 19:43 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-09 13:19 difficulties with notmuch2 python bindings for alot Daniel Kahn Gillmor
2020-06-14 19:53 ` Floris Bruynooghe
2020-06-14 22:44   ` David Bremner
2020-06-15 19:42     ` Floris Bruynooghe

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).