问题
I am currently in the process of trying to build my first app using Expo-cli. I am on Windows 10. I have an Apple Developer account and am just trying to build for iOS at the moment. However, whenever I run "expo build:ios" I get the following errors:
Connection reset by peer - SSL_connect
>>Error while gathering & validating credentials
>>Error: Reason:Unknown reason, raw:"Could not receive latest API key from App Store Connect, this might be a server issue."
>>Reason:Unknown reason, raw:"Could not receive latest API key from App Store Connect, this might be a server issue."
When I run "set EXPO_DEBUG=true expo build:ios" and enter my Apple credentials, I get the following information:
Error: Reason:Unknown reason, raw:"Could not receive latest API key from App Store Connect, this might be a server issue."
at Object._callee4$ (C:\expo-cli@2.6.14\src\commands\build\auth.js:135:11)
at tryCatch (C:\Users\danie\AppData\Roaming\npm\node_modules\expo-cli\node_modules\regenerator-runtime\runtime.js:62:40)
at Generator.invoke [as _invoke] (C:\Users\danie\AppData\Roaming\npm\node_modules\expo-cli\node_modules\regenerator-runtime\runtime.js:296:22)
at Generator.prototype.(anonymous function) [as next] (C:\Users\danie\AppData\Roaming\npm\node_modules\expo-cli\node_modules\regenerator-runtime\runtime.js:114:21)
at step (C:\Users\danie\AppData\Roaming\npm\node_modules\expo-cli\node_modules\babel-runtime\helpers\asyncToGenerator.js:17:30)
at C:\Users\danie\AppData\Roaming\npm\node_modules\expo-cli\node_modules\babel-runtime\helpers\asyncToGenerator.js:28:13
at process._tickCallback (internal/process/next_tick.js:68:7)
I have tried running the server and build on multiple networks with no luck. I have not found any other questions similar to this on any platform.
Does anyone have any ideas of what I can do to solve this issue? Thanks in advance!
回答1:
I had exactly the same issue.
Turned out Kaspersky Free Anti-Virus was blocking the connection.
Fixed by exiting Kaspersky - note that just pausing protection didn't help.
回答2:
It could be caused by 2 factor auth, which has been enforced recently. It was recommended by fastlane to create a different Apple account for CI only.
回答3:
Updating to the latest version of Expo-cli solved this for me. It incorporates latest changes from Apple Developer Account API requiring 2FA to access account.
Run npm install -g expo-cli
in terminal for project.
来源:https://stackoverflow.com/questions/54166879/expo-ios-build-not-working-could-not-receive-latest-api-key-from-app-store-con