deps(regex): take perex 0.1.11 (perex#3 matcher) under a one-time publish-age override - #11548
Conversation
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: ⛔ Files ignored due to path filters (2)
📒 Files selected for processing (3)
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 5 remain after this review. 📝 WalkthroughWalkthroughThe workspace dependency changes from perex 0.1.9 to 0.1.11. Both regex search paths now update the caller’s work budget from the remaining work when Changesperex upgrade and search handling
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~10 minutes Change: Other Merge Risk: ⚪ Minimal · up to The dependency and lockfiles are consistent, and no actionable issue remains. This change is mergeable after normal checks. Security Architecture ReviewSecurity architecture risk: 🔵 Low · up to An exact-pinned regex release is being adopted before the usual waiting period. Existing regex execution controls remain in place, and no new entrypoint or verified security defect was found, but the early adoption leaves some uncertainty about the new engine behavior. Retained concerns
Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
Resilience and Maintainability Implications
Hardening Proposals
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 1 files. (2 skipped: 2 unsupported.)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
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. Comment |
|
perex 0.1.11 is published (crates.io, tag v0.1.11, commit 80845f531 = perex#3 merged + version bump). It clears Perry's 7-day publish-age soak around 2026-10-04 21:40Z. Then this PR only needs the version bump from 0.1.10 to 0.1.11 and a re-measure. Measured with perex#3 patched in locally on top of #11543: jsonwebtoken decode −52%, uuid v4 −48%, v7 −30%, v5 parse −24%, nanoid −20%, RSS within 1%. |
perex 0.1.10's `Search::run` fails with `RunError { error, remaining_work,
buffers }`. Both call sites in `perex_runtime.rs` now set the budget from the
failed run's remaining work, where they used to keep the entry budget and
under-count what the failed call spent. Nothing observes that today, since
WORK is usize::MAX on these paths.
This is the adaptation the perex release carrying PerryTS/perex#3 (the
package-shaped repeat and class fast paths) needs. Taking that release is then
a version bump.
perex 0.1.11 carries PerryTS/perex#3: package-shaped repeats and classes leave the per-character phase loop. It has no public API change from 0.1.10, so this is a version bump. 0.1.11 was published 2026-09-27T21:13:35Z, inside the 7-day global-min-publish-age window. The owner approved a one-time override on 2026-09-28 for this version only. Cargo.lock was resolved once with CARGO_RESOLVER_INCOMPATIBLE_PUBLISH_AGE=allow, and the Cargo.toml comment records the approval, the publish time, and the sha256 the lock pins (4cacad0d...98a8), checked against the crates.io API. The soak window and .cargo/config.toml are unchanged. The Next App Route provider lock moves from perex 0.1.9 to 0.1.11 as well. Re-resolving it also adds perry-abi, which the provider's runtime already depends on on main but its lock predated.
c7ad9f6 to
8803718
Compare
Part of #10166
Moves Perry's regex engine from perex 0.1.9 (what
mainpins) to 0.1.11, which carries PerryTS/perex#3: package-shaped repeats and character classes leave the matcher's per-character phase loop.Search::runnow fails withRunError { error, remaining_work, buffers }. Both call sites inperex_runtime.rsrecord the work a failed run left instead of keeping the entry budget. Nothing observes this today, becauseWORKisusize::MAXon these paths.pub(super)items), so this step is a version bump.Publish-age override (owner-approved, one time)
perex 0.1.11 was published 2026-09-27T21:13:35Z, inside the 7-day
global-min-publish-agesoak in.cargo/config.toml. The owner approved a one-time override for this version on 2026-09-28. This follows the turnloop precedent (#10354):Cargo.lockwas resolved once withCARGO_RESOLVER_INCOMPATIBLE_PUBLISH_AGE=allow(cargo update -p perex --precise 0.1.11). The only lock change is perex's version and checksum.perex = "0.1.11"comment inCargo.tomlrecords the approval date, the publish time, the release commit (80845f5310, tag v0.1.11), and the sha256 that Cargo.lock pins:4cacad0d8fd77338345abb71e4f8372ce93bf0e9205d845940f8e789b3fc98a8. I checked that checksum againsthttps://crates.io/api/v1/crates/perex/0.1.11. The override lapses on its own on 2026-10-04..cargo/config.tomland the soak surfaces are unchanged. No gate checks Cargo.lock publish ages:soak-gate(scripts/soak/soak.mts --check) only checks config parity, and the soak skill's dated exclusions exist only for pnpm. So there is no exclusion entry to add. The Cargo.toml comment is the reviewable record.tests/release/packages/next-app-route/provider/Cargo.lockstill pinned perex 0.1.9. It moves to 0.1.11 under the same override. Re-resolving it also addsperry-abi, which the provider's runtime already depends on onmain, but that lock was older than the dependency.Measurements
Host: perrymaster (AMD Ryzen 7 7700X, shared, load 20–70 during runs; instruction counts do not depend on load). Both arms use plain
--release,cargo build -p perry -p perry-runtime-static -p perry-stdlib-static, withPERRY_NO_AUTO_OPTIMIZE=1andPERRY_RUNTIME_DIRpinned per arm. The main arm isorigin/mainat 2d1f1d7. The branch arm is this branch before its final rebase onto be39bbf; the 17 commits in between touch GC call-effects tables and the object spill store, not regex. I verified the arms differ: the runtime.asha256 changed (a23a544f… → 905281d5…) and the embedded crate paths readperex-0.1.9andperex-0.1.11respectively. Instructions come fromperf stat -e instructions:uas a two-N differential, per iteration, taken under/tmp/perry-bench-lock.d.Package workloads (
scripts/package_bench.py run --arms node,perry --modes instr,rss, Node 26.5.1). Every Perry output, in both arms, was byte-identical to Node's:The only regression outside noise is commander/parse_argv at +0.4%, about 13k instructions per iteration. All three reps agree (n2 is 19.73–19.74G on main against 19.80–19.81G here), so it is real, but it is small. dayjs/parse_format's +0.2% is inside that workload's rep spread.
Microbenchmarks, instructions per call (two-N, each N the median of 3; output identical to Node):
REGEX.test(/^(?:[0-9a-f]{8}-…)$/i)JWS_REGEX.test, 155-char token/^\d+$/.testPeak RSS (
/usr/bin/time, one n2 run, 5 reps interleaved main/branch, median): no workload moves outside its own rep spread. The largest medians are date-fns/format_add −10.9%, moment/parse_format −13.6%, moment/diff_duration +7.2%, validator/sanitize +6.9%, nanoid +4.8% and validator/batch +4.2%, but the reps of each arm overlap by tens of percent. I re-ran validator/batch, validator/sanitize and decimal.js/parse_sum at 10 reps, and they came out −0.2%, +0.1% and +0.2%. uuid, jsonwebtoken and dotenv are within ±1%. Micro RSS: uuid +0.1%, jws +7.5%,\d+−18.2%, all inside the spread of 14–24 MB. The matcher's scratch is unchanged, so no RSS change is expected, and none is measurable here.Tests (perrymaster)
RUST_TEST_THREADS=1 cargo test --release -p perry-runtime --lib -- perex split replace regex: 278 passed, 0 failed.run_parity_tests.shwithPERRY_SKIP_BUILD=1 PERRY_NO_AUTO_OPTIMIZE=1, filtersregex,regexp,split,replace,match, Node 26.5.1. 49 unique tests, includingtest_gap_regex_engine_package_shapes. Branch: 49/49 PASS. Main: 48 PASS, 1 COMPILE_FAIL (test_gap_regex_replace_dyn_regex_with_http). That compile failure is a harness artifact of the main arm, not a regression this PR fixes: it links the on-demandlibperry_ext_http.aarchive, which my copied main-arm runtime dir did not include. The PR body before this rewrite reported the same COMPILE_FAIL on main.scripts/gc_call_effects/regen.sh linux-x86_64 --checkon the rebased head (fresh build): the table is identical to the archives, so no regeneration is needed.cargo fmt --all -- --check: clean.scripts/check_file_size.sh: OK.scripts/run_lint_gates.sh(SKIP_COMPILE_GATES=1): 99 of 101 script gates passed. The 2 failures are known-red and not caused by this PR:Public benchmark evidence freshness(red onmain) andcargo xwin check(cargo-xwinis not installed on perrymaster).Not run: the full gap sweep, the auto-optimize arm, macOS, Windows (
cargo xwin),cargo test --workspace, and the fullperry-runtimetest suite (only the regex/split/replace/perex filter). The numbers were measured on the pre-rebase head. The rebase onto be39bbf brought in no regex changes, and after it I re-ran only the build and the call-effects check.Summary by CodeRabbit