英文:
Expo Development Build on Simulator Network connection lost
问题
我为Expo构建了开发版本,但一旦我这样做了,我就无法从iOS模拟器连接到Expo开发服务器。我尝试过:
- 降级Expo和React Native
- 重置路由器
- 在路由器上打开端口
- 运行全新的Expo应用程序并安装开发版本
什么都不起作用。安卓和模拟器也一样。还有一台iPhone。
在iOS上,我收到以下错误:从http://......加载应用程序失败。网络连接丢失。
在安卓上,我收到以下错误:http://上意外结束流。
有人有什么想法可以解决这个问题吗?
英文:
I built development builds for an Expo an and as soon as I did that, I was not able to to connect to the expo development server from the iOs simulator. I tried:
- downgrading expo, react-native
- resetting router
- opening ports on the router
- running a completely new, 'naked' expo app and installing dev builds
Nothing works. Same with android and the emulator. And an iPhone.
On iOs I receive the error: Failed to load app from http://...... The network connection was lost.
On android I receive the error: Unexpected end of stream on http://
Does anyone have an idea what could be done to fix this?
答案1
得分: 8
我遇到了相同的问题,并成功通过将 NodeJS 从版本 20 降级到 NodeJS 18(LTS 版本)来解决它。如果你正在使用 NodeJS 版本 20,你可能想尝试降级。
英文:
I had the same issue and managed to solve it by downgrading from NodeJS 20 to NodeJS 18 (the LTS). If you're on NodeJS version 20, you might wanna try to downgrade.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论