Skip to content

Bound check failures and elapsed-time updates - #1463

Closed
eowca wants to merge 2 commits into
mainfrom
lean178/1086-check-output-r44
Closed

eowca wants to merge 2 commits into
mainfrom
lean178/1086-check-output-r44

Conversation

@eowca

@eowca eowca commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

Bound check failures and elapsed-time updates

Context and goal

  • Goal: Keep the failure cause and receipt identity visible while keeping check output short.
  • Problem: Long structured failure lines and unchanged 30-second heartbeats dominate transcripts.
  • Context: An oversized failure preview clips long lines and marks omissions. The checked head and full diagnostic tail remain in the check receipt. A silent stage reports at 30 seconds and every five minutes thereafter.

Closes #1086
Closes #1084

Acceptance

  • The large failure fixture stays below 2,500 bytes and retains the failing command, exit code, standalone migration error, final assertion, offline remedy and matching receipt path. Stale or failed receipt publication emits no receipt pointer.
  • A simulated hour-long stage in a 24-stage check stays below 2,400 bytes and retains stage completion, verdict and receipt identity.

Transcript size

Scenario Before After
Oversized check failure 16,618 bytes 1,355 bytes
Check with one silent hour 5,928 bytes 1,893 bytes

Notes

Validation

(no loopzero check run recorded)


Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

Review

  • primary, claude, 9388b97, request_changes

Co-Authored-By: Codex <noreply@openai.com>

@loopzero-feder-positronics loopzero-feder-positronics Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

loopzero primary review by claude on 9388b97d06e72296edfb53dbfa3b1f771c813187, 41.7s: request_changes (0 critical, 1 important, 2 suggestion)

Settings per native call (launch configuration and CLI claims, not backend attestation):

  • Call 1: requested model claude-opus-5-5 (effort medium); CLI-reported model claude-opus-5-5 (effort unknown); configured model claude-opus-5-5 (effort medium)

Native Claude output is retained in the restricted local review receipt.

Comment thread tests/test_cli.py
return code, captured.out, captured.err


# Transcript size regressions

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

important: Branch fails the size-budget gate that loopzero check and CI run

scripts/size_budget.sh:16 sets TESTS_CAP=13850. Line 38 fails when the test line count is over the cap and has also grown against the base. The task notes say tests are at 13,914 / 13,850 after merging main, and this diff adds about 64 more test lines, so report tests exits with status 1. As written, the branch cannot get a passing receipt. That breaks acceptance in this repo's workflow, where ready needs a passing check.

Smallest fix: trim the new tests so the tests tree is not larger than the base. For example, fold the three receipt parametrizations and the hour-long test into fewer assertions, or remove now-redundant assertions elsewhere in tests/test_cli.py / tests/test_sandbox.py. Alternatively, raise TESTS_CAP in a separate reviewed change with a fresh measurement comment. Do not ship a branch that is known to fail the gate.

Comment thread src/loopzero/cli.py
file=sys.stderr)
return 1
if shortened:
print(f"Full diagnostic tail: {CHECKS_FILE} (head {report.head})", file=sys.stderr)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Receipt pointer prints a path relative to the worktree, not the caller's directory

The receipt is written to wt / CHECKS_FILE (cli.py:363). The new pointer prints only the relative CHECKS_FILE (.loopzero/checks.json). If loopzero check runs from a subdirectory, or the worktree is resolved through _context instead of the cwd, that path does not lead to the receipt that holds the full diagnostic tail. Smallest fix: print wt / CHECKS_FILE instead. The existing test only checks the .loopzero/checks.json substring, so it still passes.

Comment thread src/loopzero/cli.py
**_proc.build_env(config.env_allowlist),
**dict(config.env),
}
env = sandbox.SANDBOX_ENV | _proc.build_env(config.env_allowlist) | dict(config.env)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Unrelated rewrites inside cmd_check widen the diff

Several edits don't change behaviour and aren't needed for bounding output: the env dict is rewritten from {**a, **b} to a | b | c, current_head is moved into a walrus, and the offline-remedy wording is reworded (it drops the 'or the same commands' alternative). They make the change harder to review and change user-facing remedy text without a stated reason. Consider reverting the parts that aren't needed so the diff stays focused on the preview and pointer.

Architecture-Review: unchanged; the existing delivery structure and command roles still apply.
Co-Authored-By: Codex <noreply@openai.com>
@eowca

eowca commented Nov 26, 2026

Copy link
Copy Markdown
Contributor Author

Superseded by #1748. Loop Zero cannot delta-review the conflict-resolution merge (#1240), so the same check output fixes will get a primary review on current main.

@eowca eowca closed this Nov 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Keep oversized check failure output in the receipt and show a short preview Reduce repetitive elapsed-time updates from loopzero check

1 participant