Skip to content
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

fix: registration post persist hooks should not be cancelable #4148

Merged
merged 1 commit into from
Oct 9, 2024

Conversation

zepatrik
Copy link
Member

@zepatrik zepatrik commented Oct 8, 2024

Related issue(s)

When a request is canceled at the wrong point, it can lead to some hooks not being executed.
With this change we ignore context cancelation after the identity was created so that e.g. verification emails or webhooks will always be executed.

Checklist

  • I have read the contributing guidelines.
  • I have referenced an issue containing the design document if my change
    introduces a new feature.
  • I am following the
    contributing code guidelines.
  • I have read the security policy.
  • I confirm that this pull request does not address a security
    vulnerability. If this pull request addresses a security vulnerability, I
    confirm that I got the approval (please contact
    [email protected]) from the maintainers to push
    the changes.
  • I have added tests that prove my fix is effective or that my feature
    works.
  • I have added or changed the documentation.

Further Comments

IMO this is expected behavior so no docs changes should be required.

Copy link

codecov bot commented Oct 8, 2024

Codecov Report

Attention: Patch coverage is 80.00000% with 4 lines in your changes missing coverage. Please review.

Project coverage is 78.58%. Comparing base (629d867) to head (3fc5a4e).
Report is 6 commits behind head on master.

Files with missing lines Patch % Lines
selfservice/flow/registration/hook.go 80.00% 2 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4148      +/-   ##
==========================================
- Coverage   78.61%   78.58%   -0.04%     
==========================================
  Files         378      379       +1     
  Lines       26936    26989      +53     
==========================================
+ Hits        21177    21208      +31     
- Misses       4147     4169      +22     
  Partials     1612     1612              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@zepatrik zepatrik merged commit 18056a0 into master Oct 9, 2024
31 checks passed
@zepatrik zepatrik deleted the fix/registration/post-hooks-aborted branch October 9, 2024 12:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants