RNTester doesn't work
See original GitHub issueš Bug Report
I canāt force to work your sample RNTester according to manual https://github.com/facebook/react-native/tree/master/RNTester
To Reproduce
git clone https://github.com/facebook/react-native.git
. Itās OK!cd react-native
npm install
. Itās OK, but shows some warnings:
npm WARN @react-native-community/cli@1.4.2 requires a peer of react-native@^0.59.0 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-fbjs@2.0.1 requires a peer of babel-eslint@^7.2.3 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-fbjs@2.0.1 requires a peer of eslint@^4.2.0 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-fbjs@2.0.1 requires a peer of eslint-plugin-babel@^4.1.1 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-fb-strict@22.1.0 requires a peer of babel-eslint@^7.2.3 || ^8.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-fb-strict@22.1.0 requires a peer of eslint@^4.2.0 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-fb-strict@22.1.0 requires a peer of eslint-plugin-babel@^4.1.1 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-plugin-react@7.8.2 requires a peer of eslint@^3.0.0 || ^4.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-plugin-jsx-a11y@6.0.3 requires a peer of eslint@^3 || ^4 but none is installed. You must install peer dependencies yourself.
npm WARN jest-resolve-dependencies@24.5.0 requires a peer of jest-haste-map@^24.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN jest-snapshot@24.5.0 requires a peer of jest-haste-map@^24.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN jest-resolve@24.5.0 requires a peer of jest-haste-map@^24.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN The package jest-junit is included as both a dev and production dependency.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.7 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.7: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
- Prerequisites steps (https://facebook.github.io/react-native/docs/building-from-source.html#android): a) Set ANDROID_SDK and ANDROID_NDK (in ~/.bash_profile). b) Create RNTester/android/local.properties (with sdk.dir and ndk.dir properties within).
./gradlew :RNTester:android:app:installDebug
. Itās OK. Apk was installed on my android STB device../scripts/packager.sh
. Itās FAILED. Output:error Unable to find React Native files. Make sure "react-native" module is installed in your project dependencies.
Then I open installed RNTesterApp on my device:
Logcat error:
03-14 23:09:49.718 E/unknown:ReactNative(20905): Exception in native call
03-14 23:09:49.718 E/unknown:ReactNative(20905): java.lang.RuntimeException: Unable to load script. Make sure you're either running a Metro server (run 'react-native start') or that your bundle 'RNTesterApp.android.bundle' is packaged correctly for release.
03-14 23:09:49.718 E/unknown:ReactNative(20905): at com.facebook.react.bridge.CatalystInstanceImpl.jniLoadScriptFromAssets(Native Method)
03-14 23:09:49.718 E/unknown:ReactNative(20905): at com.facebook.react.bridge.CatalystInstanceImpl.loadScriptFromAssets(CatalystInstanceImpl.java:218)
03-14 23:09:49.718 E/unknown:ReactNative(20905): at com.facebook.react.bridge.JSBundleLoader$1.loadScript(JSBundleLoader.java:31)
03-14 23:09:49.718 E/unknown:ReactNative(20905): at com.facebook.react.bridge.CatalystInstanceImpl.runJSBundle(CatalystInstanceImpl.java:247)
03-14 23:09:49.718 E/unknown:ReactNative(20905): at com.facebook.react.ReactInstanceManager.createReactContext(ReactInstanceManager.java:1152)
03-14 23:09:49.718 E/unknown:ReactNative(20905): at com.facebook.react.ReactInstanceManager.access$900(ReactInstanceManager.java:123)
03-14 23:09:49.718 E/unknown:ReactNative(20905): at com.facebook.react.ReactInstanceManager$5.run(ReactInstanceManager.java:943)
03-14 23:09:49.718 E/unknown:ReactNative(20905): at java.lang.Thread.run(Thread.java:818)
Then I close RNTesterApp and run it again. It shows only white screen. Logcat:
03-14 23:31:21.125 W/unknown:ReconnectingWebSocket(20905): Couldn't connect to "ws://localhost:8081/message?device=p212%20-%206.0.1%20-%20API%2023&app=com.facebook.react.uiapp&clientid=DevSupportManagerImpl", will silently retry
Environment
Ubuntu 18.04.2 LTS Android 6.0.1
Issue Analytics
- State:
- Created 5 years ago
- Comments:8 (3 by maintainers)
Top Results From Across the Web
rn-tester Android build fails on main Ā· Issue #33725 - GitHub
Description I'm trying to run the rn-tester app, building React Native from source on Android. I'm on the current main branch,Ā ...
Read more >React Native in 7 Steps : Show RN Tester Project Review
This video tutorial has been taken from React Native in 7 Steps. You can learn more and buy the full video course hereĀ ......
Read more >I work in the ED where some procedures and tests happen ...
I work in the ED and have not experienced unnecessary testing or procedures. It's possible that you have gotten an adequate explanation for...
Read more >Testing - React Native
In this guide, we will cover different, automated ways to ensure your app works as expected, ranging from static analysis to end-to-end tests....
Read more >What You Should Know about Testing for Travel Nursing Jobs
A travel nurse will complete orientation and testing within the first two weeks on a travel nursing job. Here's what travel nurses can...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
any solution ? I encountered probably the same issue ā¦
Have you started packager? Run
yarn start
from root of React Native.