Closed Bug 1667877 Opened 5 years ago Closed 5 years ago

Phabricator emails: when a freshly-created secure revision doesn't have a bug, an exception is thrown.

Categories

(Conduit :: Phabricator, defect)

defect

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mhentges, Assigned: mhentges)

References

Details

Attachments

(2 files)

Assignee: nobody → mhentges
Status: NEW → ASSIGNED

Hmm, there was an assumption made that all secure revisions would have an associated bug.
However, each revision is marked as "secure" for a few seconds after creation until phab-bot confirms that it's able to be public.
If an email-generating event happens in this time frame (e.g.: for this revision in which necko-reviewers was added by Herald), then phab-emails has to handle a secure revision without a bug - which it's unprepared for.

Blocks: 1667229
Summary: Phabricator emails: "raw_bug" isn't set, sometimes → Phabricator emails: when a freshly-created secure revision doesn't have a bug, an exception is thrown.

If an email-generating event happens in this time frame (e.g.: for this revision in which necko-reviewers was added by Herald), then phab-emails has to handle a secure revision without a bug - which it's unprepared for.

Thinking about this more, revisions are marked as "draft" when they're first created. Once processed by phab-bot (removing the "secure" property if they're public), they're moved out of "draft" state.
We shouldn't be sending emails for events that happen while the revision is still a "draft".

When revisions are first created, they're marked as "draft" while
phab-bot processes them. Since there can be unexpected state at that
moment (revisions without bugs are temporarily marked as "secure"),
it's cleaner to wait until the processing finished. At that point, send
a single "revision created" email with all relevant information.

Depends on D91635

Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: