docs(gotcha 36): the 10ms CPU limit is a clamp under load, not a flat wall - #398
Merged
Conversation
… wall The note shipped yesterday stated Workers Free's 10ms per-invocation CPU limit as a hard ceiling a single request meets. Measuring production the same day contradicted it: requests finish `ok` at 90ms and 196ms when the account is quiet, and the 03:00Z window that showed 31 of 51 dying at exactly 10ms was a clamp under sustained /lens load. Same code, different answer depending on how busy the account is, which is why this presented as intermittent. The subrequest cap stays the hard, deterministic one, and it is what definitively broke the album covers at ~67 against 50. Also records how the fix was actually verified, since a pass/fail probe could not see it: all twelve A/B requests returned 200 on both versions, and the difference was CPU, at a median of 51ms against 15ms. And the version-override header wants the FULL UUID, because the 8-char prefix silently fails to pin and lands every request on the majority version, which reads exactly like a fix that changed nothing.
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ✅ Deployment successful! View logs |
aadhar-sh | f27309b | Aug 15 2026, 12:04 PM |
This was referenced Aug 15, 2026
oddharsh
added a commit
that referenced
this pull request
Aug 16, 2026
…verse (#416) This gotcha claimed twice that the Copilot check fails on every diff, and one of those claims went in a few hours ago as the general lesson. It is wrong. The run always fires; whether it REQUESTS A MODEL depends on the diff. The job prints a file exclusion list on every run, covering js, json, mjs, ts, py, rs, yaml, yml, html, xml, go, java, c/cpp, rb and more. `.md`, `.sh` and `.css` are NOT on it. So a docs diff survives the filter and gets a `claude-opus-4.6` request, while a pure JavaScript diff is filtered to nothing and the run exits clean. Both paths print `Sessions disabled: not supported for code scanning yet`, which this session initially read as the discriminator and is not; the discriminating line is `Creating copilot-sdk session with model`, which only the failing path reaches. Correlates 12 of 12: the five runs of 2026-08-15 (#399 jpg/json and #402 js/mjs passed; #398, #400 and #401 all carried md and failed), plus all seven earlier failures checked backwards. #313 is the "CSS-only" diff this gotcha already singles out, and css is not on the list either. #351's note here called its entire diff a `${{ }}` move in workflow files; it touched md and mjs too, and the md is what drew the request. The prose-only argument is unchanged in conclusion and inverted in mechanism: a docs PR reddens this because markdown is one of the few things the detector still looks at, rather than because the agent choked on prose. The entitlement root cause is untouched. Records the method failure too, since it is the transferable part. Nine entries were built by pattern-matching outcomes across PRs without once reading which files each diff touched, and "fails on everything" was an artifact of that sample. One uncollected column explained the whole shape. Co-authored-by: Aadharsh Pannirselvam <19518661+oddharsh@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Correcting a number I wrote into gotcha 36 in #395. The very next measurement contradicted it, and CLAUDE.md is the file other sessions read as truth.
What was wrong
The note stated Workers Free's 10ms per-invocation CPU limit as a hard ceiling a single request meets. Production says otherwise:
/lens/fetchrequests finishedokat 90ms and 196ms.exceededCpuat exactly 10ms was a clamp under sustained load, while/lenswas being hammered.Same code, different answer depending on how busy the account is. That is why this presented as intermittent, and why chasing a repro on one URL kept exonerating the wrong things.
The subrequest cap stays the hard, deterministic one, and it is what definitively broke the covers at ~67 against 50. That half of the note is unchanged.
Also recorded: how to verify a fix like this
A pass/fail probe could not see it. All twelve A/B requests returned 200, on both versions. The difference was CPU:
And one trap worth the line:
Cloudflare-Workers-Version-Overrideswants the FULL version UUID. The 8-char prefix silently fails to pin and lands every request on the majority version, which reads exactly like a fix that changed nothing. It cost one wasted A/B here.Status of the fix itself
Confirmed live at the 10% canary: 21/21 covers and 21/21 artist photos, 42 art refs in the rendered fragment. The
fulljob is still parked on the reviewer gate.Docs only, no code change. 277/277 contract tests pass.