mirror of
https://github.com/instructkr/claw-code.git
synced 2026-11-18 00:00:00 +08:00
Revert "Merge pull request #3318 from ultraworkers/pr-3292"
This reverts commit2d920ce915, reversing changes made to80bfe94b77.
This commit is contained in:
1 parent
2d920ce915
commit
f021597942
18 files changed
+464
-1940
No files matched your search
@@ -506,17 +506,13 @@ pub fn mvp_tool_specs() -> Vec<ToolSpec> {
|
||||
},
|
||||
ToolSpec {
|
||||
name: "read_file",
|
||||
description: "Read a text file from the workspace. Large files come back one page at \
|
||||
a time: if the response has \"truncated\": true you have NOT seen the \
|
||||
whole file, and \"nextOffset\" is the line to pass as `offset` to \
|
||||
continue. Prefer grep_search to locate what you need over paging \
|
||||
through a big file, and never re-read a page you already have.",
|
||||
description: "Read a text file from the workspace.",
|
||||
input_schema: json!({
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"path": { "type": "string" },
|
||||
"offset": { "type": "integer", "minimum": 0, "description": "First line to read (0-based). Pass the previous response's nextOffset to continue." },
|
||||
"limit": { "type": "integer", "minimum": 1, "description": "Maximum lines to return. Capped by a byte ceiling regardless." }
|
||||
"offset": { "type": "integer", "minimum": 0 },
|
||||
"limit": { "type": "integer", "minimum": 1 }
|
||||
},
|
||||
"required": ["path"],
|
||||
"additionalProperties": false
|
||||
@@ -10405,12 +10401,6 @@ mod tests {
|
||||
|
||||
#[test]
|
||||
fn repl_executes_python_code() {
|
||||
// Resolving the python runtime reads PATH, and PATH is process-global: the PowerShell
|
||||
// tests below blank it while they run. Without this guard that races and this test
|
||||
// intermittently fails with "python runtime not found" on a machine that has python.
|
||||
let _guard = env_lock()
|
||||
.lock()
|
||||
.unwrap_or_else(std::sync::PoisonError::into_inner);
|
||||
let result = execute_tool(
|
||||
"REPL",
|
||||
&json!({"language": "python", "code": "print(1 + 1)", "timeout_ms": 500}),
|
||||
|
||||
Reference in new issue
Block a user