fix(jiraonprem): stop resetting the priority on every update - #6755
Open
purisev wants to merge 2 commits into
Open
fix(jiraonprem): stop resetting the priority on every update#6755purisev wants to merge 2 commits into
purisev wants to merge 2 commits into
Conversation
_notify defaulted priority to Medium and passed it straight to __update_issue, which sets whatever it is given. So an update that only touched the summary, or added a label, also rewrote the ticket's priority, without the workflow mentioning priority anywhere. On Data Center it can be worse than a silent change: priority is often absent from a project's edit screen, and then the whole update fails on a field nobody asked for. The cloud provider has no such default, so the same workflow behaved differently against the two Jiras. Default to None and let the existing truthiness check in __update_issue do the rest; creating an issue still falls back to Medium, which the create screen always accepts. Signed-off-by: Iurii Purisev <92510590+purisev@users.noreply.github.com>
This was referenced Sep 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
See #6751.
_notifydefaultspriorityto"Medium"and passes it to__update_issue, which writes the field for any truthy value. An update aboutthe summary rewrites the priority of a ticket somebody escalated by hand.
Fix
prioritydefaults toNoneand reaches__update_issueas it came, so theupdate writes the field only for a value the workflow named. The create path
passes
priority or "Medium", so a new issue keeps the same default it hastoday.
Tests
tests/test_jira_provider.pygrows to 12 tests, all passing: an update with nopriority leaves the field out of the request body, an update naming one sets it,
and a create with no priority still sends Medium.
Note on the other Jira PRs
#6752, #6753 and #6754 report three more gaps in the same two providers, each
with a PR of its own. The on-prem transitions one edits the same
_notifysignature line as this PR, so whichever of the two lands second needs a one line
resolution. Everything else between the four is additive.
Fixes #6751