Search Unity

disabling "Auto-Refresh" in settings does seem to have no effect

Discussion in 'Unity Version Control' started by MassimoFrancesco, Aug 2, 2022.

  1. MassimoFrancesco

    MassimoFrancesco

    Joined:
    Jul 6, 2019
    Posts:
    44
    Hi guys,

    I think I have issues with Plastic SCM plugin constantly triggering Unity functions on file path management, when editing prefabs in prefab mode.
    E.g. as:
    - AssetPostProcessor.OnPostprocessAllAssets
    - ProjectBrowser.OnGUI.repaint
    - Editor.ApplicationUpdate

    Which causes the editor to get stuck for 2-3 seconds. Each time I change anything on the prefab (enabling/disabling a gameObject/component, editing a value, etc.).
    Obviously this is no fun at all to work with, actually making it nearly impossible to work in a productive manner.

    So I tried disabling "Auto-Refresh" and also disabling "Find changed files in workspace", but SCM is still updating every time I do changes in prefab mode, showing the little loading bar "finding changes in workspace...", while simultaneously calling the above mentioned functions (at least I suspect SCM of doing this).

    So burning question for now is, how can you actually disable SCM from automatically detecting and looking for changes, to avoid editor hang-ups in prefab-mode?

    I updated from 1.15.x(something) to 1.17.2.
    But the issue persists. Even though interestingly, the Unity Editor calls changed. Before on 1.15, I only saw the AssetPostProcessor.OnPostprocessAllAssets call, while now with 1.17.2, I don't anymore. Instead the Editor.ApplicationUpdate and ProjectBrowser.OnGUI.repaint call appears on screen with sometimes 1-2 other ones afterwards, which are too fast to screencap unfortunately.

    I hope you guys have some idea, because the only one I've got left for now is to remove the Version Control package in Unity completely, effectively removing SCM in Unity. And try to do it with the SCM desktop app version only.

    Edit: I'm using Unity Editor 2020.3.33f1 right now.
     
    Last edited: Aug 3, 2022
  2. oscarAbraham

    oscarAbraham

    Joined:
    Jan 7, 2013
    Posts:
    431
    Have you tried disabling the auto save checkbox that appears on the scene while on prefab mode?
     
    oAzuehT and MassimoFrancesco like this.
  3. MassimoFrancesco

    MassimoFrancesco

    Joined:
    Jul 6, 2019
    Posts:
    44
    Thanks a lot, this solves my issue for now.
    Didn't spot this checkbox yet.
    Still weird that this behaviour exists, while I had never issues before switching to Plastic. But I can work with this way now.
     
  4. MassimoFrancesco

    MassimoFrancesco

    Joined:
    Jul 6, 2019
    Posts:
    44
    I actually removed the Plastic SCM plugin in Unity for now, to hopefully solve another very severe issue with not being able to get two client machines properly synced to the same project state.

    However I noticed that the issue with those constantly triggering calls mentioned above, immediately went away.
    So it's safe to say that the Plastic plugin caused this.
    I even got the "Auto Save" in prefab-mode on again, and the Editor is not getting stuck in those 2-3 second long calls anymore.
     
  5. carlosalba1985

    carlosalba1985

    Unity Technologies

    Joined:
    Jul 19, 2021
    Posts:
    1,081
    What is your Version Control plugin version? We fixed some other issues with syncing prefabs and I want to be sure you are properly updated.

    After disabling the "auto save checkbox", can you let us know the details of the issue you are still facing?

    Regards,
    Carlos.
     
  6. MassimoFrancesco

    MassimoFrancesco

    Joined:
    Jul 6, 2019
    Posts:
    44
    Hey Carlos, thanks for checking in on this topic.

    Actually I had updated both clients to Version Control 1.17.2, after having those "waiting time issues" in prefab mode.

    When I had the "auto save" checkbox disabled in prefab mode, this issue disappeared.
    Still I got the loading bars once when exiting and saving prefab mode (not an issue for me personally). But not each time anymore, I did a small change on the prefab.

    I assume Plastic gets triggered to do something, when anything in the repository changes (e.g. prefab-mode auto-saving to disk each time I do a small change). And this action caused those Unity editor calls I mentioned above to run. Which in turn locked the editor for 2-3 seconds for me each time.
     
  7. carlosalba1985

    carlosalba1985

    Unity Technologies

    Joined:
    Jul 19, 2021
    Posts:
    1,081
    Hi,

    I've been reviewing this report.

    If you modify an asset in the unity editor, the pending changes view always is updated because it is a controlled operation for plastic

    If you modify an asset externally (e.g from the explorer), the pending changes view only is updated when you have enabled the auto-refresh option.

    Please let us know if this is the same behavior you are experiencing.

    Regards,
    Carlos.
     
  8. navratilvictori

    navratilvictori

    Joined:
    Feb 21, 2021
    Posts:
    4
    I am posting this comment in case someone is looking for a solution.
    I am using Unity 2022.2 and Unity 2021.3 (LTS) at the time of writing this comment.
    Auto refresh was off but I've seen that 2 different projects had different versions of Burst. And in both cases Burst had the "chain link" icon (installed as a dependency)

    The solution in my case was:
    I reinstalled Burst by name (Packager Manager -> "+" sign -> "Add packager by name.. -> added "com.unity.burst"). Installed version is 1.8.4.
    This seems to have solved it. Some settings might have been reinitialized.