fix(block-tools): keep the mark-stable script on the block facade - #1790
Merged
Conversation
The facade rule carried an unconditional `removeScript("mark-stable")`,
classifying the script as a pre-facade boilerplate leftover. It is not:
the engine-generated `.github/workflows/mark-stable.yaml` calls
`milaboratory/github-ci/.github/workflows/block-mark-stable.yaml@v4`,
which does `cd block && pnpm run mark-stable`. Blocks migrated to the new
layout lost the script, so their "Mark Platforma Block as Stable"
workflow fails with `ERR_PNPM_NO_SCRIPT Missing script: mark-stable`.
Drop the call, restoring what A-0013 specifies: the engine overwrites the
canonical build/check/prepublishOnly/do-pack scripts and leaves
block-specific scripts beyond that set alone. Covered by a refresh test
that asserts a pre-existing `mark-stable` survives.
🦋 Changeset detectedLatest commit: 976be34 The changes in this PR will be included in the next version bump. This PR includes changesets to release 4 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1790 +/- ##
==========================================
- Coverage 52.98% 52.98% -0.01%
==========================================
Files 412 412
Lines 21322 21321 -1
Branches 4761 4761
==========================================
- Hits 11298 11296 -2
+ Misses 8663 8661 -2
- Partials 1361 1364 +3 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
kevindetry-milaboratories
approved these changes
Aug 19, 2026
AStaroverov
enabled auto-merge
August 19, 2026 15:25
github-merge-queue
Bot
removed this pull request from the merge queue due to failed status checks
Aug 19, 2026
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.
Problem
Blocks migrated to the new project template fail their
Mark Platforma Block as Stableworkflow:Example: clonotype-browser run.
The facade rule carried an unconditional
removeScript("mark-stable")(tools/block-tools/src/structure/rules/block-package-json.ts), introduced in6ff3423b2with the rationale "Legacy script from the pre-facade boilerplate — gone in the slim facade" (comment later dropped in9b62f2cab).It is not boilerplate. The engine itself generates
.github/workflows/mark-stable.yaml(rules/root-ci.ts:47) fromtemplates/text/workflows/mark-stable.tpl.yaml, which calls the reusablemilaboratory/github-ci/.github/workflows/block-mark-stable.yaml@v4— and that workflow doescd "${BLOCK_PATH}"(defaultblock) followed bypnpm run mark-stable. So the structurer generates a workflow and then removes the script that workflow needs.The root
"mark-stable": "turbo run mark-stable"is not a substitute: CI never invokes it, and no package implements the turbo task declared inrules/root-turbo-json.ts:49.The removal also contradicts the spec. A-0013 (facade
package.json) defines the canonical scripts asbuild/check/prepublishOnly/do-packand states: "Block-specific scripts beyond the canonical four — engine leaves them."mark-stableis not mentioned anywhere in the facade project docs — no atom, no decision, no open question.Change
removeScript("mark-stable")from the facade rule (and the now-unused import).mark-stablesurvivesstructure refresh. Verified it fails on the current code and passes with the fix.pnpm run checkand all 257 structurer tests pass.Out of scope
clonotype-browser,clonotype-clustering,mixcr-clonotyping,mixcr-scfv-clonotyping,rarefaction,samples-and-data,antibody-tcr-lead-selection. This PR only stops the engine from removing it again; each block needs the line back. First one: chore: restore mark-stable script on the block facade platforma-open/clonotype-browser#45.mark-stableshould be engine-ensured on the facade (so refresh repairs those blocks automatically), or whether the whole mark-stable path should be retired now thatblock-tools publishadds the package to the stable channel unless--unstableis passed. Both are real options and need a decision + an atom; neither belongs in a regression fix.Greptile Summary
The PR stops
structure refreshfrom deleting a block facade’s pre-existingmark-stablescript and adds regression coverage for preservation.block/package representing the publishable block entry point; refresh now leaves its noncanonical author-defined scripts unchanged.mark-stablescript — a package script invoked by the generated stable-release workflow; this PR preserves an existing script but deliberately does not create or restore one.build,check,prepublishOnly, anddo-pack, whose commands remain managed by the structurer.mark-stable.block/; its contract is unchanged.Confidence Score: 5/5
The PR appears safe to merge, with no actionable defects identified in the changed behavior.
The rule now preserves the workflow-required facade script without changing canonical-script enforcement, and the regression test exercises the affected refresh path.
Important Files Changed
mark-stable, allowing noncanonical author scripts to survive package reconciliation.mark-stablecommand is preserved exactly.Reviews (1): Last reviewed commit: "fix(block-tools): keep the mark-stable s..." | Re-trigger Greptile
Context used: