From d0fdc55b6e1005f74c9f550f689095f6ca07b997 Mon Sep 17 00:00:00 2001 From: Chukwuemeka Date: Thu, 24 Sep 2026 16:14:11 +0200 Subject: [PATCH 1/3] fix(sync-actions): use correct `Counter` literal for skipConfiguration type `@commercetools/platform-sdk` declares the skip configuration discriminator as the string literal `'Counter'`, but the recurring orders test used lowercase `'counter'`, failing `tsc` with TS2322. The breakage surfaced after the dependency bump in b2bfcf7 resolved `sync-actions`' `"@commercetools/platform-sdk": "latest"` to 9.4.0. Co-Authored-By: Claude Opus 5 (1M context) --- packages/sync-actions/test/recurring-orders-sync.spec.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/sync-actions/test/recurring-orders-sync.spec.ts b/packages/sync-actions/test/recurring-orders-sync.spec.ts index ba0bc0d..c16612a 100644 --- a/packages/sync-actions/test/recurring-orders-sync.spec.ts +++ b/packages/sync-actions/test/recurring-orders-sync.spec.ts @@ -129,11 +129,11 @@ describe('Actions', () => { test('should build `setOrderSkipConfiguration` action', () => { const before: Partial = { - skipConfiguration: { type: 'counter', totalToSkip: 2, skipped: 1 }, + skipConfiguration: { type: 'Counter', totalToSkip: 2, skipped: 1 }, }; const now: Partial = { skipConfiguration: { - type: 'counter', + type: 'Counter', totalToSkip: 5, skipped: 0, }, From ca67eb41a2188ccc54e971828923d8ee76c573c8 Mon Sep 17 00:00:00 2001 From: Chukwuemeka Date: Thu, 24 Sep 2026 16:21:52 +0200 Subject: [PATCH 2/3] chore(sync-actions): replace `latest` platform-sdk range with `^9.4.0` `"@commercetools/platform-sdk": "latest"` re-resolved to a new version on every lockfile refresh, silently crossing major boundaries and bypassing the `dependencyDashboardApproval` gate Renovate applies to major updates. That is how the 8.x -> 9.x jump landed unreviewed and broke `tsc` on main. A caret range matches the other workspaces (`^8.9.0`) and lets Renovate manage updates through reviewable PRs. Lockfile now resolves to 9.5.0; typecheck and the full sync-actions suite (45 suites, 732 tests) pass against it. Co-Authored-By: Claude Opus 5 (1M context) --- packages/sync-actions/package.json | 2 +- yarn.lock | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/sync-actions/package.json b/packages/sync-actions/package.json index ee85057..b873c68 100644 --- a/packages/sync-actions/package.json +++ b/packages/sync-actions/package.json @@ -28,7 +28,7 @@ "test": "jest --runInBand" }, "dependencies": { - "@commercetools/platform-sdk": "latest", + "@commercetools/platform-sdk": "^9.4.0", "esbuild": "^0.25.4", "fast-equals": "^2.0.0", "jest": "^29.7.0", diff --git a/yarn.lock b/yarn.lock index 6673cbb..f651893 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1826,12 +1826,12 @@ __metadata: languageName: node linkType: hard -"@commercetools/platform-sdk@npm:latest": - version: 9.4.0 - resolution: "@commercetools/platform-sdk@npm:9.4.0" +"@commercetools/platform-sdk@npm:^9.4.0": + version: 9.5.0 + resolution: "@commercetools/platform-sdk@npm:9.5.0" dependencies: "@commercetools/ts-client": "npm:^5.0.2" - checksum: 10c0/994ee28f20f1c607a56f98136ff71a2b317363ff755518fc398433ae704966e92faaa09752c4c3d6eecb4b10b437fa5e56815e4960c24cf910c32394991cee99 + checksum: 10c0/738d841844dce697cd90d3cac647f577eb347a61d74dd3d4be8591d3d4766807be26c0b584a7910869ceaff3b25796470d41e906da69ccf843e950c5b10c8333 languageName: node linkType: hard @@ -1864,7 +1864,7 @@ __metadata: version: 0.0.0-use.local resolution: "@commercetools/sync-actions@workspace:packages/sync-actions" dependencies: - "@commercetools/platform-sdk": "npm:latest" + "@commercetools/platform-sdk": "npm:^9.4.0" esbuild: "npm:^0.25.4" fast-equals: "npm:^2.0.0" jest: "npm:^29.7.0" From ba27b2af071db480b31eace6d31b6b137a7e4f0c Mon Sep 17 00:00:00 2001 From: Chukwuemeka Date: Thu, 24 Sep 2026 16:38:11 +0200 Subject: [PATCH 3/3] docs(changeset): note the platform-sdk range change Add a patch changeset so the `latest` -> `^9.4.0` move is recorded in the published CHANGELOG for @commercetools/sync-actions. Co-Authored-By: Claude Opus 5 (1M context) --- .changeset/pin-platform-sdk-range.md | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 .changeset/pin-platform-sdk-range.md diff --git a/.changeset/pin-platform-sdk-range.md b/.changeset/pin-platform-sdk-range.md new file mode 100644 index 0000000..5ba6b4c --- /dev/null +++ b/.changeset/pin-platform-sdk-range.md @@ -0,0 +1,9 @@ +--- +'@commercetools/sync-actions': patch +--- + +Replace the `latest` version range for `@commercetools/platform-sdk` with `^9.4.0`. + +The `latest` descriptor re-resolved on every lockfile refresh and crossed major boundaries without review, which is how the 8.x to 9.x upgrade landed unannounced. A caret range matches the other packages in this repository and routes future updates through reviewable dependency PRs, with major upgrades gated behind explicit approval. + +This is a dependency-declaration change only. The public API and observable behavior of `@commercetools/sync-actions` are unchanged.