Conversation
jaydgoss
commented
Mar 17, 2026
jaydgoss
commented
Mar 17, 2026
jaydgoss
commented
Mar 17, 2026
jaydgoss
commented
Mar 17, 2026
jaydgoss
commented
Mar 17, 2026
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
c02633a to
eeca857
Compare
eeca857 to
d53957e
Compare
c2d04a2 to
051bdaa
Compare
Disable CompactSelect while existing repos are loading to prevent selecting installed repos before their Sentry IDs are available. Destructure context setters in ScmConnect to stabilize handleInstall deps. Add error state for failed provider/integration queries. Expand OnboardingContextProvider value prop to accept full session state so tests can use the real provider instead of spying on useOnboardingContext. Refs VDY-19
Use || instead of ?? for domainName fallback so empty strings fall through to provider.name. Initialize search state as empty string instead of undefined for explicitness. Extract boolean from selectedIntegration for useEffect dep to avoid re-running when the object reference changes but truthiness does not.
…pills The org creator always has org:integrations, so the Access check is unreachable in the onboarding flow. Remove the wrapper and hardcode userHasAccess. If this component is reused in project creation (where non-owners can land), the access check should be revisited.
The error UI retry button only called refetchIntegrations, so if the providers query failed the UI stayed stuck. Add a refetch function that retries both queries and wire the retry button to use it.
setSelectedPlatform(undefined) was calling removeOnboarding() which wiped the entire session including selectedIntegration and selectedRepository. Only do a full reset when no other state remains; otherwise clear just the platform field.
…tform" This reverts commit 76be625.
Move the ref null-out to after the await so that if hideRepository fails, the ref retains the ID and the user can retry removal.
Rename adding to busy and set it during both add and remove operations. Previously handleRemove didn't disable the UI, so a user could select a new repo while hideRepository was in flight.
The addRepository and hideRepository action creators show global toast messages (Loading, Success, Error) designed for the settings page. Replace with direct API calls to avoid confusing toasts during onboarding.
Check selectedRepository.id instead of just truthiness so the button stays disabled during the optimistic add (id is empty string until the POST resolves).
If a repo is marked as installed but the active-repos lookup fails (e.g., repo was previously hidden), fall through to the POST path to re-add it instead of leaving the user stuck with an empty ID.
Use all server-provided fields (name, url, etc.) instead of only cherry-picking id from the POST response.
Per review feedback — "Connected" terminology isn't used elsewhere in the codebase.
Replace inline provider and integration objects with GitHubIntegrationProviderFixture and OrganizationIntegrationsFixture.
Replace inline provider and integration objects with GitHubIntegrationProviderFixture, OpsgenieIntegrationProviderFixture, and OrganizationIntegrationsFixture.
No need for a separate component -- the connected view markup is small and only used in one place.
… repos The already-installed path only took the id from the existing Sentry repo, leaving optimistic placeholders for url, dateCreated, and name. Spread the full existing object to match the POST path behavior.
a3dde29 to
22ea2cc
Compare
- Replace inline mockIntegration with OrganizationIntegrationsFixture - Narrow useScmRepoSearch useMemo dep from full selectedRepo object to selectedRepo.externalSlug since only the slug drives the disabled flag
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements the
SCM_CONNECTonboarding step behind theorganizations:onboarding-scmfeature flag. Functional-first -- UI polish is out of scope.What it does
Provider connection
IntegrationinOnboardingContext.selectedIntegrationRepository selection
GET /integrations/{id}/repos/?search=POST /repos/(or looks up the existing Sentry ID if already added)Repository(with real Sentry ID) inOnboardingContext.selectedRepositoryPRD scenario alignment
Skip and navigation
Out of scope
New files
useScmProviders.ts-- data-fetching hook for SCM providers and active installationscomponents/scmProviderPills.tsx-- OAuth provider pill buttonscomponents/scmConnectedView.tsx-- connected status + "Manage in Settings" link + repo selectorcomponents/scmRepoSelector.tsx-- repo search dropdown UIcomponents/useRepoSearch.ts-- debounced provider repo search querycomponents/useRepoSelection.ts-- repo add/remove lifecycle with optimistic updatesTest plan
Refs VDY-19