Skip to content

test(agents): run agent stand-ins on a sleep that answers to any name - #3508

Merged
devswha merged 1 commit into
devswha:mainfrom
Danipulok:fix/sleep-stand-in
Nov 10, 2026
Merged

devswha merged 1 commit into
devswha:mainfrom
Danipulok:fix/sleep-stand-in

Conversation

@Danipulok

Copy link
Copy Markdown
Contributor

Change

The contract tests and two browser QA scripts start agent stand-ins by copying or linking /bin/sleep under an agent's name (hermes, agy, grok-*, muse, codex, omp). On Ubuntu 26.04, /bin/sleep is the rust-coreutils multicall binary, which picks its program by the name it runs under, so every stand-in exits at once:

$ cp /bin/sleep ./hermes && ./hermes 1
coreutils: unknown program 'hermes'
$ ln -s /bin/sleep ./muse && ./muse 1
Security violation: Requested utility `muse` does not match executable name:
  /usr/lib/cargo/bin/coreutils/sleep

The GNU build ships beside it as /usr/bin/gnusleep (https://packages.ubuntu.com/resolute/amd64/gnu-coreutils/filelist). The new scripts/fixtures/sleep.ts exports SLEEP, which is /usr/bin/gnusleep when it exists and /bin/sleep otherwise. Every stand-in now uses it, so other systems behave as before. This is a test-only change, so there is no changelog entry.

Validation

Run on Ubuntu 26.04 with Bun 1.4.2, Node 22 and herdr 0.9.5.

  • bun run check fast: every step passes except one unit file. scripts/install-herdr-core.test.ts fails on this machine on main too: GNUstep plutil refuses the LaunchAgent, which test(install): lint the LaunchAgent with plutil on the macOS job and with plistlib elsewhere #3506 fixes.
  • bun test server/hermes.contract.test.ts: 9 pass. On main, 1 fails with Hermes stand-in did not become the pane's foreground process.
  • bun test server/api.contract.test.ts: 197 pass. On main, 4 fail: fixture Grok process did not start, and the same for Agy, Muse and Codex.
  • Not run: the two browser QA scripts (scripts/agy-chat-browser-qa.ts, scripts/grok-chat-browser-qa.ts), and any run on macOS.

@coderabbitai

coderabbitai Bot commented Nov 9, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Summary

Summary by CodeRabbit

  • Chores
    • Updated automated browser checks and contract tests to use a compatible sleep utility across Linux environments, including Ubuntu 26.04. This keeps the checks’ existing behavior while improving their portability.

The pull request adds a shared sleep executable fixture. Browser QA scripts and contract tests now use the selected binary for their temporary stand-ins instead of using /bin/sleep directly.

Changes: Sleep executable selection and use

Layer / File(s) Summary
Select and use the shared sleep executable
scripts/fixtures/sleep.ts, scripts/*-chat-browser-qa.ts, server/*contract.test.ts
The fixture selects /usr/bin/gnusleep when present and otherwise uses /bin/sleep. The browser QA scripts and contract tests use the fixture for their stand-ins.

Estimated code review effort: 2 (Simple) | ~8 minutes

Change: Other · Severity of issue fixed: Low

Possibly related issues

  • devswha/ovis#3496: The issue reports that the Grok browser QA stand-in exits when /bin/sleep is copied under the name grok. This change uses the shared fixture for that stand-in.

Suggested reviewers: devswha

Merge Risk: Minimal · up to 1ab8b

The change selects a compatible sleep executable for test stand-ins. No merge-blocking issue is established.

Pre-merge checks: Passed 5

Check name Status Explanation
Title check Passed The title clearly summarizes the main change: agent stand-ins now use a sleep executable that works under any name.
Description check Passed The description explains the problem and resulting behavior, and lists validation results, known failures, and skipped checks. It also reports contract-test coverage.
Docstring Coverage Passed No eligible functions found in the changed files. Skipping docstring coverage check. 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

No eligible functions found in the changed files. Skipping docstring coverage check. 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 0 functions across 5 files.

Finishing Touches

Generate unit tests (beta)

  • 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

  • Source mode: Auto
  • Repository: devswha/ovis
  • Branch: main
  • File: .coderabbit.yaml
  • Commit: d3cf98b
  • Layers: Repository YAML
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 5f742418-2eae-477e-8284-d3d6333e8139
Commits

Reviewing files that changed from the base of the PR and between d3cf98b and 1ab8b6b.

Files selected for processing: 5

  • scripts/agy-chat-browser-qa.ts
  • scripts/fixtures/sleep.ts
  • scripts/grok-chat-browser-qa.ts
  • server/api.contract.test.ts
  • server/hermes.contract.test.ts

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

@github-actions

github-actions Bot commented Nov 9, 2026 •

Copy link
Copy Markdown

All contributors have signed the CLA. Thank you!
Posted by the CLA Assistant Lite bot.

@Danipulok

Copy link
Copy Markdown
Contributor Author

recheck

@Danipulok
Danipulok marked this pull request as ready for review November 10, 2026 00:09
@devswha
devswha merged commit 34dc74a into devswha:main Nov 10, 2026
34 of 48 checks passed
@devswha

devswha commented Nov 10, 2026

Copy link
Copy Markdown
Owner

Merge pass

Merged head 1ab8b6b981e9 as 34dc74aff8c2 on GitHub's checks, with no unresolved review threads.

Reviewer Verdict Note
claude CLEAR
claude-standin CLEAR

Merged with these checks red, none of them required: ssh;

  • Reviewers: a fresh Claude agent and a Claude stand-in (Codex unavailable), both CLEAR at 1ab8b6b. The base failure and the fix were reproduced on an Ubuntu 26.04 host at the binary level (a copy or link of /bin/sleep under an agent's name exits at once; gnusleep runs).
  • CI and the runner image are Ubuntu 24.04 with no gnusleep, so they take the unchanged /bin/sleep path.
  • LOW, not fixed: a rust-coreutils system without the gnu-coreutils package still falls back to /bin/sleep with no hint.
  • ssh (Remote PC bundles, not required) is red on this head as it is on other branches; unrelated to the change.
  • CodeRabbit did not review this head.

@Danipulok
Danipulok deleted the fix/sleep-stand-in branch November 10, 2026 09:59
devswha added a commit that referenced this pull request Nov 28, 2026
…ded tail for real (#4991)

Fixes #3496.

1. **The Find test did not prove Find.**
`scripts/chat-virtual-browser-qa.ts` dispatched `beforematch` itself.
With `.chat-tool-result-tail{display:none}` added, the old script still
passed. It now asks Chromium to find the text through a text fragment
(`location.hash = ":~:text=..."`), the same search Ctrl+F runs: it
reveals `hidden=until-found` text and fires `beforematch`. With the tail
hidden it now fails. (`window.find` finds the text but fires no
`beforematch` and reveals nothing, so it cannot stand in for Ctrl+F.)
2. **Markdown code blocks folded the old way.** Their tail was not in
the page, so Find could not reach it, and Show less at the end of the
chat scrolled up. The tool-output fold logic moved to
`src/lib/textFold.ts` (`useFindableTail` keeps the tail in the page as
`hidden=until-found` and unfolds on a match; `showFoldedBlock` skips the
scroll back when the chat is at its end), and `ToolOutputText` and
`CodeBlock` both use it. On main the new code-block checks fail ("the
folded tail is in the page": false; Show less at the end: jump). The
rich-text copy now leaves out a folded tail (`hidden=until-found`) and
keeps other hidden elements such as the visualization's copy-only `<br
hidden>` (`src/lib/markdownClipboard.test.ts`, both cases fail without
the change). The plain-text copy is still the browser's own
`selection.toString()`.
3. **The grok QA stand-in** was already fixed by #3508
(`scripts/fixtures/sleep.ts`); `scripts/grok-chat-browser-qa.ts` passes
on a host whose `/bin/sleep` is uutils.

No visible change: before/after screenshots of the code block, folded
and unfolded, at 1280 and 390 px are byte-identical. The tail sits next
to the code `<pre>`, not inside it, so `HighlightedCode` (also used by
the file viewer) is untouched.

Checks: `bun scripts/chat-virtual-browser-qa.ts` (4 new PASS lines for
code-block Find and Show less at 1440 and 390), `bun run typecheck`,
Markdown, MarkdownDocuments, markdown, markdownClipboard, changelog-fold
and conventions tests.
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.

2 participants