#8235 closed defect (fixed)
Submitting a workflow state after another user has set it results in an error.
Reported by: | verm | Owned by: | Eli Carter |
---|---|---|---|
Priority: | normal | Milestone: | 0.12 |
Component: | ticket system | Version: | devel |
Severity: | normal | Keywords: | workflow |
Cc: | kirean@…, osimons | Branch: | |
Release Notes: | |||
API Changes: | |||
Internal Changes: |
Description
I was trying to reopen a ticket when i got the error:
Invalid action "reopen"
Turns out when I opened the page, someone else had already set the status to reopened. This is the error I got when I tried to submit my request.
The error message should either be removed and do the right thing or be more informative ie. "someone else has already set the ticket status to XXX"
Attachments (2)
Change History (14)
comment:1 by , 16 years ago
comment:3 by , 16 years ago
I'm using version 0.11.2 and experience same problem. I'm trying to reopen an existing ticket, but unable to do so, because of a strange error message
Invalid action "reopen"
comment:4 by , 16 years ago
I've also encountered the same situation. Two people opened up a ticket. One changed the status and the other tried later to use an action that wasn't allowed in that new state.
comment:5 by , 16 years ago
Cc: | added |
---|
comment:6 by , 16 years ago
Keywords: | workflow added |
---|---|
Milestone: | → 0.11.6 |
comment:7 by , 15 years ago
Cc: | added |
---|
Having just worked through the ticket update code for th:XmlRpcPlugin, this can be fixed by checking the timestamp on update requests before digging into the specifics of the request. Should be a simple matter of moving the timestamp-checking-lines further up in the validation code.
comment:8 by , 15 years ago
It may not be possible to "do the right thing" when the end state is the same; ticket actions may have side-effects beyond setting the ticket state and those may differ depending on the user doing the submit.
comment:9 by , 15 years ago
The approach seems to work. However, the same effect can be achieved with a simpler patch. It just replaces the part where a TracError
is raised with a warning. _validate_ticket()
then in turn adds a message about "ticket modified by someone else".
Also, the reason why the <pre>
tag looses its newlines is because it has the style white-space: normal
(see trac.css). Adding a <br/>
fixes that.
comment:10 by , 15 years ago
Milestone: | next-minor-0.12.x → 0.12 |
---|---|
Owner: | set to |
comment:11 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Second patch applied in [9443].
Which version of Trac were you using?