fix: address the three pre-release sweep findings - #1246
Merged
Conversation
Three real, new-in-range bugs from the free-hunt regression sweep: - The pinpoint anchor builder ran a document-wide uniqueness query per ancestor against a growing selector with no depth cap, so one click on a deeply wrapped document froze the tab synchronously (measured 58s at depth 800). The walk now abandons the anchor past 40 ancestors (fail closed: text-search restoration takes over), bounding the work to interactive time. Regression test uses two identical depth-60 chains so uniqueness cannot short-circuit before the cap. - The 10k selection-text cap sliced UTF-16 code units and could split a surrogate pair at the boundary, silently corrupting the annotation tail into U+FFFD downstream. Both sides of the bridge now back the cut off one unit when it would land mid-pair. - The old-git sparse fallback matched git's "unknown option" error literally, which localized git builds translate, so non-English users on old git hit the exact hard failure #1239 was written to fix. All three installers now pin LC_ALL=C around the probe clone (saved and restored; kept single-line in install.ps1 for the scoped-call scanner, whose expectation is updated to the new prefix).
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.
TLDR: The three-agent creative sweep before v0.26.5 found three real, reproducible, new-in-range bugs: a tab-freezing quadratic walk in the pinpoint anchor builder (blocker), surrogate-pair corruption at the 10k truncation boundary, and an English-only error match that re-breaks the old-git installer fallback for non-English locales. All fixed with regression tests.
AI-assisted (sweep findings, fixes, and this PR).
slice(0, 10000)could cut an astral character in half, leaving a lone high surrogate that becomes a replacement character in drafts, feedback, and share URLs. The cut now backs off one unit at a pair boundary, on both sides of the iframe bridge.--sparsecapability probe greps for the literal "unknown option", which NLS git builds localize. All three scripts now run the probe clone underLC_ALL=C(saved and restored), so the fallback fires regardless of the user's locale.Verified: html-viewer suite 34/34 (two new regression tests), install tests 126/126, full DOM suite 932/932, typecheck clean, review app builds.