fix: correct clone URL and make setup.sh fail early on missing deps/keys - #1
Open
lgoyal6 wants to merge 1 commit into
Open
fix: correct clone URL and make setup.sh fail early on missing deps/keys#1lgoyal6 wants to merge 1 commit into
lgoyal6 wants to merge 1 commit into
Conversation
The first command in the README clones from github.com/surface-labs, an organisation with no public repositories, so the quick start exits 128 with "Repository not found" for anyone following the instructions as written. The repository lives under trysurface, and correcting that URL is the one change that unblocks a new user. Running the rest of the setup turned up three further problems, all of which are quiet rather than loud. That is the more expensive failure mode, because the script reports success in every one of these cases and the user only finds out later. setup.sh printed "ANTHROPIC_API_KEY looks set" and exited 0 even when the key line had been deleted from .env, because it tested only for the presence of the placeholder string rather than for an actual value. It also read .env without exporting anything, so a key that existed only in that file never reached the claude subprocess. The check now resolves the effective key from the process environment first and .env second, distinguishes missing from placeholder from present, and accumulates every problem it finds so the user sees the full list in one run instead of fixing them one at a time. .env.example line 2 is a bash syntax error if the file is sourced, which is a natural thing for someone to try given how the surrounding instructions are written. run-pipeline.sh validated the transcript path only after agent-01 had already run, so a misconfigured path burned a complete agent invocation before failing. That validation now happens before any agent starts. Verified under bash 5.x and under the system bash 3.2.57 that ships with macOS, since the script uses arrays and the older shell is what a Mac user will hit by default.
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.
The quick start's first command clones from github.com/surface-labs, which has no
public repositories, so
git cloneexits 128 for everyone. Points it at trysurface.While verifying that, three other things fail quietly:
instead of editing it prints "ANTHROPIC_API_KEY looks set" and exits 0. It also
exits 0 on the un-replaced placeholder, so
setup.sh && run-pipeline.shcontinuesinto the pipeline. Both now exit 1 with a message naming the fix, and all problems
are reported in one pass. A key already exported in the shell satisfies the check.
a bash syntax error on the parenthesis. Moved to comments, matching the advice
already in docs/troubleshooting.md.
typo cost a full agent run. The check now happens first.
Tested on macOS against bash 5.x and system bash 3.2.57: placeholder key, missing key
line, real key in .env, and key exported in the shell only.