Opened on 03/18/2014 at 11:17:22 AM
Last modified on 09/30/2019 at 10:30:35 AM
#169 new change
[trac] referencing blocked/blocking issues should be semi-automated
Reported by: | philll | Assignee: | |
---|---|---|---|
Priority: | P3 | Milestone: | |
Module: | Infrastructure | Keywords: | |
Cc: | Blocked By: | ||
Blocking: | Platform: | ||
Ready: | yes | Confidential: | no |
Tester: | Verified working: | no | |
Review URL(s): |
Description
Background
We are currently using the MasterTicketsPlugin to show dependencies between issues via the blocking/blocked by fields. As one issue can have many dependent other issues, querying the ones to depend on another is hard, as you need to add all possibilities of the issues ID being included in the field: Alone, comma before, comma after, surrounded by commas, with hash tag and without.
What to change
Implement some semi-automated solution the query the issues being listed as blocking or blockedby by giving one or more issue IDs only without having to add all the possible string versions.
Attachments (0)
Change History (5)
comment:1 Changed on 03/18/2014 at 11:18:48 AM by philll
comment:2 Changed on 03/18/2014 at 11:34:06 AM by trev
- Priority changed from Unknown to P3
- Ready set
This should be possible by implementing a plugin that will extend TicketQueryMacro and give it a new name, e.g. [[Blockers(123,...)]]. The expand_macro method can process the first argument (issue number) and replace it by blocking=123,or,blocking^=123\,,or,blocking$=\,123,or,blocking~=\,123\, (that's the exact incantation necessary to cover all the scenarios). It can then redirect all the work as well as processing the other parameters to the superclass.
comment:3 Changed on 03/18/2014 at 01:46:22 PM by philll
yep
comment:4 Changed on 05/12/2014 at 03:27:42 PM by philll
We could use this change instead: http://trac.edgewall.org/ticket/10871
comment:5 Changed on 05/19/2014 at 09:16:41 AM by philll
Apparently, querying list type fields like keywords works differently than expected, such that you cannot use the "is" operator to find single keywords in a list of an issue, but rather need to use the "contains" operator, which then apparently again finds the search string even if included in a non-seperated way of a bigger string. Seems like we need to still create our own macro.
I took a look into TicketDepPlugin but ended up with the following exception when trying to create any new issue: