Dashboard › craft › Distillation
e7f449b6-eacc-4c7c-9082-73257eff30b3["a2fe144068eabad2c5a75b9cd29990c1","814c9fe9350955463f338824105365c2","6ab3bc16af531af9bdf98fbacd2a28df","274ffbe6b466711c15a077eb0d84a351","be5d87858545781b4445676109d8daf2","4e77f4fbaf5412a41f1c9046379edf80","7b71ab02cd0bf1ae2824edab484e28c5","f9aa0df153ef601bff78bfd62c1acf9a","ed86104a8d0949e3081ea15b1756fa73","ba9f069506057eb6556b329d1d733829","fa90d4531049958829519aef1b65081e","e1f6d1cedcca06991578cddca60ebee9","3a6d04d448a85cc5739616f976d07a3a","b7c85701c683715a92d3c7d07f9c72fc"]
Date: July 21, 2026
src/config.ts fails pnpm exec prettier --check, with message "Code style issues found in the above file. Run Prettier with --write to fix."docs/ is listed in .prettierignore (so docs warnings don't matter for CI) but flagged that src/config.ts is NOT ignored, so needed to confirm whether CI would actually fail on it.src/config.ts:342-343: old (multi-line) const firstPrefix =\n (githubTargets[0]?.tagPrefix as string | undefined) || ''; vs prettier-desired single line const firstPrefix = (githubTargets[0]?.tagPrefix as string | undefined) || '';pnpm format:check which maps to prettier --check ., and since src/config.ts is not prettier-ignored, this violation will fail CI. Assistant noted this matches a known project-lore trap where pnpm lint does not catch prettier formatting issues..prettierignore contents: coverage/, dist/, node_modules/, pnpm-lock.yaml, temp_*/, docs/, CHANGELOG.md, AGENTS.md. CHANGELOG.md entry has comment: it is auto-generated from PR descriptions by release tooling, and its markdown does not always conform to prettier's preferences (e.g. literal _* sequences from release-note titles that prettier wants escaped to \*); excluding it avoids re-formatting on every release cut. AGENTS.md entry has comment: auto-managed by "lore" (github.com/BYK/loreai) — formatting controlled by the lore daemon, not prettier. format:check script = prettier --check ..docs/ ignored (irrelevant to CI), but src/config.ts is not ignored, so CI will fail on it (issue labeled M1 in later review)./home/byk/Code/getsentry/craft/src/config.ts lines 336-365: function getGitTagPrefix() filters targets for name === 'github' into githubTargets, computes firstPrefix from githubTargets[0]?.tagPrefix, checks hasConflictingPrefix via .some() comparing each target's tagPrefix to firstPrefix, logs a warning via logger.warn if targets have differing tagPrefix values (message suggests using a separate .craft.yml per product for monorepos), returns firstPrefix./home/byk/Code/getsentry/craft/src/utils/version.ts lines 1-75: imports getGitTagPrefix from ../config. Defines semverRegex() (adapted from sindresorhus/semver-regex) matching \bv?(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)(?:-?([\da-z-]+(?:\.[\da-z-]+)*))?(?:\+([\da-z-]+(?:\.[\da-z-]+)*))?\b. Exports getVersion(text) (strips leading 'v'), isValidVersion(text), interface SemVer (major, minor, patch, pre?, build?), and parseVersion(text) mapping regex match groups to SemVer fields.getVersion() edge-case results: "cli@1.2.3"→"1.2.3", "mcp@2.0.0-dev.1"→"2.0.0-dev.1", "sentry-cli@10.20.30"→"10.20.30", "cli@v1.2.3"→"1.2.3", "foo2@1.2.3"→"1.2.3", "v2@1.2.3"→"1.2.3", "2.0@1.2.3"→"1.2.3", "abc1.2.3def"→null.findReleaseBranches divergence trace across branch/prefix combinations. Same-result cases: ["origin/release/1.2.3"] prefix="release"; ["origin/release/cli/1.2.3"] prefix="release/cli"; ["origin/releases/1.0.0"] prefix="release"; ["origin/foo/"] prefix="foo"; ["origin/release/mcp/2.0.0"] prefix="release/cli"; ["origin/prod/staging/1.0.0"] prefix="release"; ["origin/a/b/c/1.0.0"] prefix="release". Divergent cases: ["origin/release/cli/1.2.3"] prefix="release" → OLD matched exact {"ex":["origin/release/cli/1.2.3"],"fz":[]}, NEW matched nothing {"ex":[],"fz":[]}; ["origin/release/1.0.0","origin/release/cli/1.2.3"] prefix="release" → OLD matched both exact, NEW matched only origin/release/1.0.0.release/cli/1.2.3 vs bare prefix release). OLD logic took first N path segments as branch-prefix (over-matched release/cli/1.2.3 against bare release); NEW logic takes everything before the last / as branch-prefix (excludes it, distance 4). Assistant determined this is the INTENDED behavior change per reviewer BYK's comment (prefix should be opaque; a bare release run should not claim another product's release/cli/x branches) — a correctness improvement, not a regression.origin/foo/ (empty version) matches identically in OLD and NEW logic (both treat as degenerate match) — deemed harmless since such a branch can't be checked out to a real version.412b796.findReleaseBranches, adding try/catch in changelog.ts) are NOT committed — they exist only as unstaged working-tree changes across 5 files: docs/src/content/docs/targets/github.md, src/commands/__tests__/changelog-versioning-policy.test.ts, src/commands/changelog.ts, src/utils/__tests__/git.test.ts, src/utils/git.ts. Committed HEAD still has old segment-count logic and un-try/catch'd changelog.ts (contains a previously-flagged Bugbot Medium bug). Assistant reviewed the working-tree (intended) state but flagged that these files MUST be git add+committed before pushing/CI.src/config.ts:342-343 fails prettier --check → will fail CI's format:check job. Fix: run pnpm exec prettier --write src/config.ts.findReleaseBranches JSDoc comment at git.ts:213 is stale, still references old "segment" matching language instead of "everything before the last /"; m2 — fuzzy cross-product noise (release/cli vs release/mcp = edit distance 3) still fuzzy-matches per test at git.test.ts:288, deemed acceptable for a "did you mean" suggestion feature, not a bug; m3 — getGitTagPrefix conflict-check edge cases (zero github targets, all-empty tagPrefix) confirmed clean with no false warnings.parseGitBranchOutput (git.ts:206) filters lines containing ->, so origin/HEAD -> origin/main never reaches prefix-matching logic (verified via test at git.test.ts:194).lastSlash <= 0 guard (rather than === -1) correctly handles both no-slash branches (e.g. main → -1 → skip) and leading-slash-empty-prefix branches (e.g. /1.2.3 → 0 → skip); noted a legit branch can never hit lastSlash === 0 post remote-strip since the remote-strip regex ^[^/]+\/ guarantees content before the first slash.findConfigFile() and getGitTagPrefix(), falls back to tagPrefix='' on error (uses latest tag overall), logs at debug level (matching git.ts style pattern), and preserves the happy-path (valid config → normal getGitTagPrefix() call). Matches existing versioningPolicy pattern.getGitTagPrefix keeps first-target-with-warning approach (no half-implemented multi-target selector); github.md docs explicitly state per-product .craft.yml is the current model, flags multi-target-in-one-file ambiguity via a :::caution block, and documents a repo-wide "Latest" badge limitation via a :::note block.tsc --noEmit -p tsconfig.build.json → ✅ exit 0; pnpm test (targeted 3 files) → ✅ 53 passed; pnpm test (full) → ✅ 1067 passed, 1 skipped, 58 files; prettier --check (src) → ❌ failed on src/config.ts (M1); prettier --check (docs) → N/A (ignored via .prettierignore).git add+committed before push; (2) M1 — must run prettier --write src/config.ts to unblock CI. Assistant assessed underlying code logic as solid: opaque-prefix rewrite correct, sole behavioral divergence is the intended fix (not a regression), all edge cases (HEAD entries, leading/trailing slash, empty version, no-slash) handled correctly, try/catch fix correct, version extraction robust, and design remains consistent with deferred-workspaces decision. Recommended: after committing the 5 files and applying the prettier fix, PR is a clean merge.