-
Notifications
You must be signed in to change notification settings - Fork 36
feat: add Claude Code runner #73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Removes a couple of methods that were duplicated from the base class.
Moves the instructions and ignored files into the agent base class.
22f1c66
to
25e5dea
Compare
'--model', | ||
MODEL_MAPPING[options.model], | ||
// Skip all confirmations. | ||
'--dangerously-skip-permissions', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we eventually need a warning before selecting some of these runners? seems "corp-risky"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe, although internally this wouldn't be installed anyways.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought anybody could run with the claude code runner on a corporate machine and this could execute arbitrary commands?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, but I meant if we were running in a g3 context.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah yeah, I'm mostly talking about it executing on corp machines, so it could technically even reach into other directories?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that it could in theory, but my impression was that it's set up to run in the CWD.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@crisbeto just to follow-up on this. The risk is that the agent is started in CWD, but can also use tools to read files from e.g. $HOME/.zshrc
etc
package.json
Outdated
"wcs": "./runner/bin/cli.js" | ||
}, | ||
"dependencies": { | ||
"@anthropic-ai/claude-code": "^1.0.128", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should these runners be optional dependencies eventually? (i.e. users install them in their project?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm potentially, but how would the type checking work?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We'd have it as a dev dependency on our end, but not as a runtime dependency for shipping to npm.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I pushed another commit to make them optional.
Fixes an error I saw while debugging where if the `exit` event emits quickly, we would get a `Cannot access <name> before initialization` error.
Allows for agents inheriting from the `BaseCliAgentRunner` to override the timeout values.
Some agent processes don't seem to execute until stdin has ended. These changes add it to the `BaseCliAgentRunner`.
Adds a runner that generates code using Claude Code.
Reduces the font size of the provider labels so they don't wrap to the next line as often.
25e5dea
to
d57309b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feedback has been addressed.
package.json
Outdated
"wcs": "./runner/bin/cli.js" | ||
}, | ||
"dependencies": { | ||
"@anthropic-ai/claude-code": "^1.0.128", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm potentially, but how would the type checking work?
'--model', | ||
MODEL_MAPPING[options.model], | ||
// Skip all confirmations. | ||
'--dangerously-skip-permissions', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe, although internally this wouldn't be installed anyways.
Adds a runner that generates code using Claude Code.