Error in Validation Transition's attachments

Issue #181 resolved
Adolfo Casari created an issue

Hi Fidel,

There is a bug with this validation in version 2.2.1_beta_1 :

If field Transition's attachments matches the following parsed regular expression: (.PUD.). Message to show when validation fails: "Debe incluir documento PUD.".

The transition completes but the attachment is not show in the issue and it is not recorded in the history.

If remove that validation, the attachment is show and recorded in history.

Comments (11)

  1. Adolfo Casari reporter

    I see this error in the logs:

    2015-10-20 16:35:03,247 http-bio-8080-exec-10 WARN rcerda 995x7184x1 106pqp9 10.0.2.2 /secure/CommentAssignIssue.jspa [jira.issue.fields.AttachmentSystemField] There were errors while converting temporary attachments: AttachmentError{logMessage='An error occurred: You can not create attachments as the issue is in a non-editable workflow state.', localizedMessage='You can not create attachments as the issue is in a non-editable workflow state.', filename='', reason=VALIDATION_FAILED, exception=none()}

    The transition goes from In Progress to Closed (here the edit workflow property is set to false).

  2. Fidel Castro Armario repo owner

    Hi Adolfo,

    I have tried to reproduce the problem (JIRA 6.4.12 and JWT 2.2.1_beta_1), but in my case all is working correctly. I think that usage of "Transition's attachments" virtual field in post-function might have something to do with the problem.

    Can you please attach a screenshot of post-functions in that transition?

    Thanks,

    Fidel

  3. Adolfo Casari reporter

    I installed 2.1.35 and it works OK. Tried workflow-toolbox-2.1.37_beta_1 and fails. I can't go back to 2.1.35 since there was an issue with reindexing the parent in that version (issue Issue #178)

  4. Fidel Castro Armario repo owner

    I have investigated the problem, and have realized that it's a bug of JIRA not JIRA Workflow Toolbox. Affected versions seems to be JIRA 6.4.x to 7.0.0. Version JIRA 6.3.15 works fine.

    Bug Description: If you try to attach a file in transition screen when the destination workflow step has property jira.issue.editable=false, then file won't be actually attached. Although GUI won't show any error message, in the log file you will find something like this:

    http-nio-8080-exec-16 WARN admin 770x585x1 1l07jej 0:0:0:0:0:0:0:1 /secure/CommentAssignIssue.jspa [c.a.j.issue.fields.AttachmentSystemField] There were errors while converting temporary attachments: AttachmentError{logMessage='An error occurred: You can not create attachments as the issue is in a non-editable workflow state.', localizedMessage='You can not create attachments as the issue is in a non-editable workflow state.', filename='', reason=VALIDATION_FAILED, exception=none()}

    This problem happens always, regardless of there are validations in the transition.

  5. Fidel Castro Armario repo owner

    Because Jira 6.3.x isn't affected by the bug. You can try JWT 2.1.37_beta_1 or 2.2_beta_1with that version, and will work correctly.

  6. Log in to comment