当我尝试使用react-native run-android
命令运行react-native应用程序时,出现以下错误。我在网上搜索过,没有找到该错误的解决方案
yarn run v1.22.4
$ react-native run-android
info Running jetifier to migrate libraries to AndroidX. You can disable it using "--no-jetifier" flag.
Jetifier found 1088 file(s) to forward-jetify. Using 4 workers...
info Starting JS server...
info Installing the app...
> Configure project :react-native-reanimated
IOException: https://dl.google.com/android/repository/addons_list-3.xml
java.net.ConnectException: Connection refused: connect
IOException: https://dl.google.com/android/repository/addons_list-2.xml
java.net.ConnectException: Connection refused: connect
IOException: https://dl.google.com/android/repository/addons_list-1.xml
java.net.ConnectException: Connection refused: connect
Failed to download any source lists!
IO exception while downloading manifest:
java.net.ConnectException: Connection refused: connect
at java.net.DualStackPlainSocketImpl.connect0(Native Method)
...
...
如何解决上述问题?
最佳答案
我发现了问题。未安装构建工具版本 29.0.2。我是从android studio安装的。现在一切正常。
关于react-native - React Native出现以下错误如何解决,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/65537942/