R/WhenFirstHit.R:31-33 — gsub(pattern, "\\1", ...) is not anchored, so a tree/replicate name that merely contains the stage pattern (rather than matching it as a whole segment) keeps surrounding text in the extracted label, producing a spurious/garbled stage name instead of a clean one.
Verified REAL (haiku verifier, code-read).
Fix: anchor the regex (e.g. with ^/$ or word boundaries) so it matches the intended segment only.
Filed by /red-team area 14 (opus finder, 2026-08-05).
R/WhenFirstHit.R:31-33—gsub(pattern, "\\1", ...)is not anchored, so a tree/replicate name that merely contains the stage pattern (rather than matching it as a whole segment) keeps surrounding text in the extracted label, producing a spurious/garbled stage name instead of a clean one.Verified REAL (haiku verifier, code-read).
Fix: anchor the regex (e.g. with
^/$or word boundaries) so it matches the intended segment only.Filed by /red-team area 14 (opus finder, 2026-08-05).