Search Unity

Unity's version control component has been upgraded to Plastic SCM.

Object references are lost after push, but survive after 2nd push

Discussion in 'Unity Collaborate' started by Jobahed, Feb 1, 2018.

  1. Jobahed

    Jobahed

    Joined:
    Feb 24, 2014
    Posts:
    19
    I will submit a bug on this unless someone tells me this is a known issue. For us it is very reproducible.

    I drag a link (prefab or object in the scene) to one of my script GameObject references in the Inspector. I save the scene and push up. My partner pulls down, and all my scene changes are there, but the object reference is "None".

    BUT...if I do all that then push, then make some minor irrelevant scene change, push AGAIN, then the reference is there.

    This is repeatable 100% of the time for us.

    We're on 2017.2.0f3 at the moment.

    Any information about this issue would be greatly appreciated.

    -John Nagle
    Gyoza Games
     
  2. Ryan-Unity

    Ryan-Unity

    Joined:
    Mar 23, 2016
    Posts:
    1,993
    Hi John! Thank you for bringing this to our attention! I haven't had any luck in reproducing this bug on my end but if you could submit a bug with a sample project that reproduces the issue then that would be extremely helpful! Please let me know what your bug number is so that we can start taking a look at it.
     
  3. Jobahed

    Jobahed

    Joined:
    Feb 24, 2014
    Posts:
    19
    Will do that now. Thanks Ryan!

    -John
     
  4. Jobahed

    Jobahed

    Joined:
    Feb 24, 2014
    Posts:
    19
    Ryan, it's case 996118.

    If you email me, I am happy to give you access to our repo so you can maybe diff the 2 pushes.
     
    Ryan-Unity likes this.
  5. Ryan-Unity

    Ryan-Unity

    Joined:
    Mar 23, 2016
    Posts:
    1,993
    Thank you for submitting a bug report.

    Actually, with your permission, we could clone your repo and its history so that we can use it for testing. That way we wouldn't require direct access to your project. Would that be alright?
     
  6. Jobahed

    Jobahed

    Joined:
    Feb 24, 2014
    Posts:
    19
    Absolutely. Email me so I can give you the specific project name.
     
  7. Ryan-Unity

    Ryan-Unity

    Joined:
    Mar 23, 2016
    Posts:
    1,993
    That's great, though your project name won't be necessary. All we really need is your project's ID which is included in the Editor.log that was attached to your bug report.

    As a side note, I was unable to DM you here. Do you maybe have restrictions on who can send you direct messages? It's completely fine if you do. I just wanted to let you know.
     
  8. Jobahed

    Jobahed

    Joined:
    Feb 24, 2014
    Posts:
    19
    I am at a customer site right now which is probably firewalled, not sure. You can always email me at jnagle at gyozagames.com.
     
  9. Ryan-Unity

    Ryan-Unity

    Joined:
    Mar 23, 2016
    Posts:
    1,993
    We've actually managed to repro the issue on our end. One likely scenario for this bug seems to come up when someone modifies an existing script (like adding new variables) and assigning a value to the new variable before someone does an Update. If you download the Update and reload the scene then you'll see the new fields but they'll have default values (like None or 0). You need to reload the scene again for the right values to be displayed, which you can do by opening another scene and then re-opening the old scene. But if you make other changes to the scene and save before reloading again then those correct values will get overwritten by the default ones.

    Needless to say we'll be working to fix this bug right away. Thank you for bringing it to our attention. I hope that the above workaround helps you in the meantime.
     
  10. Jobahed

    Jobahed

    Joined:
    Feb 24, 2014
    Posts:
    19
    Excellent, I'm glad that you found it....I was surprised more people hadn't run into this. Will use the workaround and looking forward to the fix!

    -John
     
    Ryan-Unity likes this.
  11. Jobahed

    Jobahed

    Joined:
    Feb 24, 2014
    Posts:
    19
    Hi Ryan, has there been any updates on this? I notice the bug is still listed as open. This one has potentially devastating implications to teams, so I thought it would have been addressed by now.
     
  12. HaakonL

    HaakonL

    Joined:
    Mar 13, 2014
    Posts:
    123
    We have had this bug in all 2017 versions, in 5.6 and it's still here in 2018. I don't think you should expect Unity to ever fix it. It's more than a year since we first reported it. Unity probably doesn't understand or simply don't care about the consequences it has for teams using Collab.
     
  13. Ryan-Unity

    Ryan-Unity

    Joined:
    Mar 23, 2016
    Posts:
    1,993
    Hi @Jobahed! Sorry the lack of updates on this bug. We have a fix on the way for this issue and it's making its way through release management now. We're aiming to get the fix into 2018.1's final release. I'll update here if that changes. Sorry again for the delay.