Skip to content

ai slop - #34676

Closed
robobun wants to merge 2 commits into
mainfrom
farm/d393d334/http2-rehash-test-timeout
Closed

ai slop#34676
robobun wants to merge 2 commits into
mainfrom
farm/d393d334/http2-rehash-test-timeout

Conversation

@robobun

@robobun robobun commented Jul 19, 2026 •

Copy link
Copy Markdown
Collaborator

This PR has been marked as AI slop and the description has been updated to avoid confusion or misleading reviewers.

Many AI PRs are fine, but sometimes they submit a PR too early, fail to test if the problem is real, fail to reproduce the problem, or fail to test that the problem is fixed. If you think this PR is not AI slop, please leave a comment.

The "does not hold *Stream across user-controlled options getters" test
spawned its subprocess via `bun -e`, which on a debug+ASAN build runs the
129 concurrent h2 requests in ~6.3s and overruns the default 5s per-test
timeout. The other two tests in the same file spawn fixture files and
finish in ~3s.

Move the script to node-http2-getter-rehash.fixture.js to match, and cut
the inner-loop stream count from 128 to 32 (the streams HashMap starts at
capacity 8 and grows at 80% load, so 32 still forces several rehashes).
Drop parent/weight from the options: they now emit DEP0194 and are
deleted before the native call anyway.

Before: 3/3 timeouts at 5s. After: 3/3 pass in ~3.2s.
@robobun

robobun commented Jul 19, 2026 •

Copy link
Copy Markdown
Collaborator Author
Updated 9:11 PM PT - Jul 18th, 2026

❌ @robobun, your commit 136e6aa has 4 failures in Build #75589 (All Failures):


🧪   To try this PR locally:

bunx bun-pr 34676

That installs a local version of the PR into your bun-34676 executable, so you can run:

bun-34676 --bun

@coderabbitai

coderabbitai Bot commented Jul 19, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

@robobun, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 24 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 7ce4fa81-b065-40b5-89a6-6f7bdd27e0fd

📥 Commits

Reviewing files that changed from the base of the PR and between 20b4a0b and 136e6aa.

📒 Files selected for processing (2)
  • test/js/node/http2/node-http2-getter-rehash.fixture.js
  • test/js/node/http2/node-http2-streams-rehash.test.ts

Comment @coderabbitai help to get the list of available commands.

@claude claude Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM — mechanical test de-flake that moves the inline -e script to a fixture file to match its two siblings. The inline nit about the comment/title wording is non-blocking and largely pre-dates this PR.

Extended reasoning...

Overview

Test-only change to test/js/node/http2/node-http2-streams-rehash.test.ts: the second of three tests was timing out at 5s on debug+ASAN because it ran its repro via bun -e while the other two used fixture files. This PR extracts the script to node-http2-getter-rehash.fixture.js, cuts the inner loop 128→32, and drops the parent/weight options. No src/ diff.

Security risks

None. Test fixture only; spawns a local h2 server on 127.0.0.1:0, no external network, no new dependencies.

Level of scrutiny

Low. This is a mechanical refactor of an existing regression test to match the exact shape of its two neighbors in the same file. The test wrapper (spawn + drain both pipes + assert {stdout, exitCode}) is byte-identical to the sibling tests. The fixture preserves the triggered guard, so if the getter stops firing the test fails with exit 1 rather than silently passing.

Coverage-weakening check (per REVIEW.md)

Each reduction is justified in the PR description and was independently verified by the bug hunter:

  • 128→32 streams: still forces ≥3 rehashes from initial cap 8 at 80% load — no coverage loss.
  • Dropping parent/weight: DEP0194 strips these in JS before the native call, so they never reached native even before this PR.
  • -e → fixture: pure de-flake, matches siblings.

The one inline nit notes that the fixture comment's "while the outer stream is being set up" overstates what this path guards post-#31323 — but the old -e script's comment was already stale for the same reason, so this PR doesn't introduce the inaccuracy. Non-blocking wording cleanup the author can take or leave.

Other factors

PR description shows 3/3 passing runs with the change. No outstanding reviewer comments. Approving.

Comment thread test/js/node/http2/node-http2-getter-rehash.fixture.js Outdated
The getter fires during the JS-side options spread (since #31323), not while
a native *Stream is held. Make the comment say so.
@robobun

robobun commented Jul 19, 2026 •

Copy link
Copy Markdown
Collaborator Author

Self-review clean (25 concerns probed, none survived). Review thread addressed in 136e6aa.

node-http2-streams-rehash.test.ts passed on every lane in both builds. Remaining CI failures are unrelated to this diff:

  • #75579: worker-transfer-terminate-stress JSC assertion (known, several open PRs) + 4 Windows flakes
  • #75589: node-net.test.ts mimalloc page-count boundary on debian aarch64 (owned elsewhere) + assorted Windows/asan memory-leak flakes

This is a test-only change (no src/ diff), so there is no fail-before for the gate to observe: stashing src/ is a no-op and the test passes either way. On unmodified main the test times out 3/3 at 5s under bun bd test; with this change it passes 3/3 at ~3.2s. Ready for a maintainer to merge.

@claude claude Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM — the fixture comment in 136e6aa now accurately describes this as a JS-side re-entrancy smoke test, which addresses my earlier note. Test-only de-flake that mirrors the two sibling fixtures.

What was reviewed:

  • -e → fixture file matches the pattern of the other two tests; assertion shape (toMatchObject with stderr captured-but-not-asserted) is unchanged.
  • 32 inner streams still forces ≥3 rehashes from cap 8 @ 80% load; dropped parent/weight are DEP0194-stripped in JS before the native call anyway, so no coverage loss vs. the old script.
  • Fixture guards against vacuous pass via the !triggered → exit(1) check.
Extended reasoning...

Overview

Test-only PR touching two files under test/js/node/http2/: moves an inline bun -e script from node-http2-streams-rehash.test.ts into a new sibling fixture node-http2-getter-rehash.fixture.js, cuts the inner request loop from 128→32, and drops the deprecated parent/weight priority options. No src/ changes. The motivation is a consistent 5s timeout on debug+ASAN builds where the -e path is ~2× slower than the fixture path for this workload.

Prior review

I left one nit on the previous revision: the fixture header claimed the getter fires "while the outer stream is being set up", which was inaccurate since #31323 spreads options before any stream exists. The author pushed 136e6aa updating the header to "request() now shallow copies options in JS before any stream exists (#31323), so this is a re-entrancy/ordering smoke test rather than the original native UAF repro" — that's honest and addresses the point. They reasonably left the pre-existing test title/file header alone as out of scope for a timeout fix. Thread is resolved.

Security risks

None. Test-only; the fixture spawns a local h2 server on 127.0.0.1:0 and connects to itself, same as the old inline script and the two siblings.

Level of scrutiny

Low. This is a mechanical de-flake: the new fixture is byte-for-byte the old -e script minus (a) the loop count, (b) two options fields that are stripped in JS anyway, and (c) a stale comment. The test wrapper now matches its two neighbors exactly. The one REVIEW.md concern for test edits — "never silently weaken" — was examined in the prior round and the conclusion stands: the weakening (getter no longer reaching native) pre-dates this PR (#31323); 128→32 and dropping DEP0194 fields lose nothing further.

Other factors

  • Fixture retains the !triggered guard so it can't vacuously pass if request() stops reading paddingStrategy.
  • toMatchObject includes stderr in the actual object for diagnostics but doesn't assert it empty — correct per REVIEW.md (ASAN/debug noise).
  • PR description shows 3/3 passing runs at ~3.2s, comfortably under the 5s default.
  • Bug-hunting system found nothing this run.

@github-actions

Copy link
Copy Markdown
Contributor

This PR has been closed because it was flagged as AI slop.

Many AI-generated PRs are fine, but this one was identified as having one or more of the following issues:

  • Fails to verify the problem actually exists
  • Fails to test that the fix works
  • Makes incorrect assumptions about the codebase
  • Submits changes that are incomplete or misleading

If you believe this was done in error, please leave a comment explaining why.

@github-actions github-actions Bot changed the title test(http2): move options-getter rehash repro to a fixture so it fits in 5s ai slop Jul 19, 2026
@github-actions github-actions Bot closed this Jul 19, 2026
@robobun

robobun commented Jul 19, 2026

Copy link
Copy Markdown
Collaborator Author

I believe this closure was in error. Addressing each criterion:

Verified the problem exists. On unmodified main at 20b4a0b, bun bd test test/js/node/http2/node-http2-streams-rehash.test.ts -t "does not hold" times out 3/3 runs at the 5s default (output in the PR body). PR #33004 independently notes the same failure as a "pre-existing 5-second-timeout flake on debug+ASAN builds: it reproduces identically on unmodified main (3/3 runs)".

Tested that the fix works. 3/3 local passes at ~3.2s shown in the PR body. node-http2-streams-rehash.test.ts passed on every lane in both CI builds (#75579, #75589); the remaining reds are unrelated main breaks already owned elsewhere.

Codebase assumptions. The -e vs fixture-file timing was measured (6.3s vs 3.8s for the same 129-request script on a debug+ASAN build), the spread at src/js/node/http2.ts:5926 and the HashMap growth thresholds in src/collections/zig_hash_map.rs were traced, and both automated review rounds here confirmed the analysis with no surviving concerns.

Completeness. The change moves the inline -e repro to a fixture file so it matches the two sibling tests in the same file (node-http2-foreach-rehash.fixture.js, node-http2-flush-rehash.fixture.js), cuts the loop to a count that still forces several rehashes, and updates the fixture comment to say honestly that the getter now fires during the JS-side options spread (since #31323). The fixture also runs clean under node.

This is a test-only change, so the gate cannot observe a fail-before: stashing src/ is a no-op and the modified test passes either way. That is inherent to fixing a test that is too slow on main, not a sign the fix is unverified.

Leaving for a maintainer to reopen if they agree.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants