Skip to content

feat(seer): Pass PR assignment flag and GitHub username to Seer#112670

Draft
JoshFerge wants to merge 6 commits intomasterfrom
joshferge/feat/assign-prs-to-user-v2
Draft

feat(seer): Pass PR assignment flag and GitHub username to Seer#112670
JoshFerge wants to merge 6 commits intomasterfrom
joshferge/feat/assign-prs-to-user-v2

Conversation

@JoshFerge
Copy link
Copy Markdown
Member

@JoshFerge JoshFerge commented Apr 10, 2026

Summary

  • Register organizations:seer-assign-prs-to-user feature flag
  • Pass assign_pr_to_user boolean in autofix request options
  • Pass github_username and assign_pr_to_user in explorer user context

Stack

Context

Legacy autofix already had reviewer assignment functionality, but the newer explorer autofix flow was missing it. This PR passes the necessary context (feature flag + GitHub username) so Seer can assign PRs to the invoking user in both flows.

Merge order

Merge this (Sentry) first, then the Seer PR. Seer's new fields default to False/None so either order is safe during rolling deploy, but the feature only activates once Sentry is deployed and sending the flag.

Companion Seer PR: https://github.com/getsentry/seer/pull/5704

Test plan

  • CollectUserOrgContextTest passes (18/18)
  • TestCallAutofix passes
  • Flag off: no behavior change
  • Flag on: Seer receives assign_pr_to_user=True and github_username

Agent transcript: https://claudescope.sentry.dev/share/ujgSwmf913H1ZXhobbmzBKpdRANFfyPG4duNrbz37Ho

@github-actions github-actions bot added the Scope: Backend Automatically applied to PRs that change backend components label Apr 10, 2026
@JoshFerge JoshFerge force-pushed the joshferge/ref/shared-github-username-util branch from 8a6d955 to 950be54 Compare April 10, 2026 14:39
@JoshFerge JoshFerge force-pushed the joshferge/feat/assign-prs-to-user-v2 branch from 0461e97 to e88ce89 Compare April 10, 2026 14:39
@JoshFerge JoshFerge force-pushed the joshferge/ref/shared-github-username-util branch from 950be54 to 5a0d4bc Compare April 10, 2026 14:42
@JoshFerge JoshFerge force-pushed the joshferge/feat/assign-prs-to-user-v2 branch from e88ce89 to 51afcc4 Compare April 10, 2026 14:42
Extract the GitHub username resolution function from autofix.py to
seer/utils.py so it can be reused by the explorer flow. The old name
is re-exported from autofix.py for backwards compatibility.

No behavior change.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Agent transcript: https://claudescope.sentry.dev/share/8BmYM4cKcaUl38fiIA-xxoHkUFgXmsXGQ2qrpAgJuKs
Extract the GitHub username resolution function from autofix.py to
seer/utils.py so it can be reused by the explorer flow. The old name
is re-exported from autofix.py for backwards compatibility.

No behavior change.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Agent transcript: https://claudescope.sentry.dev/share/8BmYM4cKcaUl38fiIA-xxoHkUFgXmsXGQ2qrpAgJuKs
Add feature flag `organizations:seer-assign-prs-to-user` and wire it
through both autofix and explorer flows so Seer can assign PRs to the
invoking user on GitHub.

- Register feature flag in temporary.py
- Pass `assign_pr_to_user` in autofix request options
- Pass `github_username` and `assign_pr_to_user` in explorer user context

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Agent transcript: https://claudescope.sentry.dev/share/O_Pqf33_KzAdKIC0uHWtBHi4N9k2TWTCmGLf0e0rTrU
@JoshFerge JoshFerge force-pushed the joshferge/ref/shared-github-username-util branch from 5a0d4bc to b1c6394 Compare April 10, 2026 14:57
@JoshFerge JoshFerge force-pushed the joshferge/feat/assign-prs-to-user-v2 branch from 51afcc4 to 1d9240e Compare April 10, 2026 14:57
Base automatically changed from joshferge/ref/shared-github-username-util to master April 10, 2026 15:07
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