EAS android build local error

I ran the command npx expo prebuild --platform android but there’s an error

Error: Failed to find ‘build.gradle’ file for project: /var/folders/_w/p_h7l0ws22lbmv4pq3khkgvc0000gn/T/eas-build-local-nodejs/fac128e6-8fe3-4d25-b1c8-b835525a8d78/build/android/app.

So I tried using the npx expo prebuild --platform android command to generate the android folder, but I got another error stating to delete ./android folder.
However, the ./android folder doesnt exist in my project.

npm exited with non-zero code: 1
:heavy_multiplication_x: Failed to create the native project.
You may want to delete the ./ios and/or ./android directories before trying again.

  • Managed work flow
  • eas-cli version: 3.13.3

Hi @randomgit312

Based on the title of your post I assume you meant to say that you ran something like this first?

eas build --platform android --profile ??? --local

Was there no other error before this? It seems likely to me that it was caused by something else going wrong before this.

So there’s no android directory even after the failed npx expo prebuild command?

Check for what error you get before the npx exited with non-zero code: 1 error message.

Yeah sorry i meant to say I ran eas build --platform android --profile ??? --local.

But the build went fine after upgrading eas-cli from 3.13.3 to 3.14.0

1 Like

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.