Skip to content

fix(member merge): API updates for frontend #96709

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

Merged
merged 4 commits into from
Jul 31, 2025

Conversation

mifu67
Copy link
Contributor

@mifu67 mifu67 commented Jul 29, 2025

  • Use slug instead of org name
  • Use camel case instead of snake case for parameters
  • Return serialized merged user in POST request (so we can update query data)
  • Use set instead of list for orgs, because users whose accounts have been previously merged sometimes have multiple org member objects for the same org. This might just be temporary, but in any case a set is not worse than a list ¯\_(ツ)_/¯

@mifu67 mifu67 requested review from a team as code owners July 29, 2025 22:24
@github-actions github-actions bot added the Scope: Backend Automatically applied to PRs that change backend components label Jul 29, 2025
cursor[bot]

This comment was marked as outdated.

@@ -14,9 +14,9 @@


class AuthMergeUserAccountsValidator(serializers.Serializer):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can make AuthMergeUserAccountsValidator subclass CamelSnakeSerializer and keep the snake case here, we like snake case on the backend

Copy link

codecov bot commented Jul 31, 2025

Codecov Report

❌ Patch coverage is 66.66667% with 3 lines in your changes missing coverage. Please review.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
src/sentry/users/api/serializers/user.py 50.00% 3 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           master   #96709       +/-   ##
===========================================
+ Coverage   61.21%   80.06%   +18.84%     
===========================================
  Files        8505     8484       -21     
  Lines      374455   379694     +5239     
  Branches    24301    24179      -122     
===========================================
+ Hits       229230   303999    +74769     
+ Misses     142732    75318    -67414     
+ Partials     2493      377     -2116     

@mifu67 mifu67 merged commit 067082b into master Jul 31, 2025
65 checks passed
@mifu67 mifu67 deleted the mifu67/member-merge/api-updates branch July 31, 2025 22:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Scope: Backend Automatically applied to PRs that change backend components
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants