- Notifications
You must be signed in to change notification settings - Fork2.6k
Open
Labels
Description
Current Behavior
NX fails to generate an Angular library due to vitest generator
Expected Behavior
NX correctly generates an Angular library.
GitHub Repo
No response
Steps to Reproduce
bunx nx generate @nx/angular:library --directory=libs/frontend/ui-footer --name=ui-footer --importPath=@hiking-downward/ui-footer --tags=scope:frontend,type:ui
Nx Report
NX Reportcomplete - copy this into the issue templateNode: 25.1.0OS: linux-x64Native Target: x86_64-linuxbun: 1.3.1nx: 22.1.0-beta.3@nx/js: 22.1.0-beta.3@nx/eslint: 22.1.0-beta.3@nx/workspace: 22.1.0-beta.3@nx/angular: 22.1.0-beta.3@nx/devkit: 22.1.0-beta.3@nx/eslint-plugin: 22.1.0-beta.3@nx/module-federation: 22.1.0-beta.3@nx/playwright: 22.1.0-beta.3@nx/rspack: 22.1.0-beta.3@nx/vite: 22.1.0-beta.3@nx/web: 22.1.0-beta.3@nx/webpack: 22.1.0-beta.3typescript: 5.9.3---------------------------------------Registered Plugins:@nx/playwright/plugin@nx/eslint/plugin---------------------------------------Community plugins:@analogjs/vite-plugin-angular: 2.0.0@analogjs/vitest-angular: 2.0.0@ngrx/signals: 20.1.0angular-eslint: 20.5.1---------------------------------------Cache Usage: 256.00 B / 5.00 GB
Failure Logs
NX Generating @nx/angular:library NX Invalid version. Must be a string. Gottype"object".TypeError: Invalid version. Must be a string. Gottype"object". at new SemVer (/home/mharmony/repos/HikingDownward/node_modules/semver/classes/semver.js:21:13) at major (/home/mharmony/repos/HikingDownward/node_modules/semver/functions/major.js:4:29) at vitestGeneratorInternal (/home/mharmony/repos/HikingDownward/node_modules/@nx/vite/src/generators/vitest/vitest-generator.js:33:42) at process.processTicksAndRejections (node:internal/process/task_queues:103:5) at async addVitest (/home/mharmony/repos/HikingDownward/node_modules/@nx/angular/src/generators/utils/add-vitest.js:9:5) at async addUnitTestRunner (/home/mharmony/repos/HikingDownward/node_modules/@nx/angular/src/generators/library/library.js:99:13) at async libraryGenerator (/home/mharmony/repos/HikingDownward/node_modules/@nx/angular/src/generators/library/library.js:53:5) at async /home/mharmony/repos/HikingDownward/node_modules/nx/src/command-line/generate/generate.js:240:26 at async handleErrors (/home/mharmony/repos/HikingDownward/node_modules/nx/src/utils/handle-errors.js:8:24) at async Object.handler (/home/mharmony/repos/HikingDownward/node_modules/nx/src/command-line/generate/command-object.js:13:22)
Package Manager Version
No response
Operating System
- macOS
- Linux
- Windows
- Other (Please specify)
Additional Information
No response