Skip to content

fix: [SDK-4744] stop preserving stale package-lock.json in downstream sync - #140

Merged
sherwinski merged 1 commit into
mainfrom
sherwin/sdk-4744
Jun 3, 2026
Merged

sherwinski merged 1 commit into
mainfrom
sherwin/sdk-4744

Conversation

@sherwinski

Copy link
Copy Markdown
Contributor

One Line Summary

Stop patch-repo.sh from preserving package-lock.json during downstream sync so stale lockfiles get cleaned up.

Motivation

After migrating the shims to bun, the generated tarballs no longer contain a package-lock.json. But scripts/patch-repo.sh explicitly excluded package-lock.json from its cleanup step ("defensive measure"), so a stale lockfile committed in a downstream repo would survive every sync. This kept react-onesignal pinned to a vulnerable vitest@3.0.9, triggering a critical Dependabot alert (CVE-2026-47429 / GHSA-5xrq-8626-4rwp).

Scope

  • scripts/patch-repo.sh only: removes the ! -name "package-lock.json" exclusion from the cleanup find.
  • CHANGELOG.md is still preserved (generated by semantic-release, not in the tarball).
  • On the next sync, downstream repos with a leftover package-lock.json will have it deleted via git add -A.

Testing

  • bash -n scripts/patch-repo.sh passes (syntax OK).
  • Confirmed all generated outputs use bun.lock; nothing produces a package-lock.json for the synced shims.

Checklist

  • Removes the root cause of stale lockfiles surviving downstream syncs
  • No change to runtime/codegen output

… sync

After the bun migration the generated tarballs no longer contain a
package-lock.json, but patch-repo.sh excluded it from cleanup, leaving
stale lockfiles alive in downstream repos through every sync. This kept
react-onesignal pinned to a vulnerable vitest (CVE-2026-47429). Remove
the exclusion so syncs delete leftover lockfiles.
@sherwinski
sherwinski requested a review from fadi-george June 3, 2026 04:09
@sherwinski
sherwinski merged commit d54ee59 into main Jun 3, 2026
1 check passed
@sherwinski
sherwinski deleted the sherwin/sdk-4744 branch June 3, 2026 04:28
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.

2 participants