Hi, I’ve been having problems with expo publish or build:{ios,android} for the past 2 hours or so.
⟩ env EXPO_DEBUG=true expo publish
Unable to find an existing Expo CLI instance for this directory, starting a new one...
Starting Metro Bundler on port 19001.
Tunnel ready.
Publishing to channel 'default'...
Building iOS bundle
Building Android bundle
Finished building JavaScript bundle in 9124ms.
Analyzing assets
Finished building JavaScript bundle in 2595ms.
Finished building JavaScript bundle in 259ms.
Finished building JavaScript bundle in 2784ms.
Uploading assets
No assets changed, skipped.
Processing asset bundle patterns:
- <redacted>/src/assets/images/*
Uploading JavaScript bundles
Request failed with status code 404
Error: Request failed with status code 404
at createError (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/core/createError.js:16:15)
at settle (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/core/settle.js:17:12)
at IncomingMessage.handleStreamEnd (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/adapters/http.js:237:11)
at IncomingMessage.emit (events.js:203:15)
at endReadableNT (_stream_readable.js:1145:12)
at process._tickCallback (internal/process/next_tick.js:63:19)
Tried expo build:ios, with the same result
⟩ env EXPO_DEBUG=true expo build:ios
Checking if there is a build in progress...
Unable to find an existing Expo CLI instance for this directory, starting a new one...
Starting Metro Bundler on port 19001.
Tunnel ready.
Publishing to channel 'default'...
Building iOS bundle
Building Android bundle
Finished building JavaScript bundle in 5989ms.
Analyzing assets
Finished building JavaScript bundle in 2530ms.
Finished building JavaScript bundle in 2372ms.
Finished building JavaScript bundle in 75ms.
Uploading assets
No assets changed, skipped.
Processing asset bundle patterns:
- <redacted>/src/assets/images/*
Uploading JavaScript bundles
Request failed with status code 404
Error: Request failed with status code 404
at createError (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/core/createError.js:16:15)
at settle (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/core/settle.js:17:12)
at IncomingMessage.handleStreamEnd (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/adapters/http.js:237:11)
at IncomingMessage.emit (events.js:203:15)
at endReadableNT (_stream_readable.js:1145:12)
at process._tickCallback (internal/process/next_tick.js:63:19)
Error: Request failed with status code 404
at createError (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/core/createError.js:16:15)
at settle (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/core/settle.js:17:12)
at IncomingMessage.handleStreamEnd (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/adapters/http.js:237:11)
at IncomingMessage.emit (events.js:203:15)
at endReadableNT (_stream_readable.js:1145:12)
at process._tickCallback (internal/process/next_tick.js:63:19)
In the code above we can see that the URL is made up of a base URL, the method (“publish”) and args, which in this case is null. So that URL makes sense, although it seems a bit strange to me.
If I issue a GET request to that URL I get some JSON back telling me I’m not logged in, so the URL does indeed exist. I haven’t tried a manual PUT request
So the URL does exist, but something is generating a 404 error. I suspect the backend is a Rails server. Rails can generate 404 errors if the code tries to find a record that does not exist, so this 404 could mean that something in the request body doesn’t match records that exist on the server side. (I’m being vague because I don’t know anything about the Expo team’s servers.)
It might be worth patching _uploadArtifactAsync in expo-cli’s packages/xdl/src/Project.ts file to log the contents of formData to see if that gives us any more hints.
and since last submission, we haven’t changed anything in package.jon nor app.json, except for the build number in app.json, the manifest seems ok, since it’s reading the correct build number (38)
Sorry, yes, of course Charles would have captured that
I was hoping something in formData might give us some inspiration, but nothing in your screenshot jumps out at me. I’m running out of ideas
@charliecruzan/@adamjnav any ideas what could cause the server to send back a 404 Not Found error when trying to PUT the JavaScript bundles to https://exp.host/--/api/publish/null while running expo publish? Or if that URL is incorrect, where things might be going wrong?
No major changes to app.json since the last time you were publishing/building? Have you made any recent account settings changes? Longshot, but do you when was the last time you were able to publish/build successfully?
We’re having (I believe) the same issue on expo publish. I believe it started occurring after the expo.io site went down a few days ago but am not certain on this.