fix(review): derive repo-profile check publication from reviewCheckMode - #3044
Conversation
contributionWorkflow.gatePublishesCheck read the legacy gateCheckMode/ checkRunMode fields directly, but the actual runtime authority for whether the review check publishes is reviewCheckMode (#2852) -- so a repo with reviewCheckMode: "disabled" and a stale legacy gateCheckMode: "enabled" was reported as publishing a check it does not actually publish. Also guards deriveCommandsFromPackageJson's scripts parse against an array-valued scripts field.
|
Tip 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 ✅ Gittensory review result - approve/merge recommendedReview updated: 2026-07-04 10:14:43 UTC
✅ Suggested Action - Approve/Merge
Review summary
Review context
Contributor next steps
Signal definitions
🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by Gittensory, a quiet PR intelligence layer for OSS maintainers.
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3044 +/- ##
==========================================
- Coverage 96.10% 96.09% -0.01%
==========================================
Files 261 261
Lines 28872 28871 -1
Branches 10510 10509 -1
==========================================
- Hits 27746 27745 -1
Misses 492 492
Partials 634 634
🚀 New features to boost your workflow:
|
Summary
extractRepoProfile'scontributionWorkflow.gatePublishesCheckfield, but derived it from the legacygateCheckMode/checkRunModesettings fields directly instead ofreviewCheckMode— the actual runtime authority for whether the review check publishes (feat(selfhost): configurable review-check publish mode (required/visible/disabled) #2852). A repo withreviewCheckMode: "disabled"and a stale legacygateCheckMode: "enabled"was reported as publishing a check it does not actually publish.settings.reviewCheckMode !== "disabled", matching the settings resolver's own authority.reviewCheckMode-driven behavior across all three of its values (required,visible,disabled), including the exact stale-legacy-field scenario described above.deriveCommandsFromPackageJson'sscriptsparse now excludes array values (typeof [] === "object"in JS, so an array-valuedscriptsfield previously slipped past the object check), with a regression test.Scope
type(scope): short summaryConventional Commit format, for examplefix(api): restore profile access checks.CONTRIBUTING.mdand does not reintroduce GitHub Pages, VitePress,site/, orCNAME.Validation
git diff --checknpm run typechecknpm run test:coveragenpm run test:workersnpm run build:mcpnpm run test:mcp-packnpm run ui:openapi:checknpm run ui:lintnpm run ui:typechecknpm run ui:buildnpm audit --audit-level=moderateIf any required check was skipped, explain why:
test/unit/repo-profile.test.ts, 30/30 passing, confirmed 100% branch coverage onsrc/review/repo-profile.tsviavitest run --coverage --coverage.include) rather than the full suite, per this repo's convention of scoping local verification to the affected area for small fixes and letting CI verify the rest. Proved causality on both changes by reverting each fix and confirming its regression test fails, then restoring and confirming it passes.Safety
extractRepoProfileis not yet wired to a route.)UI Evidencesection below with screenshots. (N/A — no visible UI changes.)