Skip to content

revert: ship as CommonJS again (4.0.0) to unbreak aio app add extension - #68

Merged
AnujVishwakarma-src merged 1 commit into
adobe:mainfrom
AnujVishwakarma-src:APPBLD-4503-revert-to-cjs
Sep 16, 2026
Merged

AnujVishwakarma-src merged 1 commit into
adobe:mainfrom
AnujVishwakarma-src:APPBLD-4503-revert-to-cjs

Conversation

@AnujVishwakarma-src

Copy link
Copy Markdown
Contributor

Why

The ESM 3.x releases broke aio app add extension on the released aio-cli. The Template Registry installs this template at @latest (bypassing semver pins), and aio-cli-plugin-app-templates loads it with require() — which cannot instantiate an ESM generator, throwing Error: constructor is not a constructor.

What

Revert the source to CommonJS (the 2.0.0 tree) and publish as 4.0.0 so @latest is CJS again and add extension works. CI workflows kept as-is.

Validated: clean install resolves CJS hub 3.0.2 + yeoman-generator 5.10.0; npm test (unit + validation) passes.

🤖 Generated with Claude Code

The ESM 3.x releases broke 'aio app add extension' on the released aio-cli:
the Template Registry installs this template at @latest and app-templates
loads it with require(), which cannot instantiate an ESM generator
('constructor is not a constructor'). Revert the source to CommonJS (the
2.0.0 tree) and publish as 4.0.0 so @latest is CJS again.

Temporary until aio-cli-plugin-app-templates loads templates via import()
(adobe/aio-cli-plugin-app-templates#83) ships in a new aio-cli; this package
will then be re-migrated to ESM. generator-aio-app@10 keeps the ESM 3.1.0
via its ^3 range (unaffected by this major).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@codecov

codecov Bot commented Sep 16, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@AnujVishwakarma-src

Copy link
Copy Markdown
Contributor Author

/upload-coverage

@github-actions

Copy link
Copy Markdown

Coverage artifact not found. Re-run CI first, then comment /upload-coverage again.

@AnujVishwakarma-src
AnujVishwakarma-src merged commit cd4dc9e into adobe:main Sep 16, 2026
11 checks passed
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