Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to find JSIModule for class interface com.facebook.react.bridge.UIManager #20636

Closed
ghost opened this issue Aug 12, 2018 · 19 comments
Closed
Labels
Bug Stale There has been a lack of activity on this issue and it may be closed soon.

Comments

@ghost
Copy link

ghost commented Aug 12, 2018

Environment

React Native Environment Info:
System:
OS: macOS High Sierra 10.13.6
CPU: x64 Intel(R) Core(TM) i5-4278U CPU @ 2.60GHz
Memory: 26.42 MB / 8.00 GB
Shell: 5.3 - /bin/zsh
Binaries:
Node: 10.1.0 - /usr/local/bin/node
Yarn: 1.6.0 - /usr/local/bin/yarn
npm: 6.0.1 - /usr/local/bin/npm
Watchman: 4.9.0 - /usr/local/bin/watchman
SDKs:
iOS SDK:
Platforms: iOS 11.4, macOS 10.13, tvOS 11.4, watchOS 4.3
Android SDK:
Build Tools: 23.0.1, 23.0.2, 23.0.3, 26.0.2, 27.0.3
API Levels: 23, 26, 27
IDEs:
Android Studio: 3.1 AI-173.4907809
Xcode: 9.4.1/9F2000 - /usr/bin/xcodebuild
npmPackages:
@storybook/react-native: ^3.4.8 => 3.4.8
react: 16.4.1 => 16.4.1
react-native: 0.56 => 0.56.0
npmGlobalPackages:
react-native-cli: 2.0.1

Description

I've been getting this error in my application on a newer versions of android after initial debug launch. After 'Reload' pressed it shows me a general 'Could not connect to development server' error. And of course the steps listed doesn't help. Any suggestions?

P.S New projects initialised with 'react-native init' works correctly.

Reproducible Demo

Sorry the sample for reproduction can't be provided

@react-native-bot

This comment has been minimized.

@saniawaheed
Copy link

i m facing the same issue

@Abby3017
Copy link

Abby3017 commented Aug 22, 2018

Getting Same Error.
This error happened after updating existing app from RN54 to RN56 and creating signed apk build.
Work fine in development.
Error Log
08-22 18:07:27.469 740 6694 D AES : java.lang.IllegalArgumentException: Unable to find JSIModule for class interface com.facebook.react.bridge.UIManager 08-22 18:07:27.469 740 6694 D AES : at com.facebook.react.bridge.JSIModuleRegistry.getModule(JSIModuleRegistry.java:17) 08-22 18:07:27.469 740 6694 D AES : at com.facebook.react.bridge.CatalystInstanceImpl.getJSIModule(CatalystInstanceImpl.java:478) 08-22 18:07:27.469 740 6694 D AES : at com.facebook.react.uimanager.UIManagerHelper.getUIManager(UIManagerHelper.java:32) 08-22 18:07:27.469 740 6694 D AES : at com.facebook.react.uimanager.UIManagerModule.dispatchViewManagerCommand(UIManagerModule.java:597) 08-22 18:07:27.469 740 6694 D AES : at java.lang.reflect.Method.invoke(Native Method) 08-22 18:07:27.469 740 6694 D AES : at com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:372) 08-22 18:07:27.469 740 6694 D AES : at com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:160) 08-22 18:07:27.469 740 6694 D AES : at com.facebook.react.bridge.queue.NativeRunnable.run(Native Method) 08-22 18:07:27.469 740 6694 D AES : at android.os.Handler.handleCallback(Handler.java:836) 08-22 18:07:27.469 740 6694 D AES : at android.os.Handler.dispatchMessage(Handler.java:103) 08-22 18:07:27.469 740 6694 D AES : at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:29) 08-22 18:07:27.469 740 6694 D AES : at android.os.Looper.loop(Looper.java:203) 08-22 18:07:27.469 740 6694 D AES : at com.facebook.react.bridge.queue.MessageQueueThreadImpl$3.run(MessageQueueThreadImpl.java:192) 08-22 18:07:27.469 740 6694 D AES : at java.lang.Thread.run(Thread.java:761)

Any Ideas would be helpful

@debbiefu
Copy link

I'm facing the same issue, using UIManager.dispatchViewManagerCommand

@kevinresol
Copy link
Contributor

kevinresol commented Sep 21, 2018

@Abby3017 what is your android version running the app?

I am experiencing the same issue on Android 8, release build, signed.

Fatal Exception: java.lang.IllegalArgumentException
Unable to find JSIModule for class interface com.facebook.react.bridge.UIManager

com.facebook.react.bridge.JSIModuleRegistry.getModule (JSIModuleRegistry.java:17)
com.facebook.react.bridge.CatalystInstanceImpl.getJSIModule (CatalystInstanceImpl.java:478)
com.facebook.react.uimanager.UIManagerHelper.getUIManager (UIManagerHelper.java:32)
com.facebook.react.uimanager.UIManagerModule.dispatchViewManagerCommand (UIManagerModule.java:597)
java.lang.reflect.Method.invoke (Method.java)

@igorlira
Copy link

igorlira commented Sep 27, 2018

Facing the same issue after updating RN from 54 to 57

Update:
The error was actually happening after a CodePush update had been downloaded. I've bumped my app's version so that CodePush wouldn't try to update and it's working now, so this issue might be caused by an outdated JavaScript bundle file.

@kevinresol
Copy link
Contributor

@igorlira did you report to code push?

@igorlira
Copy link

igorlira commented Oct 3, 2018

@kevinresol I think this is more like a case of user error rather than an actual issue on CodePush, since I don't think a JS bundle compiled for an older version of RN should be expected to run on a newer version.

@ivanbtrujillo
Copy link

Hi @igorlira I've exactly the same problem than you. Did you solved it?

@kevinresol
Copy link
Contributor

My problem was same as @igorlira's

@ivanbtrujillo if you are using CodePush you can try this:

  1. Log in to AppCenter and check the latest CodePush distribution
  2. Make sure the "Target Version" matches the actual version of your running app
  3. If they don't match, you can make an another release to CodePush

@ivanbtrujillo
Copy link

Yep that was the issue, after publish a new release to CodePush it works. Thanks guys!

@stale
Copy link

stale bot commented Jan 20, 2019

Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as "For Discussion" or "Good first issue" and I will leave it open. Thank you for your contributions.

@stale stale bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label Jan 20, 2019
@stale stale bot removed the Stale There has been a lack of activity on this issue and it may be closed soon. label Jan 26, 2019
@hramos hramos removed the Bug Report label Feb 6, 2019
@vkkan
Copy link

vkkan commented Jul 1, 2019

I am also facing the same issue, given below were my required information.

React Native Environment Info:
System:
OS: Linux 4.15 Ubuntu 16.04.5 LTS (Xenial Xerus)
CPU: (8) x64 Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz
Memory: 174.16 MB / 15.58 GB
Shell: 4.3.48 - /bin/bash
Binaries:
Node: 10.15.3 - /usr/local/bin/node
Yarn: 1.16.0 - /usr/local/bin/yarn
npm: 4.6.1 - /usr/local/bin/npm
SDKs:
Android SDK:
API Levels: 21, 23, 24, 25, 26, 27, 28
Build Tools: 23.0.1, 24.0.2, 25.0.0, 25.0.2, 26.0.1, 26.0.3, 27.0.2, 27.0.3, 28.0.2, 28.0.3
System Images: android-26 | Android TV Intel x86 Atom, android-26 | China version of Android Wear Intel x86 Atom, android-26 | Android Wear Intel x86 Atom, android-26 | Intel x86 Atom, android-26 | Intel x86 Atom_64, android-26 | Google APIs Intel x86 Atom, android-26 | Google APIs Intel x86 Atom_64, android-26 | Google Play Intel x86 Atom, android-27 | Intel x86 Atom, android-27 | Intel x86 Atom_64, android-27 | Google APIs Intel x86 Atom, android-27 | Google Play Intel x86 Atom, android-28 | Android TV Intel x86 Atom, android-28 | China version of Wear OS Intel x86 Atom, android-28 | Intel x86 Atom, android-28 | Intel x86 Atom_64, android-28 | Google APIs Intel x86 Atom, android-28 | Google APIs Intel x86 Atom_64, android-28 | Google Play Intel x86 Atom, android-28 | Google Play Intel x86 Atom_64
npmPackages:
react: 16.4.1 => 16.4.1
react-native: 0.56.0 => 0.56.0
npmGlobalPackages:
react-native-cli: 2.0.1
react-native-git-upgrade: 0.2.7

Error I am seeing in Logcat as follows :

E/AndroidRuntime: FATAL EXCEPTION: mqt_native_modules
Process: com.ortholive, PID: 7493
java.lang.IllegalArgumentException: Unable to find JSIModule for class interface com.facebook.react.bridge.UIManager
at com.facebook.react.bridge.JSIModuleRegistry.getModule(JSIModuleRegistry.java:17)
at com.facebook.react.bridge.CatalystInstanceImpl.getJSIModule(CatalystInstanceImpl.java:478)
at com.facebook.react.uimanager.UIManagerHelper.getUIManager(UIManagerHelper.java:32)
at com.facebook.react.uimanager.UIManagerModule.dispatchViewManagerCommand(UIManagerModule.java:597)
at java.lang.reflect.Method.invoke(Native Method)
at com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:372)
at com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:160)
at com.facebook.react.bridge.queue.NativeRunnable.run(Native Method)
at android.os.Handler.handleCallback(Handler.java:790)
at android.os.Handler.dispatchMessage(Handler.java:99)
at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:29)
at android.os.Looper.loop(Looper.java:164)
at com.facebook.react.bridge.queue.MessageQueueThreadImpl$3.run(MessageQueueThreadImpl.java:192)
at java.lang.Thread.run(Thread.java:764)

After lot of hurdles I have fixed most of my babel issues using #20150 (comment)

@vkkan
Copy link

vkkan commented Jul 1, 2019

@Abby3017 what is your android version running the app?

I am experiencing the same issue on Android 8, release build, signed.

Fatal Exception: java.lang.IllegalArgumentException
Unable to find JSIModule for class interface com.facebook.react.bridge.UIManager

com.facebook.react.bridge.JSIModuleRegistry.getModule (JSIModuleRegistry.java:17)
com.facebook.react.bridge.CatalystInstanceImpl.getJSIModule (CatalystInstanceImpl.java:478)
com.facebook.react.uimanager.UIManagerHelper.getUIManager (UIManagerHelper.java:32)
com.facebook.react.uimanager.UIManagerModule.dispatchViewManagerCommand (UIManagerModule.java:597)
java.lang.reflect.Method.invoke (Method.java)

Did you find any resolution ? I am also got struck now

@nates-dennis
Copy link

@Abby3017 what is your android version running the app?
I am experiencing the same issue on Android 8, release build, signed.

Fatal Exception: java.lang.IllegalArgumentException
Unable to find JSIModule for class interface com.facebook.react.bridge.UIManager

com.facebook.react.bridge.JSIModuleRegistry.getModule (JSIModuleRegistry.java:17)
com.facebook.react.bridge.CatalystInstanceImpl.getJSIModule (CatalystInstanceImpl.java:478)
com.facebook.react.uimanager.UIManagerHelper.getUIManager (UIManagerHelper.java:32)
com.facebook.react.uimanager.UIManagerModule.dispatchViewManagerCommand (UIManagerModule.java:597)
java.lang.reflect.Method.invoke (Method.java)

Did you find any resolution ? I am also got struck now

i am also running into this when running the app in release mode. It works fine in debug mode.

@LouisChain
Copy link

Me too, app works fine in Debug mode, but release, here is the full log:

Make sure that you have rebuilt the native code. If the problem persists try clearing the Watchman and packager caches withwatchman watch-del-all && react-native start --reset-cache`.
2019-08-27 16:46:02.595 9819-9901/com.ascentis.astons E/unknown:ReactNative: console.error: "React Native version mismatch.

JavaScript version: 0.55.4
Native version: 0.60.5

Make sure that you have rebuilt the native code. If the problem persists try clearing the Watchman and packager caches with `watchman watch-del-all && react-native start --reset-cache`.", stack:
checkVersions@54:302
<unknown>@42:706
d@2:755
n@2:326
global code@981:8

2019-08-27 16:46:03.767 9819-9901/com.ascentis.astons E/AndroidRuntime: FATAL EXCEPTION: mqt_native_modules
Process: com.ascentis.astons, PID: 9819
java.lang.IllegalArgumentException: Unable to find JSIModule for class interface com.facebook.react.bridge.UIManager
at com.facebook.react.bridge.JSIModuleRegistry.getModule(JSIModuleRegistry.java:24)
at com.facebook.react.bridge.CatalystInstanceImpl.getJSIModule(CatalystInstanceImpl.java:496)
at com.facebook.react.uimanager.UIManagerHelper.getUIManager(UIManagerHelper.java:37)
at com.facebook.react.uimanager.UIManagerModule.updateView(UIManagerModule.java:476)
at java.lang.reflect.Method.invoke(Native Method)
at com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:372)
at com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:158)
at com.facebook.react.bridge.queue.NativeRunnable.run(Native Method)
at android.os.Handler.handleCallback(Handler.java:873)
at android.os.Handler.dispatchMessage(Handler.java:99)
at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:29)
at android.os.Looper.loop(Looper.java:193)
at com.facebook.react.bridge.queue.MessageQueueThreadImpl$4.run(MessageQueueThreadImpl.java:232)
at java.lang.Thread.run(Thread.java:764)
`

@LouisChain
Copy link

LouisChain commented Aug 27, 2019

Hi guys I found this solution:

Delete the index.android.* files in android/app/src/main/assets/ directory. Then in the project root, then run:

react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res

Then I regenerated the signed APK and voila!

@stale
Copy link

stale bot commented Nov 25, 2019

Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as a "Discussion" or add it to the "Backlog" and I will leave it open. Thank you for your contributions.

@stale stale bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label Nov 25, 2019
@stale
Copy link

stale bot commented Dec 2, 2019

Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please feel free to create a new issue with up-to-date information.

@stale stale bot closed this as completed Dec 2, 2019
@facebook facebook locked as resolved and limited conversation to collaborators Dec 3, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug Stale There has been a lack of activity on this issue and it may be closed soon.
Projects
None yet
Development

No branches or pull requests