Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct here to familiarize yourself with the rules and how to post constructively.

  2. Unity 2022.1 is now available as the latest Tech release.
    Dismiss Notice

warning : [Conditional("ENABLE_UNITY_COLLECTIONS_CHECKS")] guard after pc build

Discussion in 'Unity Transport' started by ElegantUniverse, Aug 28, 2021.

  1. ElegantUniverse

    ElegantUniverse

    Joined:
    Sep 13, 2018
    Posts:
    71
    hello
    when I build for Pc, I encounter with this warning :

    An exception was thrown from a function without the correct [Conditional("ENABLE_UNITY_COLLECTIONS_CHECKS")] guard. Exceptions only work in the editor and so should be only thrown in a function protected by this guard

    I checked this link and this link as I found out there is a problem with writing data I added the mentioned attribute and it didn't solve.
    I would be appreciate if anyone could help.
     
  2. ElegantUniverse

    ElegantUniverse

    Joined:
    Sep 13, 2018
    Posts:
    71
    [Solved]

    For guys who may have this problem. go to the edit/project settings/Burst AOT settings/uncheck burst compilation and uncheck Enable optimisations
     

    Attached Files:

    Last edited: Aug 29, 2021
unityunity