Search Issue Tracker

Not Reproducible

Votes

0

Found in

2018.4

2018.4.26f1

2020.2

Issue ID

1275303

Regression

No

Editor freezes on cleanup mono after building the player when exiting after batchmode build

Mono

-

Reproduction steps:
1. Open attached project ("case_1275303-client") in File Explorer
2. Open the "build-android-exe-full.bat" file and set UnityPath to the local Unity path
3. Wait for the build to finish (~2 minutes)

Expected result: Build finishes without issues and the Editor is closed
Actual result: Editor sometimes freezes

Reproducible with: 2018.4.27f1, 2020.2.0b2

Note: Issue reproduces roughly in around 1 in 30 tries

Comments (19)

  1. leo_u

    Feb 08, 2022 00:39

    same here, 2021.2.10f1

  2. Delcasda

    Dec 28, 2021 23:58

    this happens to me on Unity 2021.2.4f1 every time I export for WebGL. Killing the child process mono.exe that holds the SimpleWebServer.exe task allows it to continue closing

  3. aimatme

    Dec 14, 2021 15:22

    Unity 2021.2.6f1 Editor freezes every time in batchmode with -quit param with text
    "Cleanup mono"

    If I kill JDK process then Editor continue closing

  4. enf3rno

    Nov 21, 2021 16:27

    for me this happens after updating to Unity 2021.2.2 when I want to end the Unity editor.

  5. manuelgoellnitz

    Nov 17, 2021 09:35

    for me this happens after updating to Unity 2021.2.2 when I want to end the Unity editor.

  6. Mwha

    Mar 24, 2021 13:34

    Same result, differents cause for us.

    Use Unity in batchmode (with -quit), call it twice in the same script, the second call will freeze after "Cleanup mono" (no performance report).

    Reproduced with Unity 2020.2 & Unity LTS 2020.3, last patch on Win10.

    Workaround for us: Add a sleep between the two calls (30s)

    Was fine until now with 2018.4

  7. petesplace

    Mar 23, 2021 14:47

    Using 2018.4.29f1 and experiencing the same issues.
    It happens very rarely (1 out of 30 times is a good guess) but completely messes up our backend pipelines as lots of bundles need to be built headless using jenkins on a windows server.

    Tried to refresh the asset database prior to quitting, tried to quit explicitly using EditorApplication.Quit, nothing works. Editor keeps running and builds never end.
    In the log file the last line is "Cleanup mono", nothing out of the ordinary in the logs despite that.

    I am having this issue for a while now, including in older unity releases (down to unity 5.6) and it keeps getting back. If its caused by our code that is fine but we have no way to debug this, no information in the log, no unusual warnings, nothing. Any help would be greatly appreciated but I honestly doubt unity knows how to fix it as they are not even capable of reproducing themself.

  8. ville-ps

    Feb 03, 2021 08:46

    We had this issue happening but found out it was caused by code in our project that used reflection to access internal editor classes UnityEditor.LogEntries and UnityEditor.LogEntry. Turns out these classes were updated in newer Unity version which caused the reflection to break and now incorrect usage of the LogEntries methods caused Unity to start logging assertion failed messages "Assertion failed on expression: '!m_IsGettingEntries'" and when quitting the editor it would freeze with "Cleanup mono" being the last line of editor log.

    Of course this might not be the only way to cause this freezing issue but if you do experience this please check your logs for any unusual error messages and search your codebase if it uses UnityEditor.LogEntries via reflection

  9. Greyborn

    Sep 17, 2020 15:32

    We are also seeing the editor hard lock - for us though we don't even need to build. We just load up the editor, run our game, quit the game and then quit the editor. Started happening after upgrading from 2018.4.23 to both 2018.4.26 and 2018.4.27

    Last lines of the log are:
    [Package Manager] Server::Kill -- Server was shutdown
    Cleanup mono

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.