Defect #11283
Adding time to an issue where a custom field regexp doesn't match adds the time spent twice
| Status: | New | Start date: | ||
|---|---|---|---|---|
| Priority: | Normal | Due date: | ||
| Assignee: | - | % Done: | 0% | |
| Category: | - | |||
| Target version: | - | |||
| Affected version: | 2.0.3 | Resolution: | Cant reproduce |
Description
Adding time to an new issue where a custom field regexp (emailadress) doesn't match,
adds the time spent twice, when you correct the missing data in the "custom field" and resubmit the issue.
Associated revisions
Test that spent time should not be added when issue update fails (#11283).
History
#1 Updated by Jean-Philippe Lang 11 months ago
Adding time to an new issue
How do you do that? AFAIK, there's no way to enter a spent time when creating a new issue.
#2 Updated by Jean-Philippe Lang 11 months ago
- Resolution set to Cant reproduce
And I can't reproduce when adding time to an existing issue.
#3 Updated by Sepp _ 11 months ago
I was wrong, this was just the second step after creating the issue.
I just tried it a second time after upgrading to 2.0.3.
- Set
^[a-zA-Z0-9][\w\.-]*(?:[a-zA-Z0-9][a-zA-Z0-9_-]+\.)+[A-Za-z]{2,5};?.*$ as a Custom Field-Rexexp for validating Emailadresses - Create a new Issur
- Update the issue with a wrong emailadress and add hours to it.
- correct the emailadress and submit again: --> The hours are added twice.
#4 Updated by Jean-Philippe Lang 7 months ago
I still can't reproduce with 2.1 by following these steps, hours are saved only after the valid update.
I have also added a test in r10621 to make sure that spent time is not added when validation fails.