My environment: Managed workflow, expo-cli v5.0.2, eas-cli v0.41.1
We have been building and deploying builds of our mobile app just fine using “expo build”. In fact, I deployed one yesterday to the app stores and it’s working great.
Using that exact same code base, when I use “eas build”, the build succeeds but when I load it up in Test Flight, the app crashes immediately.
We have Sentry installed, and I see the following error reported before the crash:
Error: Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:
- You might have mismatching versions of React and the renderer (such as React DOM)
- You might be breaking the Rules of Hooks
- You might have more than one copy of React in the same app
See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.
Pretty sure we are using hooks properly, and we have matching React versions since we are able to deploy with “expo build” and run in the “expo go” client just fine. Could something in the “eas build” process be messing this up?
If any of the Expo team sees this, here is my build link: Build Details — 8a2cb150-3d0b-4331-a824-7057637bf6d0 — mobile — Expo