mirror of
https://github.com/cpacker/MemGPT.git
synced 2025-06-03 04:30:22 +00:00
fix: pattern match new prints correctly (#2213)
Co-authored-by: Caren Thomas <caren@caren-mac.local>
This commit is contained in:
parent
666e4259cf
commit
975aca155f
2
.github/workflows/check_for_new_prints.yml
vendored
2
.github/workflows/check_for_new_prints.yml
vendored
@ -43,7 +43,7 @@ jobs:
|
||||
NEW_PRINTS=$(git diff ${{ github.event.pull_request.base.sha }} ${{ github.sha }} "$file" | \
|
||||
grep "^+" | \
|
||||
grep -v "^+++" | \
|
||||
grep "print(" || true)
|
||||
grep -E "(^|\s)print\(" || true)
|
||||
|
||||
if [ ! -z "$NEW_PRINTS" ]; then
|
||||
echo "❌ Found new print statements in $file:"
|
||||
|
@ -201,7 +201,10 @@ class ToolExecutionSandbox:
|
||||
func_result, stdout = self.parse_out_function_results_markers(result.stdout)
|
||||
func_return, agent_state = self.parse_best_effort(func_result)
|
||||
return SandboxRunResult(
|
||||
func_return=func_return, agent_state=agent_state, stdout=[stdout], sandbox_config_fingerprint=sbx_config.fingerprint()
|
||||
func_return=func_return,
|
||||
agent_state=agent_state,
|
||||
stdout=[stdout],
|
||||
sandbox_config_fingerprint=sbx_config.fingerprint(),
|
||||
)
|
||||
except subprocess.TimeoutExpired:
|
||||
raise TimeoutError(f"Executing tool {self.tool_name} has timed out.")
|
||||
|
Loading…
Reference in New Issue
Block a user