-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Fix terminal security check evaluatePolicy type definition #8226
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
The type incorrectly referenced 'evaluatePolicy' instead of 'evaluateToolCallPolicy', which is the actual field name in the Tool interface. This prevented TypeScript from properly enforcing the omission of this field when serializing tools for the browser. Fixes CON-4401 Generated with [Continue](https://continue.dev) Co-authored-by: Continue <noreply@continue.dev> Co-authored-by: nate@continue.dev
|
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.
No issues found across 1 file
RomneyDa
left a comment
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.
@continue this is a valid change and can stay but doesn't fix whatever redux or other messaging issue is causing dangerous commands to not change the policy
|
🎉 This PR is included in version 1.27.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
|
🎉 This PR is included in version 1.5.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
|
🎉 This PR is included in version 1.30.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
|
🎉 This PR is included in version 1.4.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Description
Fixed a typo in the
BrowserSerializedContinueConfigtype definition where it incorrectly referenced'evaluatePolicy'instead of'evaluateToolCallPolicy'.Root Cause
The
Toolinterface has a field calledevaluateToolCallPolicy, but theBrowserSerializedContinueConfigtype was usingOmit<Tool, "preprocessArgs", "evaluatePolicy">instead of the correctOmit<Tool, "preprocessArgs", "evaluateToolCallPolicy">.This typo meant TypeScript was not properly enforcing the omission of the
evaluateToolCallPolicyfield when tools were serialized for the browser, which could have led to runtime issues if GUI code attempted to access this function (which should only exist on the core side).Changes
core/index.d.tsto use the correct field nameevaluateToolCallPolicyTesting
evaluateToolCallPolicyis omitted from serialized toolsFixes CON-4401
This agent session was co-authored by nate and Continue.
Summary by cubic
Corrected BrowserSerializedContinueConfig to omit evaluateToolCallPolicy (not evaluatePolicy) so browser-serialized tools don’t expose core-only policy checks. Fixes CON-4401.