Skip to content

test(copilot): keep the browser fixture's node process name so WSL reports its argv - #3504

Merged
devswha merged 1 commit into
devswha:mainfrom
YuuuXie:fix/copilot-browser-qa-wsl
Nov 10, 2026
Merged

devswha merged 1 commit into
devswha:mainfrom
YuuuXie:fix/copilot-browser-qa-wsl

Conversation

@YuuuXie

@YuuuXie YuuuXie commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

Change

scripts/copilot-chat-browser-qa.ts fails on WSL: the Chat endpoint answers source: "scrollback" (copilot_process_set_unproved) instead of copilot-transcript.

On WSL, herdr (0.9.3 to 0.9.5, process_allows_remote_memory_read in src/platform/linux.rs) doesn't read /proc/<pid>/cmdline for a process whose comm names a known agent. That read can hang in access_remote_vm there. The fixture set process.title = "copilot", so herdr reported it without argv, and since #3189 such a process set is unproven and fails closed.

The fixture now keeps node's own process name and runs as node <root>/copilot.js, like an npm-installed Copilot. herdr detects the pane as copilot from that argv, and agentProcesses matches it as an interpreted agent. The real Copilot CLI doesn't rename its process either. No assertion or ownership check changes.

Validation

  • bun run check run --build bun scripts/copilot-chat-browser-qa.ts on WSL2 (herdr 0.9.5): fails before this change, passes after (all steps, including PTY send and transient recovery).
  • Probe on WSL2 with herdr 0.9.3 and 0.9.5: processes named copilot or claude are reported without argv; node x.js and a node symlink named foo are reported with it.
  • Native Linux reads argv for both shapes, so behavior there is unchanged (browser lane in CI).

…ports its argv

On WSL herdr does not read the cmdline of a process named after an agent, so
the fixture renamed to copilot had no argv and devswha#3189's ownership check failed
closed. Running as node copilot.js matches an npm-installed Copilot.

Co-authored-by: Copilot <[email protected]>
Copilot-Session: 03511a3a-c861-4657-b123-934fa3dbd976
@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 internal browser QA setup to retain Node’s default process name. This change affects only the QA fixture and does not alter application behavior or introduce any user-facing changes.

The Copilot fixture no longer sets process.title to "copilot". Its comments now describe the retained Node process name and WSL argv handling.

Changes: Copilot fixture process

Layer / File(s) Summary
Retain Node process name
scripts/copilot-chat-browser-qa.ts
The fixture no longer assigns process.title = "copilot". The comments describe the retained Node process name and WSL argv handling.

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

Change: Other

Possibly related PRs

  • devswha/ovis#2666: This PR keeps the fixture’s Node argv visible through Herdr on WSL, relating to the Copilot process and transcript path.

Suggested reviewers: devswha

Merge Risk: Minimal · up to 14cc4

The fixture retains Node’s process name to support WSL process discovery. No merge-blocking risk was identified.

Pre-merge checks: Passed 5

Check name Status Explanation
Title check Passed The title clearly identifies the main change: keep Node’s process name so WSL reports the fixture’s argv.
Description check Passed The description explains the WSL failure, the resulting behavior, and the validation performed. It includes both required sections.
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 1 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: c3612422-e765-491e-9cb9-d14d673b6f90
Commits

Reviewing files that changed from the base of the PR and between d3cf98b and 14cc49d.

Files selected for processing: 1

  • scripts/copilot-chat-browser-qa.ts

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

@devswha
devswha merged commit 466b9ed into devswha:main Nov 10, 2026
27 of 29 checks passed
@devswha

devswha commented Nov 10, 2026

Copy link
Copy Markdown
Owner

Merge pass

Merged head 14cc49d6bf1d as 466b9ed9ffc6 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 14cc49d, no findings.
  • The fixture's new argv shape (node <root>/copilot.js ...) was checked against the server's Copilot process matching, and the script passed on native Linux in CI at this head. The WSL half of the claim is herdr behaviour and was not reproduced here.
  • The first CI run failed ui-regression on "readline fixture did not start", which this change does not touch; it passed on a rerun.
  • CodeRabbit did not review this head.

@YuuuXie
YuuuXie deleted the fix/copilot-browser-qa-wsl branch November 10, 2026 11:15
devswha added a commit that referenced this pull request Nov 11, 2026
…opened output left the end (#3654)

## Change

Fixes a flaky browser script, `scripts/copilot-chat-browser-qa.ts`,
which timed out waiting for `Follow-up answer.` (`TimeoutError: waitFor:
Timeout 15000ms exceeded`). In about 30 h of CI, 10 runs needed a second
attempt for it: 9 at that wait and 1 at the next turn, `Autopilot
finished this task.`. The latest was run 42954642665.

### Cause

A race in the script, not a product bug. Before the follow-up turn is
written, the script opens the shell tool's whole output. The chat treats
that as reading (#1388): it stops following the end and shows "New
messages" for turns that arrive. The list draws rows only within 400 px
of the view, so the answer row was never created and the wait could not
find it. Whether the row landed inside that window depended on where the
list settled after the clicks.

A failure traced in the self-hosted CI runner image shows this:
- The server was right: its change push came 52 ms after the append, and
the next read returned the turn.
- The page showed "New messages", and its drawn rows stopped at
`Follow-up prompt`, 886 px above the end.

The CI logs show no conversation-read failures either.

### Fix

The script waits for either the answer or the pane's own "New messages"
button. If the button shows, it clicks it as a reader would, then waits
for the answer. Back at the end, the chat follows the next turn too. No
sleep, no longer timeout, no product change.

## Validation

- In `herdr-ci-runner:local`, the script ran next to three other looping
browser scripts, with `main`'s script and the fixed one alternating in
the same container: `main` failed 7 of 30 runs, all at `Follow-up
answer.`; the fix passed 30 of 30. The final version, which looks for
the button only inside the chat's own pane, passed 15 of 15, 2 of them
through New messages.
- `#3504` (merged before every failure) did not fix this, and no open PR
touches the script.
- `bun run check fast` on this branch, rebased on main fbcf093: every
step passed except one unit test unrelated to this change,
`server/pc-install.test.ts` "starting a stopped server again as it was >
starts nothing when its address is taken by a live server, and keeps its
log this account's alone" (`:1079`). This diff does not touch that file,
so it is the same as on `main`. Run alone it failed 1 of 5 times, so it
is a separate flake; it is being tracked on its own.
- Not run: `check full`, other browser scripts. Test-only, so no
changelog fragment.
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