txdbus icon indicating copy to clipboard operation
txdbus copied to clipboard

Matching rules are never removed from the bus

Open heftig opened this issue 10 years ago • 7 comments

DBusClientConnection's delMatch should remove rules from the bus by calling RemoveMatch with the original rule string. Otherwise, they can keep accumulating until the bus refuses to add any more rules.

heftig avatar Apr 07 '15 09:04 heftig

Fixed in 1.0.11. My testing on this was somewhat limited though, let me know if I botched the fix.

cocagne avatar Apr 07 '15 19:04 cocagne

Where is 1.0.11? The newest release in this repository is 1.0.6.

heftig avatar Apr 08 '15 07:04 heftig

Ah, in pypi. Would be nice if this repository were actually up-to-date with the packages. I would have actually noticed any new releases. I can't use the package because I need to maintain a local fork.

Anyway, my first attempt at implementing this ended up basically identical to your code. I've got a smarter version now which consolidates matches that construct the same rule string. The new callback gets added to the router, but another match is not added to the bus. I'll send a pull request once I've tested the code.

heftig avatar Apr 08 '15 07:04 heftig

That is, I could create a pull request if this repo were at least at version 1.0.11 for me to merge into.

heftig avatar Apr 08 '15 08:04 heftig

If you have a better implementation, please do send a pull request. The repository was indeed behind the released version but I'm not entirely sure why. I switched machines a few months ago and I may have screwed up my remotes when doing so. It should be fully up to date now though, thanks for pointing it out.

On Wed, Apr 8, 2015 at 3:01 AM, Jan Alexander Steffens < [email protected]> wrote:

That is, I could create a pull request if this repo were at least at version 1.0.11 for me to merge into.

— Reply to this email directly or view it on GitHub https://github.com/cocagne/txdbus/issues/26#issuecomment-90835921.

cocagne avatar Apr 08 '15 14:04 cocagne

Heftig,

Do you have an eta for making a pull request that includes your changes? I'd like to cut a new txdbus release soon to include an endian fix that was recently submitted but I'd also like to include your changes if possible.

Tom

cocagne avatar Apr 17 '15 15:04 cocagne

Sorry, I ran into a bit of trouble with ensuring that there is ever only one in-flight request for any match, so this is on the backburner now.

heftig avatar Apr 17 '15 15:04 heftig