Search Issue Tracker

Fix In Review for 2022.2.X

Planned for 2021.3.X



Found in


Issue ID




Building Unity player via CI results in "System.IO.IOException: Sharing violation on path" error

Build Pipeline


To reproduce:
• Currently no reproduction steps are known

Result: errors in CI: IOException: Sharing violation on path

Known platforms to reproduce the issue: Android, WebGL

Reproduced in (versions reported by the users): 2021.2.0f1, 2021.2.8f1
Not reproduced in (versions reported by the users) : 2021.1.x

Relevant Unity Forum posts:

Comments (4)

  1. Fcccd831b1dad4a871d0413c31e332d6?d=mm


    May 20, 2022 02:18

    Perhaps another datapoint, we only see this issue when building Test Player builds (i.e. Standalone test player builds for running Unity tests).

  2. 52d05e7ada90d8270495d06d47339335?d=mm


    Apr 15, 2022 06:32

    We get this error when building on Mac via shell script invoked by Jenkins. Strangely the issue does not occur if I start the shell script manually. It seems to be somehow related to how the Jenkins client runs. It has the same user though (the same I am logged in when manually invoking the shell script)

  3. Dd3dfccc78f1e600296d9684df23370d?d=mm


    Apr 13, 2022 14:47

    Happens also in 2021.2.17f1

  4. Ff841d597b0ea2a95131de1f7e8f5b45?d=mm


    Mar 17, 2022 07:38

    How to reproduce the issue on Unity 2021.2.0 - 2021.2.15 versions:

    1. Create a new empty project
    2. Add a build player Editor script so it can be run by CI
    3. Add Google's External Dependency Manager (tested versions 1.2.167 and 1.2.168)
    4. Some assets needs to be added. Based on the testing some assets have to be in the resources folder and some outside that folder accessing files, otherwise builds work as expected
    a. An easy way to test is for example adding either SRDebugger or Easy Roads asset
    5. Try run either iOS build or Android build with IL2CPP backend triggered by a CI service

    Expected result:
    Build should be created successfully

    What happens:
    Error: Exception occurred inside BeeDriver: System.IO.IOException: Sharing violation on path

    With an exact same project. if you run a build either in the editor or run it from terminal with a same build command as the CI system does (commanding it even from your own work machine to a remote build machine) the build works as expected.

    With this error Unity 2021.2.x versions are basically unusable for us so this definitely needs fixing before going to LTS.

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.