HTML5 build failed with multiple errors

Hello there!
I’m trying to build html5 version of project, but no matter what launch settings i’m using, keep getting the same errors:

  • UnrealBuildTool: Internal compiler error in src/compiler.js! Please raise a bug report at Issues · emscripten-core/emscripten · GitHub with a log of the build and the input files used to run. Exception message: “TypeError: Cannot read property ‘toString’ of undefined” | TypeError: Cannot read property ‘toString’ of undefined
  • UnrealBuildTool: AssertionError: Emscripten failed to generate .js
  • UnrealBuildTool: ValueError: need more than 1 value to unpack
  • UnrealBuildTool: ERROR: UBT ERROR: Failed to produce item: D:\Smug\Smuggler\Binaries\HTML5\Smuggler-HTML5-Shipping.js
  • ErrorReporter.Error: ERROR: AutomationTool error: Command failed (Result:2): C:\Program Files\Epic Games\4.7\Engine\Binaries\DotNET\UnrealBuildTool.exe Smuggler HTML5 Shipping D:\Smug\Smuggler\Smuggler.uproject -noxge -rocket -NoHotReloadFromIDE. See logfile for details: ‘UnrealBuildTool.txt’

What am i doing wrong, can anyone tell? I would really appreciate any help! Log’s attached:
[Log_file][1]

Thanks!

42379-projectlauncher.log (123 KB)

I have the same issue

Windows 7 64-bit

Unrel engine 4.7.6 binary distribution.

Hey ,

Have you tried to package any other project the same exact way in 4.7.6? Also, have you tried packaging this project and another project, such as First Person Template in 4.8 Preview 2? Could you please provide me the exact steps you’ve taken to package your project so I can also try to reproduce this?

Looking forward to hearing from you, thanks!

Hi,

We’ve seen this a when moving from one SDK version to another and looks to be a bug in the emscripten compiler. The way around it I’ve been using is to go to your emscripten install directory and open a command window in the correct sdk version folder (e.g. C:\Program Files\Emscripten\emscripten\1.30.0). Then run the commands “emcc --clear-cache” and then run “embuilder.py build struct_info”. Make sure both these commands complete ok. Hopefully, after that you’ll be able to build again.

Hi!
Thanks for advice, i’ll try this!

Hallo! Thank you for answering me!
Yes, i’ve tried to package example puzzle game for ff and it was working just fine. Maybe, i should try to add some code there and look again…
About 4.8 preview - no, didn’t try.
So my steps are: 1) in project launcher i’ve created new profile for html5; 2) build config - shipping; 3) cook: platforms html5, culture en, cooked maps - mark only 5 i need in my build; in advanced store all in a single file, shipping; 4) package and store locally; 5) deploy - i’ve tried copy to device and file server, also tried both chrome 64 and ff nighly 64; 6) launch default role with vsync.

Hey ,

Did JoJo_2nd’s suggestions fix the issue you were running in to?

Looking forward to hearing from you, thanks! :slight_smile:

Hi!
Didn’t help - emcc command fails with syntax error. I found out that in my system path was wrong adress to emscripten folder. Tried to change it manually and build game again, but it stucks on emscripten sanity checks. It starts them, but never finishes.

JoJo, hi again!)
emcc command fails with syntax error. I wonder if it may be caused by having two python versions installed on my laptop? If so, how could i influence emscripten choose the right one, more then just pointing its path in HTML5Engine.ini?

Two python version could cause an issue. To change the version used I’d ensure its on the PATH but the first thing on the PATH (so run “set PATH=‘python folder path’;%PATH%” in the command window to set it up) You can verify the version it’ll run with “python --version”. Then trying running the commands again.

UE4 is a little different when using python for emscripten. You set the python path in the ini and UE4 will force emscripten to use that python version (too avoid issues with multiple python installs) but only when building in visual studio, packaging in the editor, etc. It doesn’t effect emscripten globally.

Hi, JoJo!
I set python 2,7 first in path, then complitely reinstalled emscripten, then run the commands you suggested and after that all building succeded. It builds only then cooked on fly, but that’s better, than nothing.
Thank you so much for help!

Hey ,

I’m glad that Cook on the Fly is working for you however, since Cook by the Book isn’t working it would be best if you could post those error for us? Please submit them in your next reply as a .txt document.

Looking forward to hearing from you, thanks! :slight_smile:

Hi !
Sorry for the delay with answer. I’ve tried to pack project by-the-book with and without deploy. Without deploy it seems to pack successfully, but when i launch it in browser, i get js errors. When deploying it fails with automation tool error. I attach both and [js error list][1]. [Without deploy][2], [With deploy][3].

43060-jserrorlog.txt (4.37 KB)
[2]: 43071-projectlauncher_withoutdeploy.log (815 KB)
[3]: 43072-projectlauncher_copytodevice.log (821 KB)

Hey ,

I have been able to successfully package an HTML5 project using cook by the book without deploying and it has successfully packaged. Could you tell me how you set up Unreal Front End? You can attach screenshots to your next reply, whichever is easiest.

Thanks!

Hi!
Here are screenshots.

,

Hey ,

I have been able successfully package a project for HTML5 using the same steps that are within the images provided. However, I have spoken with the developers regarding the issue that you’re experiencing. Would it be possible to obtain a zipped version of your project? You can provide it to me through the forums in a private message that way it’s not free for the public to access.

Looking forward to hearing back from you, thanks!

Hi!
I’ve downloaded zip version of project to the cloud storage, so i can provide you a link. What’s the best way of doing it? Should i create a theme on the forum? Thank you so much for helping me!

Hey ,

You can submit a private message to me on the forums and the link will be hidden from the public by submitting it that way. Please make sure you have it set up to be downloaded by someone other than yourself.

I appreciate your assistance, thanks! :slight_smile:

Hey ,

I wanted to let you know that I’ve been in contact with one of our HTML5 developers to see what’s going on with the packaging process. I’m hoping to hear back from them soon.

Have a great day. :slight_smile:

Hey ,

I have heard back from one of the HTML5 developers this morning. He was able to successfully package your project without any trouble in 4.7.6. He said it went rather quickly for him as well, and all maps were included.

Have you tried 4.8.0 Preview 4 yet by the way?