-
Notifications
You must be signed in to change notification settings - Fork 66
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
Improve canceled subs handling #3148
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #3148 +/- ##
==========================================
+ Coverage 39.82% 40.31% +0.49%
==========================================
Files 582 582
Lines 21247 21356 +109
Branches 5103 5144 +41
==========================================
+ Hits 8461 8610 +149
+ Misses 12786 12746 -40
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
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.
Approved with a couple of suggested tweaks!
Co-authored-by: Pez Cuckow <email@pezcuckow.com>
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.
Still 👍
@knolleary did you want to include this in the billing fix push to prod? It will need the merge conflicts fixing |
@hardillb no, need to revisit this before it merges. For another day. |
Description
This improves our handling around canceled stripe subscriptions.
We have seen a couple instances where subscription is canceled on stripe, but our local state thinks it is active.
This PR adds a check whenever we come to do billable work to resync our local status with the true stripe status. If we find the status has changed, and that it is now canceled, we suspend all team instances and log it.
It also:
billing.subscription.updated
audit-log event