Skip to content

test(pending): the contract tests' omp stand-ins load no integration, so herdr keeps their state reports - #3644

Merged
devswha merged 1 commit into
mainfrom
fix/omp-contract-stand-in
Nov 11, 2026
Merged

devswha merged 1 commit into
mainfrom
fix/omp-contract-stand-in

Conversation

@devswha

@devswha devswha commented Nov 11, 2026

Copy link
Copy Markdown
Owner

Change

Since #3624, server/pending-input.contract.test.ts fails often on PR runs (#3517, #3639, #3551 each needed a rerun). The failure is an omp case of "delivers queued $text as $expected to $agent" at about 8.6 to 8.9 s ("queued command was not recorded", then "pending frame timeout" in state("idle")), and once, the hookless-process test after it.

The cause is the test setup #3624 added, not the queue's wait for a starting omp. For every omp stand-in, setup reported a herdr:omp session (so a send would not wait for an omp that loads the integration on a PC where it is installed). After that report, herdr drops the manual pane.report_agent state report that state("idle") makes about half the time. The pane stays working, the queue never sees its turn end, and the queued message is never typed.

Measured on the isolated test herdr (a stand-in reported working, the session report or not, then idle; the status read for a second after):

stand-in pane still working after idle
omp, with the herdr:omp session report 7 of 15
omp, without it 0 of 15
claude 0 of 15

Fix: setup's omp stand-ins (other than the two omp-start tests', which load the integration with -e) start with --no-extensions. The bridge sees an omp that loads no integration, also on a PC where it is installed, so no send waits for a report, and no session is reported. The omp-start tests report their state before their session, and are unchanged.

The hookless-process test that failed after the omp case did not fail in any run here once the omp case passed. Not proven beyond that.

Test-only change.

Validation

… so herdr keeps their state reports

Since #3624 every omp stand-in reported a herdr:omp session, after which herdr drops the manual
state report state("idle") makes about half the time (7 of 15 on the isolated herdr; 0 of 15
without it): the queued message never saw its turn end. The stand-ins now start with
--no-extensions, so no send waits for a report and none is made. The omp-start tests keep theirs.
@coderabbitai

coderabbitai Bot commented Nov 11, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Summary

Summary by CodeRabbit

  • Tests
    • Updated test setup for ordinary omp cases, which now run without extensions or a manually reported session. Starting cases continue to load the integration.

The pending-input test fixture now disables extensions for non-starting omp cases. It keeps herdr integration for ompStarting cases and no longer reports an omp session for non-starting cases.

Changes: Pending input test fixture

Layer / File(s) Summary
Configure omp test cases
server/pending-input.contract.test.ts
The setup adds --no-extensions for non-starting omp cases and keeps herdr integration for ompStarting cases. It removes the fixture’s ompReports() call for non-starting cases.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Change: Bug fix

Suggested reviewers: jimbb

Merge Risk: Minimal · up to d2e01

The change adjusts test fixtures; no merge-blocking risk was identified.

Pre-merge checks: Passed 5

Check name Status Explanation
Title check Passed The title clearly identifies the test-only change: OMP stand-ins load no integration so Herdr preserves their state reports.
Description check Passed The description includes complete Change and Validation sections. It explains the intermittent failure, cause, fix, affected tests, and validation results, including contract-test coverage.
Docstring Coverage Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 1 functions across 1 files.

Finishing Touches

Generate docstrings

  • Commit to this branch
  • Create a new PR
Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between dd21d21 and d2e01e0.

Files selected for processing: 1

  • server/pending-input.contract.test.ts

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 2 remain after this review.

@devswha
devswha merged commit 64bc36c into main Nov 11, 2026
21 checks passed
@devswha

devswha commented Nov 11, 2026

Copy link
Copy Markdown
Owner Author

Merge pass

Merged head d2e01e0c5535 as 64bc36c10750 on GitHub's checks, with no unresolved review threads.

Reviewer Verdict Note
codex CLEAR

One reviewer: test-only PR (one contract test file).

Test-only PR (server/pending-input.contract.test.ts), so one reviewer: Codex Terra, CLEAR with no findings.

It fixes the contract-test flake that reddened PR runs since #3624 (#3517, #3639, #3551, #3645: "delivers queued /model as /switch to omp" at about 8.7 s, with a neighbour failing after it). Cause, as the author measured on the isolated herdr: once a stand-in omp has reported a herdr:omp session, herdr drops the manual state report that ends its turn about half the time, so the queued message never sees the turn end. The stand-ins that are not about omp's start now load no integration.

Checked by the merge pass on this head: the whole file six times through the check harness (bun run check run -- env HERDR_TEST_MODE=integration bun test --timeout 15000 ./server/pending-input.contract.test.ts), 125 pass and 0 fail each time.

#3646 (lane ci-loop) fixes the same flake another way in the same function; it will conflict with this and is its lane's to rebase or close.

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.

1 participant