Before submitting
Area
apps/server
Steps to reproduce
- Configure Bitbucket credentials in Settings → Source Control.
- Open the clone dialog and choose Bitbucket as the source.
- Enter a repository name without a workspace, e.g.
myrepo instead of myworkspace/myrepo, and continue.
Expected behavior
The dialog says what is wrong with the input. BitbucketRepositoryLocatorError already carries the right message: "Bitbucket repositories must be specified as workspace/repository."
Actual behavior
The lookup fails with a generic toast:
Source control repository operation lookupRepository failed for bitbucket: The source control operation could not be completed.
No request is made to the Bitbucket API. Instead:
parseBitbucketRepositorySlug returns null for a one-segment name.
BitbucketApi.resolveRepository treats that as "no repository given" and falls back to the git remotes of input.cwd. That fallback suits operations on the current checkout (listing or creating PRs), but not a lookup where the user typed a name.
lookupRepository passes cwd: input.cwd ?? config.cwd. The clone dialog sends no cwd, so the server's own working directory is used. In the desktop app that's the home directory, which isn't a repository, so VcsUnsupportedOperationError is raised.
mapRepositoryError replaces the cause with the generic detail, so the real reason appears only in server.trace.ndjson.
The failure happens before any HTTP request, so it doesn't depend on the Bitbucket backend.
Possible fix: when input.repository is given but can't be parsed, fail with BitbucketRepositoryLocatorError instead of falling back to the checkout's remotes, and show its detail in the dialog.
Related: #7849, a lookup failure in the same dialog with a self-hosted GitLab URL.
Impact
Minor bug or occasional failure
Version or commit
0.0.46-nightly.20261003.2623 (desktop); same code on main @ f391794
Environment
macOS 26.7, T3 Code (Nightly) desktop app
Logs or stack traces
SourceControlRepositoryError: Source control repository operation lookupRepository failed for bitbucket: The source control operation could not be completed.
[cause]: SourceControlProviderError: Source control provider bitbucket failed in getRepositoryCloneUrls: Failed to get repository clone URLs.
[cause]: BitbucketRepositoryVcsResolveError: Bitbucket API failed in resolveRepository: Failed to resolve VCS repository for /Users/<user>.
[cause]: VcsUnsupportedOperationError: VCS operation is unsupported for unknown in VcsDriverRegistry.resolve: No supported VCS repository was detected at /Users/<user>.
Workaround
Enter the repository as workspace/repository, or paste a clone URL.
Before submitting
Area
apps/server
Steps to reproduce
myrepoinstead ofmyworkspace/myrepo, and continue.Expected behavior
The dialog says what is wrong with the input.
BitbucketRepositoryLocatorErroralready carries the right message: "Bitbucket repositories must be specified as workspace/repository."Actual behavior
The lookup fails with a generic toast:
No request is made to the Bitbucket API. Instead:
parseBitbucketRepositorySlugreturnsnullfor a one-segment name.BitbucketApi.resolveRepositorytreats that as "no repository given" and falls back to the git remotes ofinput.cwd. That fallback suits operations on the current checkout (listing or creating PRs), but not a lookup where the user typed a name.lookupRepositorypassescwd: input.cwd ?? config.cwd. The clone dialog sends nocwd, so the server's own working directory is used. In the desktop app that's the home directory, which isn't a repository, soVcsUnsupportedOperationErroris raised.mapRepositoryErrorreplaces the cause with the generic detail, so the real reason appears only inserver.trace.ndjson.The failure happens before any HTTP request, so it doesn't depend on the Bitbucket backend.
Possible fix: when
input.repositoryis given but can't be parsed, fail withBitbucketRepositoryLocatorErrorinstead of falling back to the checkout's remotes, and show its detail in the dialog.Related: #7849, a lookup failure in the same dialog with a self-hosted GitLab URL.
Impact
Minor bug or occasional failure
Version or commit
0.0.46-nightly.20261003.2623 (desktop); same code on main @ f391794
Environment
macOS 26.7, T3 Code (Nightly) desktop app
Logs or stack traces
Workaround
Enter the repository as
workspace/repository, or paste a clone URL.