It may not be related, but the path that you are building to is incredibly long and contains a mixture of characters which I would typically avoid.
You have mentioned that it built on your notepad, so that’s a good thing, often build issues with WebGL are caused by the downloading/installation of the WebGL component separately to the main Unity installation. Often people grab an incompatible version.
So, first question, when you installed Unity, did you select WebGL during the installation, or, did you download it separately afterwards and install it?
I would lean more towards the separate install of WebGL as being the issue personally, as pretty much everyone I’ve seen on here having a problem has had that scenary, e.g. where it has been installed separately.
If you have the time, then I would suggest removing your Unity installation from the notebook again, double check everything has gone, e.g. there aren’t any unity directories left over etc. Then re-install, select the option and make sure that the short cut icon that is created is pointing to the path where you installed it, e.g. it’s not a left-over pointing to another version or anything like that. Worst case, browse to the install directory and launch Unity from there.
The path is possible, but as you’ve had it working else where I’d suggest probably not the case. Older version of Visual Studio for example had a maximum length for the path for a project, if it was created from within Visual Studio, so creating projects in a C:\Users\someone… directory was/is typically bad. Personally I tend to have a E:\Dev\ directory, followed by the name of the project. I also avoid spaces and any special characters in the path name.
Have you done the clear down and re-install now on the PC, or is that still to happen?
Normally comes down to having an incompatible WebGL package installed for the version of Unity.
Again, out of curiosity, is there anything configured differently with either of these regarding locale/language settings?
I note the error message in your first screenshot is unhappy about the path, just wondering if again any of these more specific characters might be an issue. But if that was the case, I would expect to see a difference in the path on the working machine. That said, you probably are not using the same path on both machines are you?
I have just done the clear down and am about to reinstall!
I have just checked and both machines have same language and locale.
I am not using the same path for the project folders, but both had spaces and hifens “-” in them, I thought C# Written on the path could be the problem and removed it but nothing changed on the error.
Regarding the installation on the machines, I did both of them in the default location, no changes.
Idk if this’ll help but I can build .EXE standalone files just fine:
And here’s the result after removing all spaces and non latin characters, aswell as placing the project folder straight on a C: folder
SO IT WORKS! Thanks a lot for your patience, Rob!
I won’t be marking this as solved for now because I’ll now try and figure out which of the variables was the one that created this error, after that I’ll post the lessons learned here and at the Udemy Q&A!
For the solution part:
So, after a few hours analyzing the problem, here’s what I found out:
1- Reinstalling did not solve these errors;
2- Separate install of WebGL build tool was not the problem;
3- Spaces and numbers in the directory’s names have no impact on the WebGL Build process;
4- Path length was not a problem (on my project), as I kept my files on the Desktop and the build ran fine;
THEN WHAT DID YOU FIND OUT?
I found out that two things will freeze the WebGL builder:
1- Non-english characters, such as “ç”, a letter used a lot in portuguese.
2- Using accents on letters, such as “á”, “à”, “ã”, etc.
ANYTHING ELSE?
Yes, this only happens on the WebGL compiler, the Win/Lin/Mac Standalone compiler has no issues with these kind of characters.
I hope this information can help people in the future, I decided to be this thorough in my explanation because everything I found online was only half answers and that got me MAD, so here you go
Thank you very much for your help, Rob, nice team work!
Great write up of your analysis, I’m sure this will be beneficial to others going forward, thank you.
I suspect the non-english characters are perhaps an issues because when the game is run on the web they would need to be URL encoded perhaps, where-as locally, this wouldn’t be an issue. Not sure, might see if I can find out any more on that.
Thanks again for a great write up and you’re welcome