Topfile-checking pre-commit hook can't deal with trying to reopen a different ticket
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Twisted/Trac Integration |
New
|
Low
|
Unassigned |
Bug Description
When reviewing #2053, I had an issue where the topfile claimed this was 2503. I accidentally put that as the ticket this fixed in the commit message.
This lead to the following confusing message when trying to undo that commit:
trunk ❯ svn status ⏎
A + twisted/
D twisted/
trunk ❯ svn commit -m "Unmerge remove-
Reopens: #2053
This branch accidentally had the wrong topfile.
"
Adding twisted/
Deleting twisted/
svn: E165001: Commit failed (details follow):
svn: E165001: Commit blocked by pre-commit hook (exit code 1) with output:
Must remove a <ticket>
This resulted in having to reopen #2503 (the ticket that was accidentally closed by the commit message, even though it was already closed), and then manually setting it back to fixed.
I'm not entirely sure what the resolution for this is. It does appear that at least the error message could be better. Since this apparently hasn't happened before in Twisted's history (or at least as far as JP can recall), this is probably not very high priority, especially since there is a workaround.
So, I think the real issue is when you try to Reopen a ticket that is different from the name of the topfile that you're trying to remove in that commit.
There's a good argument to be made for *NOT* fixing that. Just as I made the mistake of closing the wrong ticket, someone might try to reopen the wrong ticket!
So perhaps just the message should be fixed and a reference to the workaround?