infinitered / ignite

Infinite Red's battle-tested React Native project boilerplate, along with a CLI, component/model generators, and more! 9 years of continuous development and counting.
MIT License
17.74k stars 1.4k forks source link

Error while initializing a new project choosing expo router #2831

Closed AAndonio closed 1 week ago

AAndonio commented 3 weeks ago

Describe the bug

I tried to create a new project and had the following output and error. If I not choose to use expo router the project is created without any problem.

✅ What bundle identifier? · com.antonio.ignitexample ✅ Where do you want to start your project? · /home/antonio/Projects/ignite-example ✅ Directory /home/antonio/Projects/ignite-example already exists. Do you want to overwrite it? (y/N) · Yes ✅ How do you want to manage Native code? · cng ✅ Do you want to initialize a git repository? (Y/n) · Yes ✅ Remove demo code? We recommend leaving it in if it's your first time using Ignite (y/N) · No ✅ Which package manager do you want to use? · npm ✅ Do you want to install dependencies? (Y/n) · Yes ✅ [Experimental] Expo Router for navigation? (y/N) · Yes ✅ [Experimental] the New Architecture? (y/N) · Yes

/ascii/

█ Creating IgniteExample using Ignite 10.0.3
█ Powered by  ∞ Infinite Red  (https://infinite.red)
█ Package Manager: npm
█ Bundle identifier: com.antonio.ignitexample
█ Path: /home/antonio/Projects/ignite-example
────────────────────────────────────────────────────

🗑️  Tossing that old app like it's hot
🖨  3D-printing a new React Native app
🎨 Getting those last few details perfect
🧶 Installing npm dependencies (wow these are heavy)
⚙️ Configuring app.json
❌ Generating native template via Expo Prebuild

The following error occurred:

Git status is dirty but the command will continue because the terminal is not interactive.

Warning: Root-level "expo" object found. Ignoring extra keys in Expo config: "name", "displayName", "ignite" Learn more: https://expo.fyi/root-expo-object CommandError: Cannot find module 'ajv/dist/compile/codegen' Require stack:

Ignite version

10.0.3

Additional info

System platform linux arch x64 cpu 8 cores 11th Gen Intel(R) Core(TM) i7-1165G7 @ 2.80GHz directory ignite-example /home/antonio/Projects/ignite-example

JavaScript (and globally-installed packages) node 20.18.0 /home/antonio/.nvm/versions/node/v20.18.0/bin/node npm 10.8.2 /home/antonio/.nvm/versions/node/v20.18.0/bin/npm corepack 0.29.3 npm 10.8.2 yarn - not installed pnpm - not installed bun 1.1.31 /usr/bin/bun expo 51.0.38 managed

Ignite ignite-cli 10.0.3 /home/antonio/.npm/_npx/bec2839915ba8fc3/node_modules/.bin/ignite ignite src build /home/antonio/.npm/_npx/bec2839915ba8fc3/node_modules/ignite-cli/build

Android java 17.0.8 /home/antonio/.sdkman/candidates/java/current/bin/java android home - /home/antonio/Android/Sdk

Tools git git version 2.46.1 /usr/bin/git

frankcalise commented 3 weeks ago

@AAndonio thanks for the report. currently an npm issue, will look to resolve this.

for now as a workaround you can utilize yarn or bun as the package manager and things should work out for you

frankcalise commented 1 week ago

Closed by #2842