Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't build example with eas #67

Open
ajeecai opened this issue Jan 5, 2025 · 6 comments
Open

Can't build example with eas #67

ajeecai opened this issue Jan 5, 2025 · 6 comments

Comments

@ajeecai
Copy link

ajeecai commented Jan 5, 2025

  1. git clone https://github.com/jamsch/expo-speech-recognition.git
  2. expo-speech-recognition/example/
  3. npm install
  4. eas build --profile preview --platform android
  5. Unknown error. See logs of the Read app config build phase for more information.
  6. seeing this in eas

Build failed

Cannot find module 'expo/config-plugins'
Require stack:

  • /home/expo/workingdir/build/app.plugin.js
  • /usr/local/eas-build-worker/node_modules/@expo/config/node_modules/@expo/config-plugins/build/utils/plugin-resolver.js
  • /usr/local/eas-build-worker/node_modules/@expo/config/node_modules/@expo/config-plugins/build/plugins/withStaticPlugin.js
  • /usr/local/eas-build-worker/node_modules/@expo/config/node_modules/@expo/config-plugins/build/plugins/withPlugins.js
  • /usr/local/eas-build-worker/node_modules/@expo/config/node_modules/@expo/config-plugins/build/index.js
  • /usr/local/eas-build-worker/node_modules/@expo/config/build/plugins/withConfigPlugins.js
  • /usr/local/eas-build-worker/node_modules/@expo/config/build/Config.js
  • /usr/local/eas-build-worker/node_modules/@expo/config/build/index.js
  • /usr/local/eas-build-worker/node_modules/@expo/build-tools/dist/utils/appConfig.js
  • /usr/local/eas-build-worker/node_modules/@expo/build-tools/dist/context.js
  • /usr/local/eas-build-worker/node_modules/@expo/build-tools/dist/builders/android.js
  • /usr/local/eas-build-worker/node_modules/@expo/build-tools/dist/builders/index.js
  • /usr/local/eas-build-worker/node_modules/@expo/build-tools/dist/index.js
  • /usr/local/eas-build-worker/src/services/worker/dist/service.js
  • /usr/local/eas-build-worker/src/services/worker/dist/ws.js
  • /usr/local/eas-build-worker/src/services/worker/dist/main.js
  1. npx expo start is ok

Thanks

@jamsch
Copy link
Owner

jamsch commented Jan 5, 2025

Hey @ajeecai, if you're building the example app you'll also need to run an "npm install" & "npm run prepare" in the root directory of the project because the example relies on a built version of the local package.

@ajeecai
Copy link
Author

ajeecai commented Jan 6, 2025

Hi @jamsch ,
Here is the result:

$ npm run prepare
npm error Missing script: "prepare"
npm error
npm error To see a list of scripts, run:
npm error npm run

And try to show the scripts list:

$ npm run
Lifecycle scripts included in [email protected]:
start
expo start --dev-client
available via npm run-script:
android
expo run:android
ios
expo run:ios
web
expo start --web
android:fix-emulator-mic
adb emu avd hostmicon

Looks like there is no npm run prepare, anything I missed?

Thanks

@jamsch
Copy link
Owner

jamsch commented Jan 6, 2025

Hi @ajeecai, you need to run those two commands a level higher (the root of the project, not in the example folder). The example folder uses the development version of expo-speech-recognition that's part of the repository which is why it needs to be installed & built first.

Also, I haven't actually tested building the example app with EAS, but you should be able to build it using npm run android / npm run ios.

@ajeecai
Copy link
Author

ajeecai commented Jan 7, 2025

Hi @jamsch,

After installing Android emulator, I can compile the app-debug.apk. But when I try to install, it says "incompatible" to my android mobile phone. So, still I can't play with it :)

Thanks

@jamsch
Copy link
Owner

jamsch commented Jan 15, 2025

Hi @ajeecai -- just checking to see if you've resolved the issue? Depending on the error code, it could mean that you have an already-existing installation of the same bundle identifier (i.e. com.yourpackage) with a lower build number value. Could you take a screenshot of your device, or the console so I could see what issue you're having?

@ajeecai
Copy link
Author

ajeecai commented Jan 15, 2025

Hi @jamsch , the incompatibility is due to my build is for x86. After I have changed the android/app/build.gradle to build for arm64 platform, it can be installed on my android phone. But the app can't be launched, it clashes and quits each time. It is said that use adb to watch on the logs for crash reason, I not am familiar to mobile development, so I may take more time to figure it out. If you like, you may close this ticket.

Thanks

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

No branches or pull requests

2 participants