Skip to content

chore(deps): bump @sasjs/lint to 2.5.0 + dependency refresh - #1466

Merged
allanbowe merged 6 commits into
mainfrom
chore/bump-deps-and-lint
Sep 7, 2026
Merged

allanbowe merged 6 commits into
mainfrom
chore/bump-deps-and-lint

Conversation

@sasjs-dev

@sasjs-dev sasjs-dev Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

Summary

Bumps @sasjs/lint 2.4.3 → 2.5.0 and @sasjs/core 4.68.1 → 5.2.4, plus updates all other dependencies to the latest compatible versions.

Runtime dependencies

Package From To
@sasjs/lint 2.4.3 2.5.0
@sasjs/core 4.68.1 5.2.4
dotenv 16.0.3 17.4.2
js-base64 3.7.5 3.9.3
jsdom 23.2.0 26.0.0
prompts 2.4.1 2.4.2

Follow-up patch bumps: 5.2.3 (mv_getjoblog error surfacing, mv_jobflow paramstring casing) and 5.2.4 (mp_abort _METAPERSON guard, mv_jobwaitfor uri truncation fix) — no CLI-facing changes; none of the affected macros are referenced by the CLI.

@sasjs/core v5 breaking changes are SAS-macro-level (mp_getddlmp_ds2ddl, mp_testservicemp_execute, mp_coretable removed, mcf_xxx insert_cmplib removed, mf_getuniquelibref maxtries removed, mp_abort type= removed). Verified the CLI source, mocks and test fixtures reference none of the affected macros — safe major bump for the CLI.

Held back (ESM-only, the CLI is CommonJS — a major bump breaks require): chalk 4.1.2, ora 5.4.1, yargs 17.6.2.
Held back (Node engine): jsdom 27+/30 need Node ≥ 22.22/24.

Dev dependencies

Package From To
jest, jest-cli, jest-environment-jsdom, babel-jest 29.4.3 30.5.1
@types/jest 29.4.0 30.0.0
jest-extended 3.2.4 4.0.2
ts-jest 29.0.5 29.4.12
typescript 4.9.5 5.9.3
@types/node 18.14.1 22.10.2
prettier 2.6.2 3.9.6
@babel/core, preset-env, preset-typescript 7.2x 7.29.7
ts-node, tslib, nodemon, util, @types/* minor bumps

Code changes required by the bumps

  • toThrowErrortoThrow (jest 30 removed the alias — 4 spec files, 6 call sites)
  • toBeCalledTimestoHaveBeenCalledTimes (jest 30 removed the alias — 1 spec file)
  • process.exit mock signatures widened to code?: string | number | null | undefined (new @types/node signature — 2 files)
  • 20 files reformatted by prettier 3 (nested-ternary indentation style; no semantic changes)

CI fixes included

  • run-tests.yml: wait for sasjs/server readiness (/SASjsApi/info poll, up to 5 min) before "Deploy SAS9 tests" — the deploy was hitting localhost:5000 0.9s after pm2 start, before the server was listening (startup race, unrelated to the bumps)

Verification (all run locally against this branch)

  • 84/84 test suites, 637/637 tests pass (jest --config=jest.config.js --bail=0)
  • npm audit --omit=dev --audit-level=low: 0 vulnerabilities
  • npm audit --audit-level=low (full tree incl. dev): 0 vulnerabilities
  • npm run build: 0 TypeScript errors
  • prettier --check: clean
  • npm run doc: documentation coverage 17% > 16% threshold
  • npm pack + global install + sasjs v works

sasjs-dev Bot added 2 commits September 4, 2026 12:53
Bumps @sasjs/lint 2.4.3 -> 2.5.0 (Em Dash gremlin, jest 30, clean
audit) and refreshes other dependencies to latest compatible versions:

Runtime:
- dotenv 16.0.3 -> 17.4.2
- js-base64 3.7.5 -> 3.9.3
- jsdom 23.2.0 -> 26.0.0
- prompts 2.4.1 -> 2.4.2

Dev:
- jest family 29.4.3 -> 30.5.1 (jest, jest-cli,
  jest-environment-jsdom, babel-jest, @types/jest)
- jest-extended 3.2.4 -> 4.0.2
- ts-jest 29.0.5 -> 29.4.12
- typescript 4.9.5 -> 5.9.3
- @types/node 18.14.1 -> 22.10.2
- @babel/* -> 7.29.7
- prettier 2.6.2 -> 3.9.6 (reformatted 20 files, nested ternary style)
- ts-node, tslib, nodemon, util, @types/* minor bumps

Held back (ESM-only, CLI is CommonJS): chalk 4.x, ora 5.x, yargs 17.x.
Held back (Node engine): jsdom 27+ needs Node 24+.

Test migrations for jest 30 / @types/node:
- toThrowError -> toThrow (4 files)
- toBeCalledTimes -> toHaveBeenCalledTimes (1 file)
- process.exit mock signature widened for new @types/node

Verified locally: 84/84 suites, 637/637 tests pass; npm audit 0
vulnerabilities (prod and full); build clean; prettier clean; doc
coverage 17% over 16% threshold.
The Test Package Install CI step runs 'npm version 5.0.0' itself;
having the field committed makes that step fail with
'npm error Version not changed'. Version is managed by
semantic-release, as on main.
@github-actions

github-actions Bot commented Sep 4, 2026

Copy link
Copy Markdown

Coverage report

Total coverage

Status Category Percentage Covered / Total
🟡 Statements 75.3% 3472/4611
🟡 Branches 62.86% 1415/2251
🟡 Functions 75.03% 700/933
🟢 Lines 83.85% 8855/10560

Status of coverage: 🟢 - ok, 🟡 - slightly more than threshold, 🔴 - under the threshold

Show files with reduced coverage 🔻

Reduced coverage

Status Filename Statements Branches Functions Lines
🟢 src/commands/compile/compileSingleFile.ts 95.83% (-2.08% 🔻) 84% (-4% 🔻) 100% 100%

Status of coverage: 🟢 - ok, 🟡 - slightly more than threshold, 🔴 - under the threshold

Report generated by 🧪jest coverage report action from 1ea349e

sasjs-dev Bot added 2 commits September 4, 2026 13:11
pm2 start returns as soon as the process is forked, not when the
server is listening. The deploy step hit http://localhost:5000
0.9 seconds after pm2 start and failed with 'An error occurred
while fetching server info'. Adds a polling loop (up to 5 minutes)
on the /SASjsApi/info endpoint, dumping pm2 logs on timeout.
Latest core release. The v5 breaking changes are SAS-macro-level
(mp_getddl -> mp_ds2ddl, mp_testservice -> mp_execute,
mp_coretable removed, mcf_xxx insert_cmplib removed,
mf_getuniquelibref maxtries removed, mp_abort type= removed) -
verified the CLI source, mocks and test fixtures reference none of
the affected macros, so the major bump is safe for the CLI.

Verified: 637/637 tests pass, audit 0 vulnerabilities (prod+full),
build clean, prettier clean.

@4gl-reviewer 4gl-reviewer Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed the full diff: dependency refresh (package.json, package-lock.json), Prettier reformatting across ~20 source files (ternary indentation, line wrapping), Jest 30 API migrations (toThrowError to toThrow, toBeCalledTimes to toHaveBeenCalledTimes), Node.js process.exit type updates (code?: number to code?: string | number | null | undefined), and a CI reliability improvement (wait-for-server step in .github/workflows/run-tests.yml).

Hardening checklist:

  • ignore-scripts=true in committed .npmrc: pass (also has save-exact=true)
  • Dependencies pinned to exact versions: pass
  • npm audit --audit-level=low in CI: pass
  • npm ci in CI: pass
  • Lockfile committed and updated: pass
  • No secrets in diff: pass
  • .gitignore covers .env, .env.*: pass

Code review:

  • .github/workflows/run-tests.yml:91 -- the wait-for-server step is well-implemented: polls http://localhost:5000/SASjsApi/info up to 60 times (5s intervals, 300s max), dumps pm2 logs on timeout, exits 1 on failure. Good reliability improvement.
  • src/commands/compile/compileSingleFile.ts:77 -- the ;( prefix added to (outputPathParts.pop(), outputPathParts.pop()) is Prettier ASI safety; the comma expression is pre-existing and functionally unchanged.
  • src/commands/lint/processLint.ts:204 -- the ;( prefix and ternary reformatting are Prettier changes; the pre-existing comma-operator structure (process.logger?.table called with only the mapped array, { head: ... } evaluated as comma operand) is unchanged. Not a PR-introduced issue.
  • src/types/command/spec/commandBase.spec.ts and src/utils/test.ts -- process.exit mock type widened to string | number | null | undefined to match newer @types/node. Correct migration.
  • @sasjs/core major bump (4.68.1 to 5.2.2) and jsdom major bump (23 to 26) -- CI passes.
  • CI passing (test runs green at node 22).

No blocking issues.

Patch release (published today): mv_getjoblog error-surfacing fixes
and mv_jobflow paramstring casing fix. No breaking changes; none of
the affected macros are referenced by the CLI.

Verified: 637/637 tests pass, audit 0 vulnerabilities (prod+full),
build clean.

@4gl-reviewer 4gl-reviewer Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed the diff (dependency refresh: TS 4->5, Jest 29->30, Prettier 2->3, jsdom 23->26; CI server-readiness step; .npmrc hardening verified, lockfile committed, npm ci + npm audit --audit-level=low in CI).

  • package.json:72 — "@sasjs/adapter": "^4.19.0" uses a caret range; pin to an exact version (e.g. "4.19.0") for reproducible installs, consistent with the other pinned deps and the repo's save-exact=true policy.
    1 finding above for review.

Patch release (published today): guard _METAPERSON symget in
mp_abort; stop fixed-length uri truncation in mv_jobwaitfor.
No breaking changes; none of the affected macros are referenced
by the CLI.

Verified: 637 tests pass (84 suites; 4 env-dependent suites
fail identically before and after the bump - seed-app archive
installs, doxygen, global CLI install), audit 0 vulnerabilities
(prod+full), build clean.
@allanbowe
allanbowe merged commit ad2971e into main Sep 7, 2026
2 checks passed
@allanbowe
allanbowe deleted the chore/bump-deps-and-lint branch September 7, 2026 12:15
sasjs-dev Bot added a commit to sasjs/vscode-extension that referenced this pull request Sep 7, 2026
4.20.2 released today from the merge of sasjs/cli#1466 (the
dependency-refresh PR: @sasjs/core 5.2.4, @sasjs/lint 2.5.0,
@sasjs/utils 3.6.2 + jest 30 toolchain). Lockfile-only refresh:
@sasjs/cli 4.20.1 -> 4.20.2, transitively @sasjs/core 4.68.1 ->
5.2.4, @sasjs/lint 2.4.3 -> 2.5.0, @sasjs/utils 3.5.2 -> 3.6.2.

No CLI API changes in 4.20.2 (dependency-only release); the
extension deep-imports @sasjs/cli/build/commands - verified
compile clean, unit tests 10/10, lint 0 errors, esbuild bundle
clean.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant