Skip to content

feat: re-prompt for a repository name when the provider rejects it - #1373

Merged
l2ysho merged 1 commit into
masterfrom
claude/apify-cli-1372-b7c997
Sep 1, 2026
Merged

feat: re-prompt for a repository name when the provider rejects it#1373
l2ysho merged 1 commit into
masterfrom
claude/apify-cli-1372-b7c997

Conversation

@l2ysho

@l2ysho l2ysho commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

Note

TL;DRapify create --source github no longer throws away the whole run when GitHub rejects the repository name. In a TTY it asks for another name and retries; without one it stops as before.

Closes #1372

apify create --source github stopped the whole run when the Git provider rejected the repository name — taken, or malformed. The name is fixable on the spot and nothing has been created at that point, so an interactive run now prints the provider's message and asks for another name, then retries.

  • Interactive only. Without a TTY (--json, CI, piped stdin) the run keeps the previous repoNameRejected stop and its next steps.
  • No prefilled value in the prompt: defaulting to the rejected name would make Enter repeat the same failure.
  • Tests cover both branches of runGitSourceFlow — the retry sends the new name, the non-interactive path still stops.

Verified by hand against GitHub: taken name in a TTY re-prompts and the run completes; the same command with stdin from /dev/null stops with the error.

No new dependencies, so no install-size change.

🤖 Generated with Claude Code

Closes #1372

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@l2ysho
l2ysho requested a review from DaveHanns as a code owner August 31, 2026 15:36
@github-actions github-actions Bot added this to the 148th sprint - Tooling team milestone Aug 31, 2026
@github-actions github-actions Bot added t-tooling Issues with this label are in the ownership of the tooling team. tested Temporary label used only programatically for some analytics. labels Aug 31, 2026

@DaveHanns DaveHanns left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Nice 🚀

@l2ysho
l2ysho merged commit e8b9d9b into master Sep 1, 2026
24 checks passed
@l2ysho
l2ysho deleted the claude/apify-cli-1372-b7c997 branch September 1, 2026 07:34
l2ysho added a commit that referenced this pull request Sep 1, 2026
Master's #1371 and #1373 rewrote the same functions this branch generalizes.
Resolved by keeping this branch's multi-provider shape and folding both of
master's behaviours into it:

- `getGitConnectUrl` keeps the optional `authorize` block, so GitLab and
  Bitbucket still fall back to the Console page, and now also sends
  `routePrefix` for an organization login
- `ensureUsableIntegration` keeps the Console hand-off race for providers
  the CLI cannot authorize, and takes master's per-poll re-read of which
  grant is missing, its never-open-the-same-URL-twice rule, and the
  account-aware wait message — with provider labels rather than ids
- `runGitSourceFlow` keeps the non-fatal clone and per-account `providerId`,
  and takes master's re-prompt for a rejected repository name
- `notAuthorized` and `noWorkspace` name the Apify account and the provider
  label; next steps and `getGitStopUrl` carry the account
- both test suites kept in full

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

t-tooling Issues with this label are in the ownership of the tooling team. tested Temporary label used only programatically for some analytics.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

re-prompt if repo name already taken

3 participants