[ENG-4060] Declare every runtime option and keep the declarations in step - #303
Merged
Merged
Conversation
|
Adds missing runtime option declarations and robust drift tests. 🎯 Quality: 100% Elite · 📦 Size: Medium 🤖 Authorship: Agent-written — Claude Code, going by its own attribution. Whether a person read it is unknown; coding agents can call the 📈 This month: Your 164th PR — above team average · Averaging Excellent |
Contributor
Author
|
/review |
mariojgt
approved these changes
Sep 29, 2026
patchstackdave
force-pushed
the
fix/declaration-drift
branch
from
September 29, 2026 09:22
b79dee6 to
07852e7
Compare
Add the options the runtime reads but protect.d.ts did not declare, and coverage(). Correct the fetchImpl and reportManifest descriptions. A test now compares the option names the runtime reads, and the members the protection object carries, with the declarations in both directions. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
patchstackdave
force-pushed
the
fix/declaration-drift
branch
from
September 29, 2026 09:35
07852e7 to
bf7d553
Compare
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.
protect.d.tsis written by hand, and it had fallen behind the runtime.Added: declarations for the options the runtime already reads —
onSkip,onRuleRejected,bootTimeoutMs,refreshTimeoutMs,acceptPartialBundle,allowGlobalWhitelistsand the top-levelmaxBodyBytes— and for thecoverage()method.Corrected:
fetchImplis used by the reporters, not the rules client.reportManifestapplies whenever a refresh path is configured, not only withrefreshMs > 0.New test: it compares the option names the runtime reads, and the members the protection object carries, with the declarations, in both directions. A new option or member without a declaration fails it, and so does a declaration the runtime no longer uses.
No runtime change.
Rebased onto current
main. The test also passes against the options and members that have landed there since, so they are all declared.Validation: full suite, typecheck, build.
Part of ENG-4060.
🤖 Generated with Claude Code