Repository navigation
fix: correct regex over-matching - #9
Open
NormandErwan wants to merge 9 commits into
Open
NormandErwan wants to merge 9 commits into
NormandErwan wants to merge 9 commits into
Conversation
- XrefMapService: narrow ZeroStringsRegex from `(\d):` to `\b0:` so
only the YAML-crashing `0:` pattern is stripped, not every digit
before a colon; update replacement from "$1" to "0" (no capture group)
- Utils.RunCommand: return process.ExitCode so callers can observe
non-zero results
- BuildCommand: check DocFX exit code and log/continue on failure
- unity-xref-maps.yml: paginate Unity Releases API with offset loop to
avoid silent truncation at limit=25; propagate dotnet tool exit code
with `if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }`
https://claude.ai/code/session_0145GzJVvweE69KcFn9j1WWB
…codes" This reverts commit ee77abc.
XrefMapServiceTests: - Load_ZeroColonAtWordBoundary_IsStripped: verifies `0: value` (which would crash the YAML deserializer) is pre-processed correctly - Load_NonZeroDigitColon_IsPreserved: verifies that `data1:field` in a string value keeps its colon; the old `(\d):` regex stripped it UtilsTests: - RunCommand_SuccessfulProcess_ReturnsZero / _FailingProcess_ReturnsNonZero: verify that RunCommand surfaces the process exit code; both tests fail to compile against the unfixed code because RunCommand returned void https://claude.ai/code/session_0145GzJVvweE69KcFn9j1WWB
- XrefMapService: narrow ZeroStringsRegex from `(\d):` to `\b0:` so
only the YAML-crashing `0:` pattern is stripped, not every digit
before a colon; update replacement from "$1" to "0" (no capture group)
- Utils.RunCommand: return process.ExitCode so callers can observe
non-zero results
- BuildCommand: check DocFX exit code and log/continue on failure
- unity-xref-maps.yml: paginate Unity Releases API with offset loop to
avoid silent truncation at limit=25; propagate dotnet tool exit code
with `if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }`
https://claude.ai/code/session_0145GzJVvweE69KcFn9j1WWB
bdovaz
added this pull request to stack #17
October 15, 2026 09:46
Copilot AI
added a commit
that referenced
this pull request
Oct 15, 2026
- Change Utils.RunCommand return type from Task to Task<int> to return process exit code - Capture exit code from DocFX command in BuildCommand - Check if exit code is non-zero and skip further processing if DocFX fails - Log error message with exit code when DocFX fails Fixes: Extract changes from PR #9 Co-authored-by: bdovaz <950602+bdovaz@users.noreply.github.com>
bdovaz
added a commit
that referenced
this pull request
Oct 15, 2026
- Change Utils.RunCommand return type from Task to Task<int> to return process exit code - Capture exit code from DocFX command in BuildCommand - Check if exit code is non-zero and skip further processing if DocFX fails - Log error message with exit code when DocFX fails Fixes: Extract changes from PR #9 Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: bdovaz <950602+bdovaz@users.noreply.github.com>
bdovaz
force-pushed
the
claude/fix-xrefmaps-audit-issues-8Tvrf
branch
from
October 15, 2026 12:23
a72497e to
7ddc8fb
Compare
- XrefMapService: narrow ZeroStringsRegex from `(\d):` to `\b0:` so
only the YAML-crashing `0:` pattern is stripped, not every digit
before a colon; update replacement from "$1" to "0" (no capture group)
- Utils.RunCommand: return process.ExitCode so callers can observe
non-zero results
- BuildCommand: check DocFX exit code and log/continue on failure
- unity-xref-maps.yml: paginate Unity Releases API with offset loop to
avoid silent truncation at limit=25; propagate dotnet tool exit code
with `if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }`
https://claude.ai/code/session_0145GzJVvweE69KcFn9j1WWB
…codes" This reverts commit ee77abc.
XrefMapServiceTests: - Load_ZeroColonAtWordBoundary_IsStripped: verifies `0: value` (which would crash the YAML deserializer) is pre-processed correctly - Load_NonZeroDigitColon_IsPreserved: verifies that `data1:field` in a string value keeps its colon; the old `(\d):` regex stripped it UtilsTests: - RunCommand_SuccessfulProcess_ReturnsZero / _FailingProcess_ReturnsNonZero: verify that RunCommand surfaces the process exit code; both tests fail to compile against the unfixed code because RunCommand returned void https://claude.ai/code/session_0145GzJVvweE69KcFn9j1WWB
- XrefMapService: narrow ZeroStringsRegex from `(\d):` to `\b0:` so
only the YAML-crashing `0:` pattern is stripped, not every digit
before a colon; update replacement from "$1" to "0" (no capture group)
- Utils.RunCommand: return process.ExitCode so callers can observe
non-zero results
- BuildCommand: check DocFX exit code and log/continue on failure
- unity-xref-maps.yml: paginate Unity Releases API with offset loop to
avoid silent truncation at limit=25; propagate dotnet tool exit code
with `if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }`
https://claude.ai/code/session_0145GzJVvweE69KcFn9j1WWB
…ub.com/NormandErwan/UnityXrefMaps into claude/fix-xrefmaps-audit-issues-8Tvrf
bdovaz
removed this pull request from stack #17
October 15, 2026 12:36
bdovaz
marked this pull request as ready for review
October 15, 2026 12:38
This branch has not been deployed
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.
What was wrong and what changed
Regex stripping too many characters from xref map files
The code was removing the colon from any digit-colon sequence (
0:,1:,2:, …) in the raw YAML before parsing, even though only0:is problematic (YAML treats it as a mapping key).For example, a reference like
"SomeType.Method(Int32):SomeParam"would have its2:silently stripped to"SomeType.Method(Int32)SomeParam", producing a wrong href.Fix: the regex now only matches
0:, leaving all other digit-colon sequences untouched.Test plan
dotnet build --configuration Releasecompiles without errorsdotnet testpassesunity-xref-mapsworkflow manually and confirm versions beyond 25 appear in the matrixhttps://claude.ai/code/session_0145GzJVvweE69KcFn9j1WWB