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. Dismiss Notice

FileNotFoundException Build.data.gz.compressed

Discussion in 'WebGL' started by Kozaki2, Aug 22, 2020.

  1. Kozaki2

    Kozaki2

    Joined:
    Apr 8, 2019
    Posts:
    47
    Hello, I am trying to build my webgl game but I have FileNotFoundException
    System: Ubuntu 20.04
    Unity version: 2020.1.1f1

    Filename: gzip
    Arguments: -9 --keep -S ".compressed" "/home/konradkozaczenko/Łowca - mistrz strzały/Temp/StagingArea/Data/Output/Build/Build.data.gz"
    index: -1
    FileNotFoundException: Could not find file "/home/konradkozaczenko/Łowca - mistrz strzały/Temp/StagingArea/Data/Output/Build/Build.data.gz.compressed"
    at System.IO.FileStream..ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share, System.Int32 bufferSize, System.Boolean anonymous, System.IO.FileOptions options) [0x0019e] in <fb001e01371b4adca20013e0ac763896>:0
    at System.IO.FileStream..ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share) [0x00000] in <fb001e01371b4adca20013e0ac763896>:0
    at (wrapper remoting-invoke-with-check) System.IO.FileStream..ctor(string,System.IO.FileMode,System.IO.FileAccess,System.IO.FileShare)
    at System.IO.File.OpenRead (System.String path) [0x00000] in <fb001e01371b4adca20013e0ac763896>:0
    at System.IO.File.ReadAllBytes (System.String path) [0x00000] in <fb001e01371b4adca20013e0ac763896>:0
    at UnityEditor.WebGL.WebGlBuildPostprocessor.SetGzipComment (System.String path, System.String comment) [0x00001] in /Users/builduser/buildslave/unity/build/PlatformDependent/WebGL/Extensions/Unity.WebGL.extensions/BuildPostprocessor.cs:761
    at UnityEditor.WebGL.WebGlBuildPostprocessor.CompressAndMarkGzip (System.String path) [0x000aa] in /Users/builduser/buildslave/unity/build/PlatformDependent/WebGL/Extensions/Unity.WebGL.extensions/BuildPostprocessor.cs:815
    at UnityEditor.WebGL.WebGlBuildPostprocessor.CompressBuild (UnityEditor.Modules.BuildPostProcessArgs args) [0x00058] in /Users/builduser/buildslave/unity/build/PlatformDependent/WebGL/Extensions/Unity.WebGL.extensions/BuildPostprocessor.cs:851
    at UnityEditor.WebGL.WebGlBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args) [0x002f5] in /Users/builduser/buildslave/unity/build/PlatformDependent/WebGL/Extensions/Unity.WebGL.extensions/BuildPostprocessor.cs:920
    at UnityEditor.Modules.DefaultBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args, UnityEditor.BuildProperties& outProperties) [0x00001] in /home/bokken/buildslave/unity/build/Editor/Mono/Modules/DefaultBuildPostprocessor.cs:27
    at UnityEditor.PostprocessBuildPlayer.Postprocess (UnityEditor.BuildTargetGroup targetGroup, UnityEditor.BuildTarget target, 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) [0x000dc] in /home/bokken/buildslave/unity/build/Editor/Mono/BuildPipeline/PostprocessBuildPlayer.cs:324

    In folder Temp/StagingArea/Data/Output/Build/ I have files:
    • Build.data.gz
    • Build.framework.js.gz
    • Build.loader.js
    • Build.wasm.gz

    So there is no file Build.data.gz.compressed. How can I deal with it?
     
    Last edited: Aug 27, 2020
    Ishidres and Tacodude like this.
  2. ShaneChristopher

    ShaneChristopher

    Joined:
    Nov 6, 2018
    Posts:
    12
    I'm also having this issue while building locally, any help would be great.
     
  3. ShaneChristopher

    ShaneChristopher

    Joined:
    Nov 6, 2018
    Posts:
    12
    For me this seems to be an issue on Linux (Ubuntu 18.04) on 2020.1.3f1. I just tried with the same Unity version on Windows 10 and the build worked.
     
    Ishidres likes this.
  4. Kozaki2

    Kozaki2

    Joined:
    Apr 8, 2019
    Posts:
    47
    Yes, I am using Ubuntu 20.04 and Unity version is
    You're right, my system is Ubuntu 20.04 and Unity 2020.1.1f1
     
  5. ShaneChristopher

    ShaneChristopher

    Joined:
    Nov 6, 2018
    Posts:
    12
    Disabling compression of the build allowed me to build on Linux again, that was to resolve another issue where compressed builds were no longer loading in the browser. It really looks like 2020.1 has added a lot of new bugs when it comes to WebGl builds.
     
  6. Kozaki2

    Kozaki2

    Joined:
    Apr 8, 2019
    Posts:
    47
    Refresh... I'm still facing this issue and don't know what to do. I don't want to disable compression :/
    I can see in editor logs following lines
    Code (csharp):
    1. Filename: gzip
    2. Arguments: -9 --keep -S ".compressed" "/home/konradkozaczenko/Łowca - vfix/Temp/StagingArea/Data/Output/Build/Build.data.gz"
    3. index: -1
    4. FileNotFoundException: Could not find file "/home/konradkozaczenko/Łowca - vfix/Temp/StagingArea/Data/Output/Build/Build.data.gz.compressed"
    When I tried running this command direct in terminal I got
    Code (csharp):
    1.  
    2. gzip -9 --keep -S ".compressed" "/home/konradkozaczenko/Łowca - vfix/Temp/StagingArea/Data/Output/Build/Build.data.gz"
    3. gzip: /home/konradkozaczenko/Łowca - vfix/Temp/StagingArea/Data/Output/Build/Build.data.gz already has .gz suffix -- unchanged
     
    Last edited: Nov 8, 2020
  7. jukka_j

    jukka_j

    Unity Technologies

    Joined:
    May 4, 2018
    Posts:
    944
    I wonder if it gets confused by the non-ASCII character Ł in the path name? Can you try locating the project into a path that only has ASCII characters to diagnose?
     
  8. Noxalus

    Noxalus

    Joined:
    Jan 9, 2018
    Posts:
    80
    I have the same issue on a build server with a more conventional path => here.

    I'm using Unity 2020.1.12f1 and I have no difficulty to build for WebGL on my local machine (Windows 10).
     
  9. jukka_j

    jukka_j

    Unity Technologies

    Joined:
    May 4, 2018
    Posts:
    944
    Hmm, upon further inspection this does look like a Linux specific issue. Would someone be able to raise a bug report about this?
     
  10. Noxalus

    Noxalus

    Joined:
    Jan 9, 2018
    Posts:
    80
    Disabling the compression I have no problem to build anymore on my build server:

    Code (CSharp):
    1. PlayerSettings.WebGL.compressionFormat = WebGLCompressionFormat.Disabled;
     
  11. jacobgmartin

    jacobgmartin

    Joined:
    Sep 10, 2015
    Posts:
    37
    The same issue happened to me with 2020.1 on linux and disabling compression fixed it.
     
  12. undefined666

    undefined666

    Joined:
    Apr 3, 2018
    Posts:
    53
    @Noxalus
    Could you specify where I have to add this record?
    Is it in ProjectSettings.asset?
    I see different format there. Like
    Code (CSharp):
    1.  m_ShowUnitySplashScreen: 1
    2.   m_ShowUnitySplashLogo: 1
     
  13. Noxalus

    Noxalus

    Joined:
    Jan 9, 2018
    Posts:
    80
    It's in the script you use to make your build.

    If you don't have this kind of script and you use the Unity window to make your build, you will find this option in the Player Settings:

    upload_2021-1-4_20-54-32.png
     
  14. kentg1

    kentg1

    Joined:
    Dec 22, 2014
    Posts:
    167
    Disabled does not work