fix(agent): pass --verbose to claude subprocess#17
Merged
Conversation
Recent versions of the claude CLI reject the SDK's invocation with: Error: When using --print, --output-format=stream-json requires --verbose The partio-io SDK already exposes the toggle via claude.WithVerbose; no vendor or upstream patch needed. Hardcode it to true in buildOptions — archy always wants this and it has no user-visible effect since stdout/stderr aren't surfaced to the operator (the SDK's drain goroutine consumes stderr via our WithStderrCallback). Diagnosed via the SDK-invocation-summary + stderr-capture infrastructure from the previous two PRs.
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
Recent versions of the
claudeCLI reject the SDK's invocation with:This caused every
archy dailyrun to silently complete withturns=0, zero cost, zero tool calls, empty text — exactly the symptom the diagnostic infrastructure from PRs #15 and #16 surfaced.Fix: The partio-io SDK already exposes
claude.WithVerbose(v bool) Option. Hardcode it totrueinbuildOptions. archy always wants this and it has no user-visible effect — the SDK's drain goroutine consumes stderr via ourWithStderrCallback, so--verbose's extra subprocess output doesn't bleed to the operator.Deviation from the originating task
The task draft proposed vendoring the SDK in
third_party/and patchinginternal/process/args.go. I didn't vendor because the same effect is reachable from the consumer side via the SDK's existingWithVerboseoption — one-line fix, no third-party maintenance burden, noreplacedirective to clean up later. The upstream issue (forcing--verbosewhen streaming insideBuildArgs) is still worth filing; that's a follow-up.Test plan
go build ./...go test -race ./...(14 packages green; option-count assertions updated 5→6, 6→7, 5→6)go vet ./...golangci-lint run(0 issues)./archy daily --force— the agent run now produces actual output (file lands, or a new archy-side error surfaces — anything but the silent zero-turn exit)