Search Unity

  1. Unity 2018.3 is now released.
    Dismiss Notice
  2. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  3. Want more efficiency in your development work? Sign up to receive weekly tech and creative know-how from Unity experts.
    Dismiss Notice
  4. Build games and experiences that can load instantly and without install. Explore the Project Tiny Preview today!
    Dismiss Notice
  5. Nominations have been announced for this years Unity Awards. Celebrate the wonderful projects made by your peers this year and get voting! Vote here!
    Dismiss Notice
  6. Want to provide direct feedback to the Unity team? Join the Unity Advisory Panel.
    Dismiss Notice
  7. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice

Building in headless mode with -quite does not shutdown unity after build

Discussion in 'Linux Editor' started by Krstn, Sep 17, 2018.

  1. Krstn

    Krstn

    Joined:
    Dec 30, 2012
    Posts:
    21
    I have this command line to build my app:

    Code (CSharp):
    1. /opt/Unity-2018.2.7f1/Editor/Unity -quit -batchmode -nographics -logFile /root/stdout.log  -buildTarget WebGL -projectPath /root/projects/dw_bo_unity_positioning -executeMethod WebGLBuilder.buildDev
    My WebGLBuilder.buildDev method looks like:

    Code (CSharp):
    1.         string[] scenes = {"Assets/Scenes/Scene.unity"};
    2.  
    3.         string pathToDeploy = "webglbuild-dev/unity";
    4.  
    5.         PlayerSettings.WebGL.compressionFormat = WebGLCompressionFormat.Gzip;
    6.         PlayerSettings.WebGL.linkerTarget = WebGLLinkerTarget.Asm;
    7.         PlayerSettings.WebGL.memorySize = 256;
    8.         PlayerSettings.WebGL.dataCaching = true;
    9.         PlayerSettings.WebGL.exceptionSupport = WebGLExceptionSupport.FullWithStacktrace;
    10.         PlayerSettings.WebGL.useEmbeddedResources = true;
    11.         PlayerSettings.WebGL.emscriptenArgs = "-s ALLOW_MEMORY_GROWTH=1";
    12.      
    13.         BuildPipeline.BuildPlayer(scenes, pathToDeploy, BuildTarget.WebGL, BuildOptions.None);
    And as stated in the title, in most of the cases, the build finishes and is "hanging", while after I kill Unity and some nodejs Unity related process the next build will pass ok.

    If someone could shed some light, I would be grateful. This is happening with versions 2018.2.2 -> 2018.2.7


    When the Unity does not shut down, in logs, I DON"T have this line:

    [Package Manager] Server::Kill -- Server was shutdown
     
    Last edited: Sep 17, 2018
  2. george_vasilchenko

    george_vasilchenko

    Joined:
    Sep 20, 2014
    Posts:
    3
    Got the same here while building Android project. Version 2018.2.10
    Output:
    Refresh: detecting if any assets need to be imported or removed ...
    Refresh: elapses 0.054368 seconds (Nothing changed)
    Refresh completed in 0.054442 seconds.
    [Package Manager] Server::Kill -- Server was shutdown
    Cleanup mono
    Checking for leaked weakptr:
    Found no leaked weakptrs.
    ##utp:{"type":"MemoryLeaks","allocatedMemory":431182,"memoryLabels":[{"Default":1292},{"NewDelete":262521},{"Thread":8},{"Manager":296},{"VertexData":96},{"GfxDevice":528},{"FMOD":640},{"Physics":1},{"Serialization":40},{"String":55004},{"DynamicArray":23298},{"Curl":1336},{"PoolAlloc":120},{"Sprites":8},{"GI":480},{"VR":1516},{"EditorGui":40},{"EditorUtility":416},{"AssetImporter":32},{"RestService":64},{"UnityConnect":17000},{"Collab":696},{"Upm":65750}]}