GothenburgBitFactory / bugwarrior

Pull github, bitbucket, and trac issues into taskwarrior
http://pypi.python.org/pypi/bugwarrior
GNU General Public License v3.0
736 stars 209 forks source link

find UUID in completed only after pending/waiting #796

Closed jspricke closed 3 years ago

jspricke commented 3 years ago

9fe6215 added completed to the search to allow reopening tasks but the issue could have been completed multiple times before resulting in an MultipleMatches exception. This change only considers completed tasks if the issue is not in the pending/waiting set and also arbitrarily returns the first found result.

ryneeverett commented 3 years ago

While I find your PR more readable I'm leaning towards #797 for performance reasons. If the extra taskwarrior query only occurred on edge cases I would consider that acceptable but it looks like as it current stands there will be an extra query for every new issue before adding it to the database. Thoughts?

jspricke commented 3 years ago

I agree that #797 is probably the better fix.