Skip to content

NXT-20660: Fix error ts - #401

Open
dan-ichim-lgp wants to merge 2 commits into
feature/typescriptfrom
feature/NXT-20660
Open

dan-ichim-lgp wants to merge 2 commits into
feature/typescriptfrom
feature/NXT-20660

Conversation

@dan-ichim-lgp

@dan-ichim-lgp dan-ichim-lgp commented Sep 28, 2026 •

Copy link
Copy Markdown

Checklist

  • I have read and understand the contribution guide
  • A CHANGELOG entry is included
  • I have run automated testing and it is passed
  • Documentation was added or is not needed
  • This is an API breaking change

Issue Resolved / Feature Added

enact pack fails when the app depends on TypeScript 7. TypeScript 7 publishes only a version entry and does not expose the classic compiler API (createProgram). fork-ts-checker-webpack-plugin resolves typescript through pkg.main, that lookup throws MODULE_NOT_FOUND, and the pack command exits before the framework bundle is written.

A failure inside the dynamic import('chalk') chain was also swallowed. enact.js logs the exception and still exits 0, so CI treated the pack as successful.

Resolution

enact pack now skips type checking when the installed typescript package has no createProgram, and prints a warning. Apps on TypeScript 5.x still run fork-ts-checker-webpack-plugin as before.

Pack failures are returned through the promise chain and always exit with code 1, including when chalk has not loaded yet.

Additional Considerations

Links

NXT-20660

Comments

Enact-DCO-1.0-Signed-off-by: Dan Ichim (dan.ichim@lgepartner.com)

@dan-ichim-lgp dan-ichim-lgp self-assigned this Sep 28, 2026
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