-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HPCC4J-578 Migrate existing jirabot logic to new Jira environment #692
Conversation
@rpastrana please review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jpmcmu looks fine, just one question. If the empty transition map case is handled appropriately, let's go ahead and squash
.github/workflows/Jirabot.yml
Outdated
|
||
if transition != '': | ||
if transition != None and transition != '': |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's hard to tell, how's the transaction == None or '' case handled?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If transition == None or '' that indicates we don't need to make any transitions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understand what the conditions mean, I asked how that case is handled.
if the new table is empty, does that issue get logged anywhere?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah sorry I didn't understand your question. No, that issue wouldn't get logged anywhere, but if the table were empty or didn't have the specified status we would default to None. To your point it is probably a good idea to add a log message if we hit None, an empty string though should still be treated as a valid no-op
@rpastrana squashed |
@rpastrana Added an additional error message for the transition == None case |
|
||
issue = jira.issue(issue_name) | ||
result = 'Jirabot Action Result:\n' | ||
|
||
transitionMap = json.loads(os.environ['JIRA_ISSUE_TRANSITION_MAP']) | ||
if not isinstance(transitionMap, dict): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be logged.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added a log statement and squashed
- Updated Jirabot to work with current Jira and new Cloud Jira Signed-off-by: James McMullan [email protected]
Signed-off-by: James McMullan [email protected]
Type of change:
Checklist:
Testing: