fix(build): externalize lazily-imported optional drivers (unbreak main from #1524)#1525
Merged
Merged
Conversation
…n from #1524) #1524 moved optional internal @objectstack peerDependencies off `peer`; tsup then bundled the lazily await-import()'d driver packages and hit their optional native deps (mysql/oracledb via knex) → build failure for service-datasource & plugin-dev. - service-datasource: tsup `external: [/^@objectstack\/driver-/]` (drivers stay devDeps for tests, never bundled). - plugin-dev: framework packages devDeps → dependencies (tsup auto-externalizes deps; dev-only plugin, force-install is fine). Verified: full `pnpm build` 71/71 green; `changeset status` still 0 major (7.6.0). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Unbreaks
main: #1524 (the fixed-group major-cascade fix) moved optional internal@objectstack/*peerDependencies offpeer, after which tsup stopped auto-externalizing them and began bundling the lazilyawait import()-ed driver packages — pulling in their optional native clients (mysql/oracledbviaknex) and failing the build forservice-datasourceandplugin-dev.Fix
@objectstack/driver-*in tsup (drivers stay devDeps for tests, never bundled — preserves their optionality).dependencies(tsup auto-externalizes deps; dev-only plugin, so hard deps are fine).Neither re-introduces the major cascade (regular deps/devDeps don't cascade; only peerDeps did).
Verification
Full
pnpm build71/71 green;changeset statusstill 0 major (next release 7.6.0).🤖 Generated with Claude Code