Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Join us on Dec 8, 2022, between 7 am & 7 pm EST, in the DOTS Dev Blitz Day 2022 - Q&A forum, Discord, and Unity3D Subreddit to learn more about DOTS directly from the Unity Developers.
    Dismiss Notice
  3. Have a look at our Games Focus blog post series which will show what Unity is doing for all game developers – now, next year, and in the future.
    Dismiss Notice

Bug WebGL Build Not Working

Discussion in 'Editor & General Support' started by danpantz, Sep 14, 2022.

  1. danpantz

    danpantz

    Joined:
    Nov 17, 2020
    Posts:
    3
    Using Unity 2021.3.6f1, I keep getting these build errors when trying to build for WebGL. I've tried uninstalling and reinstalling, but I always get these same errors. Any idea what a solution might be?

    1:
    Building Library\Bee\artifacts\WebGL\build\debug_WebGL_wasm\build.js failed with output:
    Traceback (most recent call last):
    File "C:\Program Files\Unity\Hub\Editor\2021.3.6f1\Editor\Data\PlaybackEngines\WebGLSupport\BuildTools\Emscripten\emscripten\emcc2.py", line 3571, in <module>
    sys.exit(main(sys.argv))
    File "C:\Program Files\Unity\Hub\Editor\2021.3.6f1\Editor\Data\PlaybackEngines\WebGLSupport\BuildTools\Emscripten\emscripten\emcc2.py", line 3564, in main
    ret = run(args)
    File "C:\Program Files\Unity\Hub\Editor\2021.3.6f1\Editor\Data\PlaybackEngines\WebGLSupport\BuildTools\Emscripten\emscripten\emcc2.py", line 944, in run
    args = substitute_response_files(args)
    File "C:\Program Files\Unity\Hub\Editor\2021.3.6f1\Editor\Data\PlaybackEngines\WebGLSupport\BuildTools\Emscripten\emscripten\tools\response_file.py", line 116, in substitute_response_files
    new_args += read_response_file(arg)
    File "C:\Program Files\Unity\Hub\Editor\2021.3.6f1\Editor\Data\PlaybackEngines\WebGLSupport\BuildTools\Emscripten\emscripten\tools\response_file.py", line 103, in read_response_file
    args = shlex.split(args)
    File "D:\obj\windows-release\37amd64_Release\msi_python\zip_amd64\shlex.py", line 305, in split
    File "D:\obj\windows-release\37amd64_Release\msi_python\zip_amd64\shlex.py", line 295, in __next__
    File "D:\obj\windows-release\37amd64_Release\msi_python\zip_amd64\shlex.py", line 105, in get_token
    File "D:\obj\windows-release\37amd64_Release\msi_python\zip_amd64\shlex.py", line 187, in read_token
    ValueError: No closing quotation
    UnityEngine.GUIUtility:processEvent (int,intptr,bool&)

    2:
    BuildFailedException: Incremental Player build failed!
    UnityEditor.Modules.BeeBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args) (at <44a70d1b13cf47e29810e30f45ffae08>:0)
    UnityEditor.WebGL.WebGlBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args) (at /Users/bokken/buildslave/unity/build/PlatformDependent/WebGL/Extensions/Unity.WebGL.extensions/BuildPostprocessor.cs:158)
    UnityEditor.Modules.DefaultBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args, UnityEditor.BuildProperties& outProperties) (at <44a70d1b13cf47e29810e30f45ffae08>:0)
    UnityEditor.PostprocessBuildPlayer.Postprocess (UnityEditor.BuildTargetGroup targetGroup, UnityEditor.BuildTarget target, System.Int32 subtarget, System.String installPath, System.String companyName, System.String productName, System.Int32 width, System.Int32 height, UnityEditor.BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry, UnityEditor.Build.Reporting.BuildReport report) (at <44a70d1b13cf47e29810e30f45ffae08>:0)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr, Boolean&)

    3:
    Build completed with a result of 'Failed' in 3 seconds (2977 ms)
    UnityEngine.GUIUtility:processEvent (int,intptr,bool&)

    4:
    UnityEditor.BuildPlayerWindow+BuildMethodException: 3 errors
    at UnityEditor.BuildPlayerWindow+DefaultBuildMethods.BuildPlayer (UnityEditor.BuildPlayerOptions options) [0x002da] in <44a70d1b13cf47e29810e30f45ffae08>:0
    at UnityEditor.BuildPlayerWindow.CallBuildMethods (System.Boolean askForBuildLocation, UnityEditor.BuildOptions defaultBuildOptions) [0x00080] in <44a70d1b13cf47e29810e30f45ffae08>:0
    UnityEngine.GUIUtility:processEvent (int,intptr,bool&)
     
  2. danpantz

    danpantz

    Joined:
    Nov 17, 2020
    Posts:
    3
    A little follow-up: I've since tried deleting the library folder and other folders that get recreated on launch, but nothing has changed. I've also encountered a unity package manager error when creating a new project in 2021.3.9, saying "No such file or directory". I think these might be correlated somehow, but not sure how. Attached is the editor.log for the original build error.
     

    Attached Files: