Open leplatrem opened 2 months ago
Expanding this a bit more, in this scenario I think we want the workflow to be:
Possible comment format to Jira:
Attachment added to bugzilla ticket.
{attachment_file_name} - as a link to the attachment
{attachment_description}
Edited to remove part of step four based on comments below.
and update ticket to in-review if it's in a status less than in-review
I would leave this part to Jira automation for now. We also have #249
and update ticket to in-review if it's in a status less than in-review
I would leave this part to Jira automation for now. We also have #249
Yep, I would agree that Jira automation should be easily able to take care of this with better data in the comment. That's also something that's very project/workflow specific so this would also allow teams to decide if this is something they want and how exactly to act on it as needed.
The change in #997 removed the only rudimentary way to put things in review via automation even though it wasn't ideal. Is there any ETA on being able to provide the details of Phabricator attachments?
We haven't really planned anything about this.
Since #997 seems to be a regression for you, I propose that we cover your use-case with a minimal code change.
I enabled attachment
events on JBI non prod and could obtain:
event: {
action: "create"
changes: null
routing_key: "attachment.create"
target: "attachment"
time: "datetime.datetime(2024, 6, 19, 13, 53, 29, tzinfo=TzInfo(UTC))"
user: {
id: 672219
login: "phab-bot@bmo.tld"
real_name: "Phabricator Automation"
}
}
We don't have enough information in the event to display the name of the attachment, but at least we could post a comment that could look like: phab-bot@bmo.tld created attachment
. This would be trivial and I will implement it now :) But for a better version that pulls attachments information from the bug to post a smarter comment, I can't tell you when it will be done
On Bugzilla:
On Jira:
Event payload received from Bugzilla seems to be:
See https://bugzilla-dev.allizom.org/page.cgi?id=webhooks.html
See #154 #249