Search Unity

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

New Collaborate Features in Unity 5.6

Discussion in 'Unity Collaborate' started by unity-tuesday, Apr 6, 2017.

  1. unity-tuesday

    unity-tuesday

    Unity Technologies

    Joined:
    Aug 2, 2016
    Posts:
    42
    Here is a short summary of the new features shipping with Unity 5.6! Please continue to share your feedback with us on these and other features.

    Partial Publish

    Many have requested the ability to publish certain assets instead of publishing everything at once when some things may not be ready.

    The partial commit feature allows you to right-click on a new or modified asset, set of assets, or a folder, then open the "Collaborate" menu. Within the menu, you can then select the "Publish" item. This will generate a pop-up window that will allow you to add commit comments, see a list of selected assets, and then choose to publish them.

    Ignore Files

    This feature allows the exclusion of files and directories from Collaborate using the ".collabignore" file which is generated in the root of the project directory. It contains the files and directories ignored by default in Collaborate.

    To add your own ignore rules to ".collabignore":
    • Check out GitIgnore; we use the same rules! (https://git-scm.com/docs/gitignore)
    • Modify ".collabignore" files with your new rules.
    • Start the Unity Editor (restart the Editor if it's already running.) Your new exclusions will now be tracked.
    • Publish your ".collabignore" changes in Collaborate to share your exclusions with the rest of your team.
    Here are a few items to note:
    • For local edits to the ".collabignore" file to take effect, the Editor needs to be restarted.
    • Excluding a file already tracking in Collaborate will not erase existing file history.
    • Certain files and directories can never be excluded in Collaborate, including the ".collabignore" file, the Assets directory (although specific files or directories within the Assets directory can be ignored), the ProjectSettings directory, any "*.asset" files inside the ProjectSettings directory, and "ProjectVersion.txt" within the ProjectSettings directory.
    Rollback

    Rolling back commits has been on many a wishlist, so here are the details!

    You can now roll back to a previous publish by opening up the Collaborate History window and clicking "Go back to..." on the change you want to revert to. Clicking "Go back to..." will replace all local project files with the files from the older version. These files will show up as "modified" in the Collab toolbar (Collab will show the "Publish" button), as would any new changes made to these files, and can therefore be pushed as a new revision for your project. This new behavior ensures that all versions are intact, even after a rollback, and can be accessed at any time in the development cycle.
     
  2. KarelA

    KarelA

    Joined:
    Dec 30, 2008
    Posts:
    422
    Hi.

    As a person who has never used git. Could you please please provide an example for a .collabignore file?
    Just saying "check out the rules from Git website" is not helping. I have never used git, i cannot even put these things into context. I would rather see a concrete syntax sample that i could put into unity .collabignore and use this to work out the folders that i need to exclude from my project.

    For example i have a project that has 80gb worth of textures. Located in Assets/3D/Textures I want to exclude that folder because i do not need to upload the 80gb to the cloud. How should the command look like in collabignore file?

    Also the explanation about collabignore file location is weak. I tried to search for that file and it was not there. Luckily i found this documentation https://docs.unity3d.com/Manual/UnityCollaborateIgnoreFiles.html that explained that this file is only generated after you have collaboration switched on.

    This brings me to the last and most frustrating part of the entire collab system. A system which has costed me many days of work before. Luckily today i backed my project up just before starting to play with 5.6 collaboration again. I knew that will probably mess something up and i did. The collab sync button is on top of the toolbar. Super easy to switch it on, and then.... nothing... everything is just locked up. No progress bar, nothing. The reason is probably because of the huge size of the project that it is automatically trying to sync trough the cloud. So here comes the most silly part, i can only access my project when i go offline. But when i am offline then my services window is not showing anything. This means i cannot switch off the collaboration from services window. I have to log on first, but doing so the pesky Unity will try to start automatically syncing again and my entire project locks up again. So there is absolutely nothing i can do.

    Now to think about it. It would have been better to just take the time and learn how to use Git properly and not rely on Unity built in "easy one click solution" for collaboration. It may work on smaller projects, but having a VR project with almost 100gb worth of data this collab is a disaster waiting to happen. Sad part is that there is absolutely no warning about this. You have to find it out the hard way.

    Good thing that i backed up. Now i just have to waste two hours to copy my old project back.
    Sorry for the ramble, quite frustrated at the moment.

    Would still like to have a simple collabignore sample on how to ignore a certain folder from the assets folder. I believe that my collab will stop freezing once i figure out how to exclude the textures folder.

    Please help,
    Thanks.
     
    Last edited: May 8, 2017
  3. Ryan-Unity

    Ryan-Unity

    Joined:
    Mar 23, 2016
    Posts:
    1,993
    Hi @KarelA!

    I'm sorry that you've run into issues using the Collab Ignore file. I'd be happy to help you get yourself on the right track!

    You actually already have a perfectly valid rule in your post! If you enter "Assets/Textures/3D" into your .collabignore file then that particular folder will no longer be handled by Collab. Anything else inside of your Assets/Textures folder will still be tracked for publishes and updates. But the 3D folder will be ignored.

    If you wanted to exclude a specific file, say a material called Blue, then you can enter "Assets/Blue.mat" in your .collabignore file to ignore it too. If you want to exclude every material in a certain folder, then you can use the * wildcard like so: "Assets/*.mat". And if you'd like to exclude a certain file no matter where it might be located then you can use the ** wildcard to have it not care about a specific path matching (ex. "Assets/**/blue.mat" will ignore blue.mat in Assets/x/y/blue.mat, Assets/blue.mat, Assets/z/blue.mat, etc.).

    I hope those examples help and let me know if you have anymore questions!
     
    unity-tuesday and KarelA like this.
  4. pKallv

    pKallv

    Joined:
    Mar 2, 2014
    Posts:
    1,191
    This feature is really good, thanks.
     
    Ryan-Unity likes this.
  5. KarelA

    KarelA

    Joined:
    Dec 30, 2008
    Posts:
    422
    Hi @ryanc-unity

    I added a screenshot of my collabignore file. Are the these lines looking correct? I need to ignore every tga and png file from my project. Without them the 80gb project will only be around 3gb.

    I not sure if the collabignore file works. It takes sooooo long get anything done. Waiting two hours for Unity unlock, then collabignore file is generated. Added lines to the file and started upload process. Waited another hour at "preparing to upload" spinning wheel. I noticed that it was gathering all 80gb worth of data to my temp/upload folder. When this was finished then the upload process finally started.

    Here is where i cannot tell if my collabignore file is working. Instead of uploading 80gb, progress bar shows me that it tries to upload 39gb. So it is not trying to upload everything (which makes me think that some files are getting ignored?), but it is still way too big. Not knowing what to do i left this running overnight. When i left from work it was about 10% done. By morning i was just greeted with "an error occurred " message and nothing else. I have no idea what to make it from. Now everything is locked up again :(

    Super frustrating. All i need to do is upload my project to cloud so my sound designer can start working on it. Since he does not see the visuals i can ignore all the textures and the project size will reduce 95%. This should be so simple but for the life of me i cannot get it to work.
    Usually i can figure stuff out by myself with trial and error but every small movement in collab is automatically rewarded with hours of waiting time. This means that trying couple of simple things has taken days out of my development time. And if something goes wrong then i have no idea why, am i doing something wrong or has some bug occurred. An error occurred message is not helpful either. Documentation at this state is also very shallow. "press this button and .... magic!"
    The collab talk at Unite was not helpful either since the use case was very simple project and may not relate to realistic use cases where collaboration is really needed.

    I apologize, i dont mean to undermine the teams work who are building the collab feature, i know that this is a super hard feature to handle. What frustrates me is the way Unity sells this collaboration idea. A magical unicorn where it just works with a click of a button. I know this is a feature is in BETA, but at the moment it seems to break too easily without giving you much information back.

    If you run into problem then there is absolutely no information for you to use to get yourself into context. No documentation, no error messages.
    This puts me in a silly situation where all i can do is just sit here and whine that my collab does not work. And i don't know why it does not work. Maybe my ignore file syntax is wrong, of maybe i am just running into an edge case bug. I have no way to know and trying to figure this out by trial and error has taken me almost a week of my development time. Mostly this consist of me pressing a button and then waiting for something to happen.


    EDIT: i have some new information. I tried to upload again. Now the remaining file size was 31gb. After uploading 10gb i got an error with connection timeout.
    UnityConnectUserInfoRequest: Timed out while fetching user - please check your network connection
    UnityConnectOrganizationRequest: Timed out while fetching orgs - please check your network connection

    Also while the collab upload process is going on my connection with internet goes worse and worse when time goes on. Few hours later dropbox and steam are giving me an offline notification.
    But this time i can see some of the files on the collaboration portal that is on Unity website. Sadly i can see that all my tga files are also uploaded. This means that have done something wrong with my collabignore file and it just tries to upload the entire project.
    Please take a look at my attached screenshot.

    Thanks
     

    Attached Files:

    Last edited: May 18, 2017
  6. Ryan-Unity

    Ryan-Unity

    Joined:
    Mar 23, 2016
    Posts:
    1,993
    Hi @KarelA!

    I believe the ignore commands you're looking for are the following:
    Assets/**/*.tga
    Assets/**/*.png

    Please don't ignore the .meta files. Collab (and all source control options) require those to track changes properly.

    I apologize that the process is taking so long for you but this is to be expected when working with so many gigs of assets. Collab does take up most of the available bandwidth when uploading assets in order to complete it as quickly as possible so it's understandable that Steam and Dropbox would exhibit offline notifications after several minutes have passed. When an upload takes longer than 10 minutes, the upload will timeout but you can resume the upload from where it left off. And those request errors aren't anything to worry about if you're only seeing one of each. We immediately try to request that info again if they fail.

    We are working on improving our documentation, both in help docs and in the Editor, which should make it easier to determine what action to take when something goes wrong.