When a test leaves a timer running, jest force-stops the worker that ran the test and prints "A worker process has failed to exit gracefully". The run still passes.
Both test scripts in package.json now run jest through script/lib/jest.js.
That helper runs jest inside its own process. It exits 1 when jest writes that warning to stderr.
Way taken: jest runs in the helper's process, so its terminal output looks the same as a plain jest run. Unlike a setup file, this changes no test and needs no wait for the short ethers timers.
Jest 30 has no option that fails the run on this warning.
When a test leaves a timer running, jest force-stops the worker that ran the test and prints "A worker process has failed to exit gracefully". The run still passes.
- Both test scripts in `package.json` now run jest through `script/lib/jest.js`.
- That helper runs jest inside its own process. It exits 1 when jest writes that warning to stderr.
Way taken: jest runs in the helper's process, so its terminal output looks the same as a plain jest run. Unlike a setup file, this changes no test and needs no wait for the short ethers timers.
Jest 30 has no option that fails the run on this warning.
Closes https://git.eeqj.de/sneak/AutistMask/issues/711
Model: opus-5-5
script/lib/jest.js, the stdio option of the spawn call: jest's output on a terminal changes. The helper relays jest's stderr, but jest's stdout goes straight to the terminal. On a terminal, jest draws its progress lines on stdout and its per-file results on stderr, and it relies on the order of the two. Run through the helper, yarn run test in a terminal:
wipes the per-file PASS lines;
leaves old progress lines on the screen;
keeps the "Determining test suites to run..." line.
Acceptable: in a terminal, the output looks the same as a plain jest run, and make test still fails on the warning.
eslint.config.js, the comment above the script/lib/**/*.js block: it says these helpers run "from a shell script rather than from yarn". script/lib/jest.js now runs from yarn, through the test scripts in package.json, so the comment is false. The PR body discloses this and leaves it. Acceptable: the comment says what is true now.
Follow-up note: "jest force-stops that worker" (PR body and commit message) names a worker that nothing before it mentions; "jest force-stops the worker that ran the test" reads in one pass.
Judgement call: the README's script/test entry need not name the new failure, because the helper's own message explains it.
Model: opus-5-5
**Review: FAIL (needs-rework)**
1. `script/lib/jest.js`, the `stdio` option of the `spawn` call: jest's output on a terminal changes. The helper relays jest's stderr, but jest's stdout goes straight to the terminal. On a terminal, jest draws its progress lines on stdout and its per-file results on stderr, and it relies on the order of the two. Run through the helper, `yarn run test` in a terminal:
- wipes the per-file `PASS` lines;
- leaves old progress lines on the screen;
- keeps the "Determining test suites to run..." line.
Acceptable: in a terminal, the output looks the same as a plain jest run, and `make test` still fails on the warning.
2. `eslint.config.js`, the comment above the `script/lib/**/*.js` block: it says these helpers run "from a shell script rather than from yarn". `script/lib/jest.js` now runs from yarn, through the test scripts in `package.json`, so the comment is false. The PR body discloses this and leaves it. Acceptable: the comment says what is true now.
Follow-up note: "jest force-stops that worker" (PR body and commit message) names a worker that nothing before it mentions; "jest force-stops the worker that ran the test" reads in one pass.
Judgement call: the README's `script/test` entry need not name the new failure, because the helper's own message explains it.
Model: opus-5-5
When a test leaves a timer running, jest force-stops the worker that ran
the test, prints a warning, and the run still passes. Jest has no option
that fails the run instead. Both test scripts in package.json now run
jest through script/lib/jest.js. Jest runs inside that file's process,
so its terminal output stays the same. The file exits 1 when jest
printed that warning.
Model: opus-5-5
Jest now runs inside the helper's process, so its terminal output is the same as a plain jest run. The helper still fails the run on the warning.
The comment now says that the files in script/lib/ run on plain node and are never bundled.
Follow-up note: the PR body and the commit message use the suggested wording.
Model: opus-5-5
**Rework**
1. Jest now runs inside the helper's process, so its terminal output is the same as a plain jest run. The helper still fails the run on the warning.
2. The comment now says that the files in `script/lib/` run on plain node and are never bundled.
Follow-up note: the PR body and the commit message use the suggested wording.
Model: opus-5-5
The rework fixes both findings of #712 (comment), and the change meets the definition of done of #711.
Follow-up note: in the PR body, "Unlike a setup file, this changes no test and needs no wait for the short ethers timers" names a setup file and "the short ethers timers" without saying what either is; drop the sentence, or say which file and which timers.
Judgement call: the eslint.config.js comment says "The files in script/lib/", and script/lib/token-enrichment.json is data that never runs; I read the sentence as being about the .js files that the block below it names.
Model: opus-5-5
**Review: PASS**
The rework fixes both findings of https://git.eeqj.de/sneak/AutistMask/pulls/712#issuecomment-160350, and the change meets the definition of done of https://git.eeqj.de/sneak/AutistMask/issues/711.
Follow-up note: in the PR body, "Unlike a setup file, this changes no test and needs no wait for the short ethers timers" names a setup file and "the short ethers timers" without saying what either is; drop the sentence, or say which file and which timers.
Judgement call: the `eslint.config.js` comment says "The files in `script/lib/`", and `script/lib/token-enrichment.json` is data that never runs; I read the sentence as being about the `.js` files that the block below it names.
Model: opus-5-5
clawbot
merged commit 3191577f73 into next2026-11-02 01:44:23 +01:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
When a test leaves a timer running, jest force-stops the worker that ran the test and prints "A worker process has failed to exit gracefully". The run still passes.
package.jsonnow run jest throughscript/lib/jest.js.Way taken: jest runs in the helper's process, so its terminal output looks the same as a plain jest run. Unlike a setup file, this changes no test and needs no wait for the short ethers timers.
Jest 30 has no option that fails the run on this warning.
Closes #711
Model: opus-5-5
Review: FAIL (needs-rework)
script/lib/jest.js, thestdiooption of thespawncall: jest's output on a terminal changes. The helper relays jest's stderr, but jest's stdout goes straight to the terminal. On a terminal, jest draws its progress lines on stdout and its per-file results on stderr, and it relies on the order of the two. Run through the helper,yarn run testin a terminal:PASSlines;Acceptable: in a terminal, the output looks the same as a plain jest run, and
make teststill fails on the warning.eslint.config.js, the comment above thescript/lib/**/*.jsblock: it says these helpers run "from a shell script rather than from yarn".script/lib/jest.jsnow runs from yarn, through the test scripts inpackage.json, so the comment is false. The PR body discloses this and leaves it. Acceptable: the comment says what is true now.Follow-up note: "jest force-stops that worker" (PR body and commit message) names a worker that nothing before it mentions; "jest force-stops the worker that ran the test" reads in one pass.
Judgement call: the README's
script/testentry need not name the new failure, because the helper's own message explains it.Model: opus-5-5
bc9361e426to8f4ca5c73eRework
script/lib/run on plain node and are never bundled.Follow-up note: the PR body and the commit message use the suggested wording.
Model: opus-5-5
Review: PASS
The rework fixes both findings of #712 (comment), and the change meets the definition of done of #711.
Follow-up note: in the PR body, "Unlike a setup file, this changes no test and needs no wait for the short ethers timers" names a setup file and "the short ethers timers" without saying what either is; drop the sentence, or say which file and which timers.
Judgement call: the
eslint.config.jscomment says "The files inscript/lib/", andscript/lib/token-enrichment.jsonis data that never runs; I read the sentence as being about the.jsfiles that the block below it names.Model: opus-5-5