[ENG-11880] Fixed missed email sends - #11912
Open
ihorsokhanexoft wants to merge 3 commits into
Open
ihorsokhanexoft wants to merge 3 commits into
ihorsokhanexoft wants to merge 3 commits into
Conversation
ihorsokhanexoft
force-pushed
the
fix/ENG-11880
branch
from
September 14, 2026 16:56
e4f5014 to
d4007fa
Compare
adlius
requested changes
Sep 18, 2026
| self.registration_approval.add_authorizer(admin, node=node) | ||
| self.registration_approval.save() # Save approval's approval_state | ||
| try: | ||
| self.registration_approval.ask(admins) |
Collaborator
There was a problem hiding this comment.
- So if we
ask()here and inarchive_success()we ask again, doesn't that mean the user will receive two identical emails of the same notification? - If we send the notification here, that means it is possible that the user will approve the registration before archiving is done. What happens then if archiving fails?
ihorsokhanexoft
force-pushed
the
fix/ENG-11880
branch
2 times, most recently
from
September 30, 2026 05:59
b96c7f6 to
3103fc3
Compare
ihorsokhanexoft
force-pushed
the
fix/ENG-11880
branch
from
September 30, 2026 10:33
714eb36 to
95b3c61
Compare
brianjgeiger
changed the base branch from
feature/pbs-26-18
to
feature/pbs-26-19
October 1, 2026 12:37
brianjgeiger
approved these changes
Oct 1, 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.
Ticket
https://openscience.atlassian.net/browse/ENG-11880
Purpose
Initial approval emails are not sent for usual and embargoed registrations
node_pending_embargo_adminandnode_pending_registration_adminemails are not sent.Changes
ACTUAL APPROACH:
Use retry to avoid race condition
PREVIOUS APPROACH:
According to sentry, we have multiple different issues with the archiving process. This PR fixes the error that caused
NoneType.rootattribute access issue.Two changes made:
[archive_addon, make_copy_request]tasks so that we follow the initial fix that caused this issue: waterbutler call must be made after addons are archived. So this group is run as a part of the whole archiving flowhttps://sentry3.cos.io/organizations/cos/discover/results/?cursor=0%3A100%3A0&field=title&field=release&field=environment&field=user.display&field=timestamp&field=celery_task_id&field=dist&name=AttributeError%3A+%27NoneType%27+object+has+no+attribute+%27root%27&project=2&query=issue%3APROD-OSF-BE-5Z8D&sort=-timestamp&statsPeriod=90d&yAxis=count%28%29
For the reported registration
my9kp, there is the same issue (guid saved in Additional Data section) that caused successful archiving but no emails sent.https://sentry3.cos.io/organizations/cos/issues/214086/events/b9d4781d876e4483a5f3c747ef7e1b0d/?project=2
Despite the error was found for the reported registration (used registration creation date to find the following issue in sentry), I was not able to find the same sentry error for the other registrations
Side notes
Even though this change will fix one bug with the archiving process, sentry says there are a few more issues with archiving that potentially can lead to failed registration archiving, so my recommendations are:
Additional Datasection that makes it difficult to find these errors as per sentry docs additional data is not indexed, thus cannot be found via sentry search.