Conversation
@contentstack/cli and @contentstack/cli-utilities compile with importHelpers: true, so their emitted output requires tslib at runtime. tslib was listed under devDependencies (cli) or not at all (cli-utilities), so consumers never receive it and a global install fails with "Cannot find module 'tslib'". Verified against the published v1-x tarballs: @contentstack/cli 1.68.0 has 3 files requiring tslib, @contentstack/cli-utilities 1.19.2 has 26, neither declaring it. cli-auth, cli-command and cli-config emit zero tslib requires and are deliberately left unchanged. Mirrors PR #2722, which fixed the same defect on the v2 line. Also switches the .talismanrc pnpm-lock.yaml entry from a checksum pin to ignore_detectors, so lockfile regeneration no longer invalidates it. Refs: #2629 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
🔒 Security Scan Results
⏱️ SLA Breach Summary
ℹ️ Vulnerabilities Without Available Fixes (Informational Only)The following vulnerabilities were detected but do not have fixes available (no upgrade or patch). These are excluded from failure thresholds:
Consider reviewing these vulnerabilities when fixes become available. |
Upgrades @contentstack/cli-utilities dependencies and the workspace-level pnpm overrides. packages/contentstack-utilities: @contentstack/management ~1.30.1 -> ~1.31.1 @contentstack/marketplace-sdk ^1.5.1 -> ^1.5.4 axios ^1.19.0 -> ^1.20.0 js-yaml ^4.3.1 -> ^4.3.2 picomatch (@oclif/core override) ^4.0.4 -> ^4.0.7 pnpm-workspace.yaml overrides: uuid 14.0.1 -> 14.0.2 brace-expansion 5.0.9 -> 5.0.12 js-yaml 5.2.3 -> 5.4.2 fast-uri 4.1.2 -> 4.2.1 snyk test --all-projects --fail-on=all reports 6 projects with no vulnerable paths. pnpm install --frozen-lockfile and pnpm build both pass, and the tslib runtime dependency added in the preceding commit is unaffected. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
🔒 Security Scan Results
⏱️ SLA Breach Summary
ℹ️ Vulnerabilities Without Available Fixes (Informational Only)The following vulnerabilities were detected but do not have fixes available (no upgrade or patch). These are excluded from failure thresholds:
Consider reviewing these vulnerabilities when fixes become available. |
Problem
@contentstack/cliand@contentstack/cli-utilitiescompile withimportHelpers: true, so their emitted output callsrequire("tslib")at runtime. Neither declarestslibas a runtime dependency — it sits indevDependenciesfor@contentstack/cliand is absent entirely from@contentstack/cli-utilities.Consumers do not install devDependencies, so a global install fails:
pnpm add -g @contentstack/cli csdx --help # [MODULE_NOT_FOUND] ... /lib/help.js: Cannot find module 'tslib'It is masked in local development because
.npmrcsetsshamefully-hoist=true, which hoiststslibsomewhere resolvable. That setting is not published, so it does not help users.Reported as #2629, filed against 1.64.0 — a v1 release.
Evidence
Each published
v1-xtarball was downloaded from the npm registry and its shippedlib/output grepped forrequire("tslib"), then compared against that tarball's ownpackage.json. These are the artifacts users actually install, not source-tree inference.tslib@contentstack/cli@contentstack/cli-utilitiescli-utilitiesis the more severe of the two: it is a runtime dependency of@contentstack/cliitself, so it reaches every user.Deliberately unchanged
cli-auth,cli-commandandcli-configemit zerotslibreferences of any form (require("tslib"),require('tslib'),from "tslib"), verified against their published tarballs, which contain real compiled output (13, 2 and 25.jsfiles respectively). All packages targetes2017, where async/await is native, so only packages using spread/rest/decorators emit helpers.This differs deliberately from #2722, which added
tslibto all five packages on the v2 line.Second commit: dependency upgrades
ef64d7269upgrades dependencies and workspace overrides, independent of thetslibfix.packages/contentstack-utilities@contentstack/management@contentstack/marketplace-sdkaxiosjs-yamlpicomatch(@oclif/coreoverride)pnpm-workspace.yamloverridesuuidbrace-expansionjs-yamlfast-uriReviewer note:
@contentstack/managementandaxiosare minor-version upgrades rather than patches, andjs-yamlmoves across two majors at the override level (5.2.3 → 5.4.2). Those warrant more scrutiny than thetslibchange itself.Verification
pnpm install --frozen-lockfilepasses — lockfile and manifests agreepnpm buildpassessnyk test --all-projects --fail-on=allreports 6 projects, no vulnerable pathspnpm packofcli-utilitiesproduces an artifact with 28 files requiringtslibanddependencies.tslib: ^2.8.1present — verified at the same level the bug was foundtslibconfirmed intact in both packages after the dependency upgradesAlso included
.talismanrc'spnpm-lock.yamlentry moves from a checksum pin toignore_detectors. The pinned checksum was already stale and blocked committing any lockfile change; this stops it recurring.Notes
developmentand was never backported.cli-pluginsrepo.Refs: #2629
🤖 Generated with Claude Code