expo-cli 和 react-native-app 的"npm install"问题/失败



我真的需要一些帮助来完成最基本的任务(设置expo/react-native项目(。我已经安装了expo-cli (v3.11.7)react-native (v2.0.1)watchman (v4.9.0)node (v12.14.1)。我已经按照教程进行操作,直到我需要运行 expo start 并收到以下错误:

Your project is in SDK version >= 33.0.0, but the expo package version seems to be older.
Error: node_modules directory is missing. Please run npm install in your project directory.
Couldn't start project. Please fix the errors and restart the project.
Set EXPO_DEBUG=true in your env to view the stack trace.

然后我运行了npm install并重试,但弹出了相同的错误。我已经删除了node_modules文件夹,但这也不起作用。

更新:

当我npm安装时,这是我看到的错误:

npm WARN deprecated core-js@1.2.7: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.    
npm ERR! code EPROTO
npm ERR! errno EPROTO
npm ERR! request to https://codeload.github.com/expo/react-native/tar.gz/sdk-36.0.0 failed, reason: write EPROTO 4521895360:error:14094410:SSL routines:ssl3_read_bytes:sslv3 alert handshake failure:../deps/openssl/openssl/ssl/record/rec_layer_s3.c:1544:SSL alert number 40

我已经安装了yarn (v1.21.1)并尝试使用它进行安装,但出现相同的错误:

warning expo > fbemitter > fbjs > core-js@1.2.7: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
error An unexpected error occurred: "https://github.com/expo/react-native/archive/sdk-36.0.0.tar.gz: write EPROTO 4356277696:error:14094410:SSL routines:ssl3_read_bytes:sslv3 alert handshake failure:../deps/openssl/openssl/ssl/record/rec_layer_s3.c:1544:SSL alert number 40

谁能建议?

我已经设法解决了这个问题。我正在尝试通过我的家庭网络进行安装,这显然有一些代理限制!不知道为什么。

有人建议我重试,但连接到另一个网络或我的移动热点。我试过这个,它奏效了!问题解决了。因此,我想对于可能遇到相同问题的任何其他人,请尝试连接到另一个网络,看看是否有帮助。

如果这失败了,那么我想查看代理配置并在那里进行更改可能会有所帮助。但我不建议这样做,除非你确切地知道你在做什么。

最新更新