David Ewins
Error library

OTA update crashes old installs after adding a native module

ExpoConfirmed fix

runtimeVersion policy appVersion

Error
Invariant Violation: `new NativeEventEmitter()` requires a non-null argument.

Cause

The JS references a native module (here WebRTC) that is not compiled into the installed binary. Either the update reached an older binary, or you are testing native code over Metro on an old dev client.

Fix

Bump the app version when adding native code so the runtimeVersion changes and updates cannot reach older binaries. Test native changes on a fresh dev build (eas build --profile development or npx expo run:ios), not Fast Refresh.

More Expo errors

Search all errors