Guard failures fail the round, not the run; add guard_exclude_paths - #28
Open
TON14 wants to merge 1 commit into
Open
Guard failures fail the round, not the run; add guard_exclude_paths#28TON14 wants to merge 1 commit into
TON14 wants to merge 1 commit into
Conversation
Two related fixes for auditor read-only-guard snapshot errors (e.g. EBADF when a build directory churns underneath the walk): 1. classify_agent_runtime_failure returns None when the episode carries verifier_workspace_snapshot_errors: the audit is already rejected fail-closed by the adapter, so the round fails and is retried instead of the whole run aborting with provider_provider_error. Reproduced twice on 0.1.4 with a large Rust workspace (cargo target/ churn). 2. New [run] guard_exclude_paths config option (and --guard-exclude-path CLI flag): volatile workspace paths the guard skips while snapshotting. Unlike hidden_paths these stay readable to the agents; relative paths resolve against the workspace.
Author
|
Context and reproduction details for the underlying problem are in #27 (run aborted as |
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.
Fixes #27.
Two related changes for auditor read-only-guard snapshot errors (e.g.
EBADFwhen a build directory churns underneath the walk):1. A guard snapshot failure fails the round, not the run
classify_agent_runtime_failurenow returnsNonewhen the episode carriesverifier_workspace_snapshot_errors. The adapter has already rejected the audit fail-closed at that point, so the round fails and is retried — restoring the 0.1.3 behavior — instead of the whole run aborting withprovider_provider_error. Genuine runtime failures (auth, quota, rate limit, network, model) keep their terminal classification; a test covers both directions.2. New
guard_exclude_pathsoptionA
[run] guard_exclude_pathsconfig key (and matching--guard-exclude-pathCLI flag) lists volatile workspace paths the guard should not snapshot — build/cache directories such astarget,node_modules,build,.venv. Unlikehidden_pathsthese stay fully readable to the agents: the guard just refrains from walking directories that legitimately churn during an audit window, which avoids the race in #27 at the source. Relative paths resolve against the workspace; the default is empty, so existing behavior is unchanged.lh-harness initdocuments the option in the generated config, including a warning not to exclude guard-protected paths like.git.Testing
tests/test_provider_errors.py(new): guard-snapshot failure →None;"connection reset by peer"→ still terminal withabort_reason == "provider_network".lh-harness initandlh-harness doctoron a real project, and a multi-hour run on a Rust workspace withguard_exclude_paths = ["target"]where 0.1.4 previously aborted twice.🤖 Generated with Claude Code