Skip to content

ref(repositories): Simplify ProjectRepoLink serializer and make url better#115826

Merged
wedamija merged 2 commits into
masterfrom
danf/fix-repo-link-serializer
May 19, 2026
Merged

ref(repositories): Simplify ProjectRepoLink serializer and make url better#115826
wedamija merged 2 commits into
masterfrom
danf/fix-repo-link-serializer

Conversation

@wedamija
Copy link
Copy Markdown
Member

Use validated_data["repositoryId"] in create() instead of storing self.repository as side-effect state during validation. The existence check uses .exists() instead of .get() since we only need the ID.

Also updates the url of the api to remove the -link

@wedamija wedamija requested a review from a team May 19, 2026 18:01
@wedamija wedamija requested review from a team as code owners May 19, 2026 18:01
@github-actions github-actions Bot added the Scope: Backend Automatically applied to PRs that change backend components label May 19, 2026
Comment thread src/sentry/api/urls.py Outdated
@getsantry getsantry Bot requested a review from a team as a code owner May 19, 2026 18:03
@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label May 19, 2026
@github-actions
Copy link
Copy Markdown
Contributor

🚨 Warning: This pull request contains Frontend and Backend changes!

It's discouraged to make changes to Sentry's Frontend and Backend in a single pull request. The Frontend and Backend are not atomically deployed. If the changes are interdependent of each other, they must be separated into two pull requests and be made forward or backwards compatible, such that the Backend or Frontend can be safely deployed independently.

Have questions? Please ask in the #discuss-dev-infra channel.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 19, 2026

📊 Type Coverage Diff

✅ No new type safety issues introduced. Coverage: 93.56%

@wedamija wedamija force-pushed the danf/fix-repo-link-serializer branch from 919f89c to 1b6cc86 Compare May 19, 2026 18:06
Use validated_data["repositoryId"] in create() instead of storing
self.repository as side-effect state during validation. The existence
check uses .exists() instead of .get() since we only need the ID.

Co-Authored-By: Claude Opus 4 <noreply@anthropic.com>
@wedamija wedamija force-pushed the danf/fix-repo-link-serializer branch from 1b6cc86 to 40d99f3 Compare May 19, 2026 18:08
@wedamija wedamija enabled auto-merge (squash) May 19, 2026 18:09
@wedamija wedamija merged commit 75fbb62 into master May 19, 2026
63 checks passed
@wedamija wedamija deleted the danf/fix-repo-link-serializer branch May 19, 2026 18:25
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 Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants