Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Internal Server Error (500): APPX package generation failed. Error: Failed to unpack the uploaded content archive. #287

Open
devunion opened this issue Feb 15, 2018 · 26 comments

Comments

Projects
None yet
@devunion
Copy link

commented Feb 15, 2018

I was able to build APPX for Edge extension in the morning, but started to get the next exception after a couple of hours:

[debug] manifoldjs : Loading platform module: manifoldjs-edgeextension [debug] manifoldjs : Packaging the 'Microsoft Edge Extension Platform' app... [info ] edgeextension: Packaging the Microsoft Edge Extension Platform app... [debug] manifoldjs : Unable to create the package locally. Invoking the CloudAppX service instead... [debug] manifoldjs : Invoking the CloudAppX service... [error] manifoldjs : Failed to package the Microsoft Edge Extension Platform app. at C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\manifoldjs-lib\lib\projectBuilder.js:140:29 at _rejected (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:864:24) at C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:890:30 at Promise.when (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:1142:31) at Promise.promise.promiseDispatch (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:808:41) at C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:624:44 at runSingle (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:137:13) at flush (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:125:13) at _combinedTickCallback (internal/process/next_tick.js:131:7) at process._tickCallback (internal/process/next_tick.js:180:9) Failed to create the package. The CloudAppX service returned an error - Internal Server Error (500): APPX package generation failed. Error: Failed to unpack the uploaded content archive. at Request._callback (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\manifoldjs-edgeextension\lib\appPackage.js:72:32) at Request.self.callback (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\request\request.js:186:22) at emitTwo (events.js:126:13) at Request.emit (events.js:214:7) at Request.<anonymous> (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\request\request.js:1163:10) at emitOne (events.js:116:13) at Request.emit (events.js:211:7) at IncomingMessage.<anonymous> (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\request\request.js:1085:12) at Object.onceWrapper (events.js:313:30) at emitNone (events.js:111:20) [error] manifoldjs : One or more platforms could not be generated successfully. at C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\manifoldjs-lib\lib\projectBuilder.js:28:23 at _fulfilled (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:854:54) at self.promiseDispatch.done (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:883:30) at Promise.promise.promiseDispatch (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:816:13) at C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:624:44 at runSingle (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:137:13) at flush (C:\Users\Ириша\AppData\Roaming\npm\node_modules\manifoldjs\node_modules\q\q.js:125:13) at _combinedTickCallback (internal/process/next_tick.js:131:7) at process._tickCallback (internal/process/next_tick.js:180:9)

My build script is based on this tutorial: https://docs.microsoft.com/en-us/microsoft-edge/extensions/guides/packaging/using-manifoldjs-to-package-extensions

PS. Also can't build the app with the help of makeappx.exe tool. It fails with empty error message. Does anyone have an idea how to pack Edge extension?

@boyofgreen

This comment has been minimized.

Copy link
Member

commented Feb 16, 2018

Hello,
I've reached out to a few of the devs who support it. What OS are you working on?

@devunion

This comment has been minimized.

Copy link
Author

commented Feb 17, 2018

@boyofgreen

This comment has been minimized.

Copy link
Member

commented Feb 23, 2018

Hi @devunion someone should be jumping in shortly. We were not able to re-create, so we have a few additional questions.

@tomayac

This comment has been minimized.

Copy link

commented Jul 16, 2018

My extension contained a (naturally big) node_modules folder that was needed only for the development phase (linting, etc.). I removed this folder manually from the to-be-packaged extension folder and it worked. Looks like the "CloudAppX" service should contain a check regarding packaging size or warn about (or plain refuse to) package a node_modules folder.
CC: @boyofgreen

@boyofgreen

This comment has been minimized.

Copy link
Member

commented Jul 19, 2018

Thanks for letting me know. We've been fighting this issue where some seemingly "random" sites fail generation. We will look at file size and see if that might be the key.

@boyofgreen

This comment has been minimized.

Copy link
Member

commented Jul 19, 2018

@michael-hawker lets discuss and see if we can carve out some of your time to look at this issue. Maybe we need to not ship all the dev components when we do the appx

@tomayac

This comment has been minimized.

Copy link

commented Aug 13, 2018

@boyofgreen @michael-hawker Any update on this? I am able to reproduce this 100% of the times :-/ on ManifoldJS 0.7.6.

$ manifoldjs -l debug -p edgeextension package SWDetector/edgeextension/manifest
[debug] manifoldjs  : Loading platform module: manifoldjs-edgeextension
[debug] manifoldjs  : Packaging the 'Microsoft Edge Extension Platform' app...
[info ] edgeextension: Packaging the Microsoft Edge Extension Platform app...
[debug] manifoldjs  : Unable to create the package locally. Invoking the CloudAppX service instead...
[debug] manifoldjs  : Invoking the CloudAppX service...
[error] manifoldjs  : Failed to package the Microsoft Edge Extension Platform app.
                          at /usr/local/lib/node_modules/manifoldjs/node_modules/manifoldjs-lib/lib/projectBuilder.js:140:29
                          at _rejected (/usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:864:24)
                          at /usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:890:30
                          at Promise.when (/usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:1142:31)
                          at Promise.promise.promiseDispatch (/usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:808:41)
                          at /usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:624:44
                          at runSingle (/usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:137:13)
                          at flush (/usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:125:13)
                          at process._tickCallback (internal/process/next_tick.js:61:11)
                      Failed to create the package. The CloudAppX service returned an error - Internal Server Error (500): There was an error generating the APPX package.
                          at Request._callback (/usr/local/lib/node_modules/manifoldjs/node_modules/manifoldjs-edgeextension/lib/appPackage.js:72:32)
                          at Request.self.callback (/usr/local/lib/node_modules/manifoldjs/node_modules/request/request.js:185:22)
                          at Request.emit (events.js:182:13)
                          at Request.<anonymous> (/usr/local/lib/node_modules/manifoldjs/node_modules/request/request.js:1161:10)
                          at Request.emit (events.js:182:13)
                          at IncomingMessage.<anonymous> (/usr/local/lib/node_modules/manifoldjs/node_modules/request/request.js:1083:12)
                          at Object.onceWrapper (events.js:273:13)
                          at IncomingMessage.emit (events.js:187:15)
                          at endReadableNT (_stream_readable.js:1081:12)
                          at process._tickCallback (internal/process/next_tick.js:63:19)
[error] manifoldjs  : One or more platforms could not be generated successfully.
                          at /usr/local/lib/node_modules/manifoldjs/node_modules/manifoldjs-lib/lib/projectBuilder.js:28:23
                          at _fulfilled (/usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:854:54)
                          at /usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:883:30
                          at Promise.promise.promiseDispatch (/usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:816:13)
                          at /usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:624:44
                          at runSingle (/usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:137:13)
                          at flush (/usr/local/lib/node_modules/manifoldjs/node_modules/q/q.js:125:13)
                          at process._tickCallback (internal/process/next_tick.js:61:11)
@dylanlrrb

This comment has been minimized.

Copy link

commented Aug 13, 2018

I am also seeing this exact same error 100% of the time - has there been any update on this?

@thomasingalls

This comment has been minimized.

Copy link

commented Aug 13, 2018

I am also seeing this since Friday, cannot build.

@boyofgreen

This comment has been minimized.

Copy link
Member

commented Aug 13, 2018

Hi Folks, we are looking at this. Hey @thomasingalls , @dylanlrrb or @tomayac can you try preview.pwabuilder.com and see if that works for you? I think I might have a redis cache that is full somewhere. Also what part of the world are you in ?

@dylanlrrb

This comment has been minimized.

Copy link

commented Aug 14, 2018

@boyofgreen I'm in the San Francisco bay area.

@dm-trushin

This comment has been minimized.

Copy link

commented Aug 14, 2018

@boyofgreen I have a similar problem.
I'm based in Russia.

@tomayac

This comment has been minimized.

Copy link

commented Aug 14, 2018

@boyofgreen When I try pwabuilder v2.3.0 (i.e., simply replacing manifoldjs in the command with pwabuilder), this is what I get:

$ pwabuilder -l debug -p edgeextension package SWDetector/edgeextension/manifest/
[debug] pwabuilder  : Available platforms within project:
[debug] pwabuilder  : Packaging the following platforms:

FWIW, I'm based out of Hamburg, Germany.

@running-codebase

This comment has been minimized.

Copy link

commented Aug 14, 2018

@boyofgreen I am also experiencing this issue in Melbourne, Australia.

@TrLucas

This comment has been minimized.

Copy link

commented Aug 14, 2018

@boyofgreen We also experience this while attempting to build Adblock Plus for Edge.

Using pwabuilder for packaging, instead of ManifoldJS yields the same result as for @tomayac :

[debug] pwabuilder  : Available platforms within project: 
[debug] pwabuilder  : Packaging the following platforms: 

Tried both ManifoldJS and pwabuilder packaging from several locations across germany.

@dylanlrrb

This comment has been minimized.

Copy link

commented Aug 14, 2018

@boyofgreen Just an update - any attempts I make at packaging the app with preview.pwabuilder.com fails with this error in the console:

D:\home\site\wwwroot\node_modules\axios\lib\adapters\xhr.js:178 POST https://manifold-api-prod-staging.azurewebsites.net/manifests/0a01ac98/appx 500 (Internal Server Error)

@boyofgreen

This comment has been minimized.

Copy link
Member

commented Aug 15, 2018

Hi Guys, the APPX server is back up. It should be working for everyone except for @tomayac where we still have the file size issue (addressing in sept)

@TrLucas

This comment has been minimized.

Copy link

commented Aug 15, 2018

@boyofgreen thanks for the update! A minimal setup (which used to fail too) is working again, however the full setup still fails:

[error] manifoldjs  : Failed to package the Microsoft Edge Extension Platform app.
                      Failed to create the package. The CloudAppX service returned an error - Internal Server Error (500): APPX package generation failed. Error: Command failed: 
[error] manifoldjs  : One or more platforms could not be generated successfully.
                      For more information, run manifoldjs with the diagnostics level set to debug (e.g. manifoldjs [...] -l debug)

Could you clarify the size limits? Maybe that's a problem for us too.

@tomayac for comparison, could you tell me what size your tree is pre-packaging?

Thanks in advance!

@tomayac

This comment has been minimized.

Copy link

commented Aug 15, 2018

Wowza, it just worked for me. My manifest folder weighs just 879 KB. I had size issues before, when (more or less accidentally) I tried to package the node_modules folder on top, which was only needed during development.

@THeflinKeeper

This comment has been minimized.

Copy link

commented Sep 7, 2018

Hello all, I'm getting the The CloudAppX service returned an error - Internal Server Error (500) error. Is the server down again?

@danmofo

This comment has been minimized.

Copy link

commented Sep 11, 2018

Started seeing this a few days ago, cannot build.

Edit (14/09/2018): seems to be working again.

@snoack

This comment has been minimized.

Copy link

commented Sep 11, 2018

I can confirm, about a month ago it worked again with extensions that were smaller than about 1MB. Now, it seems to fail again regardless of the size.

FWIW, for us (@adblockplus), it doesn't make much of a difference, as we couldn't build our extension for Microsoft Edge anymore since this issue first came up due to our size of >1MB.

@tregagnon

This comment has been minimized.

Copy link

commented Sep 12, 2018

Same issue here @Dashlane, we always get the error 500 from the CloudAppX service. It was working last week. (with an extension larger than 1MB)

@geoffdutton

This comment has been minimized.

Copy link

commented Sep 27, 2018

I'm getting this issue as well. Haven't seen it before today.

Edit: It seems to be back up as of today (2018-10-01).

@djacobow

This comment has been minimized.

Copy link

commented Sep 28, 2018

Getting this right now. The last time I built the same extension, about two weeks ago, no problem. Today, no dice. In the USA.

I just tried this again with the exact same folder/contents as I did last month and it failed. So something is definitely amiss with the CloudAppX, it seems.

@snoack

This comment has been minimized.

Copy link

commented Oct 31, 2018

For reference, eventually it turned out that for us (@adblockplus) this issue was unrelated of the size of the package (unlike previously suspected), but due to translating the extension's name into Azerbajani. Any of the following workarounds caused manifoldjs to build the extension successfully:

  1. Removing the translation used in the name key in manifest.json from _locales/az/messages.json.
  2. Renaming _locales/az/ to _locales/az-latn/.
  3. Hard-coding the value of the name key in manifest.json (not translating it).

In the end, we went with option 3 due to another issue with the Windows Store, that caused the build to be rejected if you haven't registered every translation of your extension's name.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.