Android error after ejecting from CRNA: "Failed to resolve: host.exp.exponent:expoview:30.0.0"

I created a project using CRNA, ran ‘npm run eject’, and chose to use Expo. I’m getting the following error: “Failed to resolve: host.exp.exponent:expoview:30.0.0” when opening the project in Android Studio without making any changes to the code. I’m new to both CRNA and Expo so I’m not sure how to go about resolving this issue. I’m using Expo version 30.0.1. Any advice?

1 Like

Hi @aaaronmf,

Did you manage to fix it? We’re experiencing the same issue.

I have not unfortunately.

Hi @aaaronmf and @socialmediaemotions - have you tried re-running yarn or npm install in the root folder of your project?

Hi @esamelson, I just ran npm install and then got the following message: “Failed to find Build Tools revision 28.0.2”. I clicked the link the install the build tools and sync the project, and am now getting new errors: “Output: /aaaronMFsProject/android/app/build/intermediates/incremental/mergeDevMinSdkDevKernelDebugResources/merged.dir/values/values.xml:1156: error: inner element must either be a resource reference or empty.” There are eight other similar errors. Should I not have updated the build tools? It didn’t seem like I had a choice. Do you happen to know what I can do to rectify these errors?

Thanks for the help!

I was facing the same issue. I found that the “expokit” package was missing from my package.json file. So I run this command in the terminal:

npm install --save expokit

expokit 1.7.1 was added into my dependencies and after that my build.gradle built successfully.

3 Likes

Thank you so much darush that was it for me, you saved my day!

epo-cli version 2.2.5

I’have the same issue. After creating a default CRNA App. The solluton above doesn’t fix this problem

What is the sollution for this issue

Hi, I found that my problem was due to a simple error on my part. In the expo docs, it is explicitly stated that you should not update the build tools as ExpoKit ships with the latest compatible version, yet I still updated it out of ignorance. I solved the problem by deleting and reinstalling Android Studio. Also I changed this line in android/app/build.gradle: implementation('host.exp.exponent:expoview:30.0.0@aar') { to compile('host.exp.exponent:expoview:30.0.0@aar') { which solved the problem for me. Hope this helps.

1 Like

Hey @he1nr1ch,

Glad you got it working and thanks for sharing your solution with the community. Always appreciate exponauts helping each other out and saving them from hair-pulling moments.

Cheers,

Adam

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