500 Internal Server Error When Publish to WebGL in Unity

Опубликовано: 01 Декабрь 2022
на канале: DA LAB
1,945
16

Recently, I have been getting http/1.1 500 internal server error when I build and publish to WebGL in Unity. Sometimes the project builds and publishes to webGL successfully but only loads up to 90% online and then fails to work.
The code of my project contains web requests and download handlers.

There are different suggestions to fix the issue.
Restart Unity Editor and Unity Hub
Restart the PC
Change the player project settings
Not blocking WebRequest in the code. Get rid of while, if and other statements that may block the request.

I have tried all these suggestions. None seems to fix the issue.

The error is random. My project sometimes builds and publishes successfully to webGL, and sometimes I get the 500 internal server error.

This randomness may confuse a person about what solution would work. If the project randomly publishes successfully to the web, a person may think that the fix they tried is the right answer.

So, I thought, what if I keep trying to build and publish to WebGL over and over until the publishing is successful?

It worked eventually.

I still don’t understand the reason for that error, given 500 internal server error is general by nature. It could be a Unity bug or something else.

However, the repetitive trial of building and publishing to webGL seems a temporary fix.


На этой странице сайта вы можете посмотреть видео онлайн 500 Internal Server Error When Publish to WebGL in Unity длительностью часов минут секунд в хорошем качестве, которое загрузил пользователь DA LAB 01 Декабрь 2022, поделитесь ссылкой с друзьями и знакомыми, на youtube это видео уже посмотрели 1,945 раз и оно понравилось 16 зрителям. Приятного просмотра!