fix(dev): prompt for credentials before image build + fix CLI execute bit#21
Merged
Conversation
On first run of `azureclaw dev --build`, credentials were prompted only after the Docker image build (which can take 10-20 min for Rust). Two issues: 1. Wrong step order: credentials should be asked first so users aren't surprised by a prompt after a long build, and don't waste time if they lack valid credentials. 2. Spinner conflict: the ora spinner from stepper.step() was still active when inquirer.prompt() tried to display interactive input, causing the prompts to be invisible/overwritten. Fix: move credential check to step 1 (before image resolution), and stop the spinner before calling promptAndSaveCredentials() so inquirer prompts display correctly. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
tsc doesn't preserve the executable permission on output files, causing 'permission denied' when running azureclaw after npm link. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Model: clarify it must already exist in the Azure OpenAI resource - API key: clarify it's the resource-level key, not a per-model key Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…esource - Help text: explain that an existing Azure OpenAI resource with a deployed model is required - --model flag: clarify it's an existing deployment name - First-run prompt: tell user they need an existing resource + deployment Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Collaborator
Author
pallakatos
pushed a commit
that referenced
this pull request
May 12, 2026
… bit (#21) * fix(dev): prompt for credentials before image build On first run of `azureclaw dev --build`, credentials were prompted only after the Docker image build (which can take 10-20 min for Rust). Two issues: 1. Wrong step order: credentials should be asked first so users aren't surprised by a prompt after a long build, and don't waste time if they lack valid credentials. 2. Spinner conflict: the ora spinner from stepper.step() was still active when inquirer.prompt() tried to display interactive input, causing the prompts to be invisible/overwritten. Fix: move credential check to step 1 (before image resolution), and stop the spinner before calling promptAndSaveCredentials() so inquirer prompts display correctly. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix(cli): set execute bit on dist/index.js after build tsc doesn't preserve the executable permission on output files, causing 'permission denied' when running azureclaw after npm link. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix(cli): clarify credential prompt labels - Model: clarify it must already exist in the Azure OpenAI resource - API key: clarify it's the resource-level key, not a per-model key Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix(dev): clarify help text and prompts about existing Azure OpenAI resource - Help text: explain that an existing Azure OpenAI resource with a deployed model is required - --model flag: clarify it's an existing deployment name - First-run prompt: tell user they need an existing resource + deployment Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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.




Problem
When
azureclaw dev --buildis run for the first time (no~/.azureclaw/config.json), the credential prompt doesn't work properly. Additionally,make install-cliresults in a permission denied error when runningazureclaw.Root causes
Wrong step order — Credentials were prompted at step 2, after the Docker image build (step 1), which can take 10-20 minutes for Rust compilation. Users should be asked for credentials first.
Spinner hides interactive prompt —
stepper.step("Loading credentials...")starts anoraspinner that's still animating wheninquirer.prompt()tries to display the interactive endpoint/model/API-key inputs. The spinner overwrites the prompt text, making it invisible or unresponsive.Missing execute bit on dist/index.js —
tscdoesn't preserve the executable permission on output files, so afternpm link, runningazureclawfails withEACCES: permission denied.Changes
cli/src/commands/dev.tspromptAndSaveCredentials()soinquirerprompts display correctlyloadConfig+promptAndSaveCredentialsdirectly instead ofensureCredentialsfor finer controlcli/package.jsonchmod +x dist/index.jsto the build script so the CLI entry point is always executable aftertscNew first-run flow
Testing
tsc --noEmitpassesoxlint— 0 errorsmake install-cli→azureclaw --helpworks (no permission denied)