Edgewall Software
Modify

Opened 11 years ago

Closed 11 years ago

Last modified 10 years ago

#11622 closed enhancement (fixed)

Allow full ticket ref syntax in the CommitTicketUpdater

Reported by: Lele Gaifax Owned by: Ryan J Ollos
Priority: normal Milestone: 1.1.2
Component: ticket system Version:
Severity: normal Keywords: CommitTicketUpdater
Cc: Branch:
Release Notes:

CommitTicketUpdater recognizes long-form ticket references with a trailing #comment:N or #comment:description in the token.

API Changes:
Internal Changes:

Description

Currently it does not handle the full TracLinks syntax: ticket:10#comment:2.

Could something like this patch be applied?

Attachments (0)

Change History (5)

comment:1 by Ryan J Ollos, 11 years ago

Keywords: CommitTicketUpdater added
Milestone: 1.1.2
Owner: set to Ryan J Ollos
Status: newassigned

I don't think it is intended that all forms of the ticket TracLinks be allowed as ticket reference tokens. Supporting the comment:2:ticket:10 TracLink form would appear to require difficult changes. However I think we can add support for the ticket:10#comment:2 form.

The ticket:10#comment:2 form works when referencing only a single ticket, which I don't think was intentional, but rather just a consequence of how the matching is implemented. The comment TracLink doesn't work correctly when multiple tickets are referenced, for example: ticket:10#comment:2 and ticket:11#comment2 - a reference to only the first ticket is inserted.

Proposed changes in log:rjollos.git:t11622.

comment:2 by lelit, 11 years ago

I see, and find it reasonable: I did not even know about the alternative ordered syntax.

Looking at your patch, what does ticket:10#comment:description do? Trying it out in the SandBox, it seems it addresses the description field of the ticket… and I fail to see a concrete use case for it (in the CommitTicketUpdater context, I mean): I needed support for ticket:10#comment:2 in cases when a previous commit closed the ticket, then the QA people reopened it because the fix was not enough, annotating the reason, and one more commit was needed.

in reply to:  2 comment:3 by Ryan J Ollos, 11 years ago

Replying to lelit:

I see, and find it reasonable: I did not even know about the alternative ordered syntax.

The syntaxes can be found at TracLinks#comment:links. It seems useful to align the syntaxes as much as possible.

comment:4 by Ryan J Ollos, 11 years ago

Release Notes: modified (diff)
Resolution: fixed
Status: assignedclosed

Committed to trunk in [12825].

comment:5 by Ryan J Ollos, 10 years ago

Release Notes: modified (diff)

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Ryan J Ollos.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Ryan J Ollos to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.