Skip to content

fix(ci): make the release dispatchable - #278

Merged
allanbowe merged 2 commits into
mainfrom
fix/dispatchable-release
Oct 5, 2026
Merged

allanbowe merged 2 commits into
mainfrom
fix/dispatchable-release

Conversation

@sasjs-dev

@sasjs-dev sasjs-dev Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

What

Adds workflow_dispatch to the publish workflow.

On 2026-10-05 the merge of #277 produced no workflow run at all - no run, no check run - so nothing was published. This workflow triggers on push to main only, which means there was no way to trigger the release by hand either: no dispatch, and re-running the previous run would re-analyse at the older commit rather than at the merge.

workflow_dispatch makes the release reachable from the Actions UI or the API when the push trigger does not fire. It does not change what a release does - semantic-release computes the version from the commits since the last tag either way.

This is a workaround, and the real problem is still open

This repo has stopped scheduling workflow runs. Evidence:

The same pattern affects sasjs/adapter: its pull_request runs stop after 15:38 while the dynamic PR workflow still runs. Both repos have no rulesets configured, and the installation token gets 403 on the Actions permission endpoints, so the cause is not visible from here.

It needs someone with admin to look at the two repos' Actions settings. This change at least means a missed release can be recovered rather than being stranded - which is what happened here.

Verification

  • the workflow file parses as YAML
  • the only change is the on: block; no job, step or permission moved

Folded in: the coverage gate

CI on this PR failed on coverage, and it could not go green without this, so it is here rather than in a separate PR:

Jest: Uncovered count for statements (16) exceeds global threshold (10)

All 440 tests passed - it was the gate, not a test. The uncovered lines in target.ts were exactly 341, 347, 353, 359, 369, 379, 389 and 400: the eight else if (withDefaults) branches, one per inserted default. Flipping toJson's default to false in #277 left them unexercised, because no spec passed true any more.

A new case asserts the escape hatch still does what it says - the four mandatory attributes plus the eight inserted defaults - which is what a caller passing true, and the CLI's saveWithDefaultValues flag, relies on.

Verified with the command CI actually runs: npx jest --config=jest.config.js --coverage - 39 suites, 441 tests pass, no threshold error. I had only run bare npx jest locally before, which is why this reached CI.

sasjs-dev Bot added 2 commits October 5, 2026 22:18
The merge of #277 produced no workflow run at all - no run, no check run - so
nothing was published, and there was no way to trigger it by hand: this workflow
triggers on `push` to main only, and that push produced nothing.

`workflow_dispatch` makes the release reachable from the Actions UI or the API
when the push trigger does not fire. It changes nothing about what a release
does - semantic-release computes from the commits since the last tag either way.

This is a workaround rather than the fix. The underlying problem is that this
repo has stopped scheduling workflow runs: its most recent run is from 19:31,
while cli, vscode-extension, test-framework and sas-language all triggered
normally at the same moments. That needs someone with admin access to diagnose.
What this does is ensure a missed release can be recovered instead of being
stranded.

Verification: the workflow file parses as YAML, and the only change is the
trigger block.
Flipping `toJson`'s default to false left the eight `else if (withDefaults)`
branches uncovered, because no spec passed `true` any more. This repo gates on
coverage, so CI failed on it:

    Jest: Uncovered count for statements (16) exceeds global threshold (10)

All 440 tests passed - it was the gate, not a test. The uncovered lines were
exactly 341, 347, 353, 359, 369, 379, 389 and 400, one per injected default.

The new case asserts the escape hatch still does what it says: the four
mandatory attributes plus the eight inserted defaults, which is what a caller
passing `true` - and the CLI's `saveWithDefaultValues` flag - relies on.

Verification: npx jest --config=jest.config.js --coverage - 39 suites, 441 tests
pass, no threshold error; npx tsc --noEmit clean; npm run lint clean.
@allanbowe
allanbowe merged commit bf2f677 into main Oct 5, 2026
2 checks passed
@allanbowe
allanbowe deleted the fix/dispatchable-release branch October 5, 2026 22:42
sasjs-gha Bot pushed a commit that referenced this pull request Oct 5, 2026
## [3.7.1](v3.7.0...v3.7.1) (2026-10-05)

### Bug Fixes

* **ci:** make the release dispatchable ([#278](#278)) ([bf2f677](bf2f677)), closes [#277](#277)
* **utils:** drop the Node crypto import, and tighten what the package ships ([#274](#274)) ([0f79733](0f79733))
* **utils:** insert no config a target does not declare, and reject release-suppressing markers ([#277](#277)) ([58baebb](58baebb)), closes [#274](#274)
@sasjs-gha

sasjs-gha Bot commented Oct 5, 2026

Copy link
Copy Markdown

🎉 This PR is included in version 3.7.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant