realm-js: [Solved] Error: Exception in HostObject::get for prop 'Realm': java.lang.UnsatisfiedLinkError: couldn't find DSO to load: librealm.so caused by: dlopen failed: cannot locate symbol "__emutls_get_address"

How frequently does the bug occur?

Always

Description

when trying to launch my application I get the following error:

ERROR Error: Exception in HostObject::get for prop ‘Realm’: java.lang.UnsatisfiedLinkError: couldn’t find DSO to load: librealm.so caused by: dlopen failed: cannot locate symbol “__emutls_get_address” referenced by “/data/ app/~~TV6qv1qy_a_BYXgZTHBqTw==/br.com.xxxx-Ja5z9s0oS8KVtSZWf6nQ8Q==/lib/arm/librealm.so”… result: 0, js engine: hermes

ERROR Invariant Violation: Module AppRegistry is not a registered callable module (calling runApplication). A frequent cause of the error is that the application entry file path is incorrect. This can also happen when the JS bundle is corrupt or there is an early initialization error when loading React Native., js engine: hermes

ERROR Invariant Violation: Module AppRegistry is not a registered callable module (calling runApplication). A frequent cause of the error is that the application entry file path is incorrect. This can also happen when the JS bundle is corrupt or there is an early initialization error when loading React Native., js engine: hermes

This happened after I migrated from react-native 0.68.2 to 0.68.5

this is my package.json

{ “name”: “xxxx”, “version”: “0.0.1”, “private”: true, “scripts”: { “start”: “react-native start”, “test”: “jest”, “test:update”: “jest -u”, “test:coverage”: “jest --coverage”, “run:ios”: “react-native run-ios”, “run:android”: “react-native run-android”, “lint”: “./node_modules/eslint/bin/eslint.js src”, “lint:fix”: “./node_modules/eslint/bin/eslint.js src --fix”, “flow”: “./node_modules/flow-bin/cli.js”, “e2e:build”: “detox build --configuration ios.sim.debug”, “e2e:test”: “detox test --configuration ios.sim.debug”, “postinstall”: “npx jetify” }, “dependencies”: { “@babel/helper-hoist-variables”: “^7.18.6”, “@expo/react-native-action-sheet”: “^3.13.0”, “@react-native-community/art”: “^1.2.0”, “@react-native-community/async-storage”: “^1.12.1”, “@react-native-community/datetimepicker”: “^6.3.1”, “@react-native-community/netinfo”: “^9.3.0”, “@react-native-community/push-notification-ios”: “^1.10.1”, “@react-native-picker/picker”: “^2.4.2”, “@react-navigation/bottom-tabs”: “^5.11.11”, “@react-navigation/drawer”: “^5.12.5”, “@react-navigation/native”: “^5.9.4”, “@react-navigation/routers”: “^5.7.4”, “@react-navigation/stack”: “^5.14.5”, “axios”: “^0.27.2”, “base-64”: “^1.0.0”, “date-fns”: “^2.28.0”, “formik”: “^2.2.9”, “jetifier”: “^2.0.0”, “lodash”: “^4.17.21”, “moment”: “^2.29.4”, “pdf-lib”: “^1.17.1”, “react”: “17.0.2”, “react-native”: “0.68.5”, “react-native-blob-util”: “^0.16.2”, “react-native-calendars”: “^1.1285.0”, “react-native-device-info”: “^10.0.1”, “react-native-fs”: “^2.20.0”, “react-native-gesture-handler”: “^2.5.0”, “react-native-image-picker”: “^4.8.4”, “react-native-linear-gradient”: “^2.6.2”, “react-native-location”: “^2.5.0”, “react-native-maps”: “^1.1.0”, “react-native-mock-location-detector”: “^2.0.0”, “react-native-modal”: “^13.0.1”, “react-native-modal-datetime-picker”: “^13.1.2”, “react-native-modal-dropdown”: “^1.0.2”, “react-native-multiple-select”: “^0.5.9”, “react-native-paper”: “^4.12.2”, “react-native-pdf”: “^6.6.2”, “react-native-progress-steps”: “^1.3.4”, “react-native-push-notification”: “^8.1.1”, “react-native-rate”: “^1.2.9”, “react-native-ratings”: “^8.1.0”, “react-native-reanimated”: “^2.9.1”, “react-native-render-html”: “^6.3.4”, “react-native-responsive-screen”: “^1.4.2”, “react-native-safe-area-context”: “^4.3.1”, “react-native-screens”: “^3.15.0”, “react-native-share”: “^7.6.6”, “react-native-signature-canvas”: “^4.4.1”, “react-native-svg”: “^12.4.4”, “react-native-ui-lib”: “^6.18.0”, “react-native-vector-icons”: “^9.2.0”, “react-native-vision-camera”: “^2.14.0”, “react-native-webview”: “^11.22.7”, “react-redux”: “^8.0.2”, “realm”: “^11.0.0-rc.0”, “recompose”: “^0.30.0”, “redux”: “^4.2.0”, “redux-logger”: “^3.0.6”, “redux-persist”: “^6.0.0”, “redux-promise”: “^0.6.0”, “redux-thunk”: “^2.4.1”, “vanilla-masker”: “^1.2.0”, “vision-camera-face-detector”: “^0.1.8”, “yup”: “^0.32.11” }, “devDependencies”: { “@babel/core”: “^7.18.6”, “@babel/runtime”: “^7.18.6”, “@react-native-community/eslint-config”: “^3.0.3”, “babel-jest”: “^28.1.2”, “babel-plugin-module-resolver”: “^4.1.0”, “eslint”: “^8.19.0”, “jest”: “^28.1.2”, “metro-react-native-babel-preset”: “^0.71.3”, “react-test-renderer”: “17.0.2” }, “jest”: { “preset”: “react-native” } }

Stacktrace & log output

ERROR Error: Exception in HostObject::get for prop 'Realm': java.lang.UnsatisfiedLinkError: couldn't find DSO to load: librealm.so caused by: dlopen failed: cannot locate symbol "__emutls_get_address" referenced by "/data/ app/~~TV6qv1qy_a_BYXgZTHBqTw==/br.com.xxxx-Ja5z9s0oS8KVtSZWf6nQ8Q==/lib/arm/librealm.so"... result: 0, js engine: hermes

Can you reproduce the bug?

Always

Reproduction Steps

No response

Version

24.0.8215888

What services are you using?

Local Database only

Are you using encryption?

No

Platform OS and version(s)

24.0.8215888

Build environment

Which debugger for React Native: …

Cocoapods version

No response

About this issue

  • Original URL
  • State: closed
  • Created a year ago
  • Comments: 18 (4 by maintainers)

Most upvoted comments

Use realm version “11.0.0” rather than “^11.0.0”,

This fixed the issue for me.

if enableProguardInReleaseBuilds is enabled then disable it

@Pingou The current development of RN is a bit tough to follow for most of us. We hope to find a better solution soon (see also https://github.com/realm/realm-js/pull/4027 for a first attempt)

@Pingou I assume that you haven’t upgraded React Native or another dependency. Please check the compatibility matrix

@kneth Why close the issue? It seems like one of the last updates broke something. It works for me if I use 11.2.0, but not ^11.2.0.