ERROR Amplitude Logger [Error]: TypeError: Network request failed

I added amplitude react native sdk to my expo project using dev client and got this error on android when tracking an event: ERROR Amplitude Logger [Error]: TypeError: Network request failed.

  • Expo sdk 48 (48.0.15)
  • @amplitude/analytics-react-native 1.1.7
  • serverZone: eu

steps to reproduce:

  • create an amplitude project in EU zone
  • Start a new expo project
  • yarn add @amplitude/analytics-react-native
  • Create a development build of the project
  • initialize amplitude in app.tsx and track some events
    example: init([you-amplitude-api-key], undefined, { serverZone: 'EU' });

PS: even when trying with HTTP API source and sending event with normal fetch api i got the same issue: TypeError: Network request failed in an expo app, but when i try it in bare react native app it works fine for both sources HTTP API or React Native SDK.
any idea how to resolve this issue ?

0 replies

Be the first to reply!