Search Unity

Feedback Please inform your users when you are deleting anything with new installs

Discussion in 'Unity Hub' started by Exzerios, May 14, 2019.

  1. Exzerios

    Exzerios

    Joined:
    Jun 25, 2015
    Posts:
    8
    And thanks a lot for not informing, that updating to Hub 2.0 will clear the Hub folder completely.
    Mistakenly suggesting, that folder called "Hub" might be a good place to store everything, I've just lost my project, which, because of early prototyping stage, wasn't backed up.
     
    Abejka and reachout like this.
  2. AndersMalmgren

    AndersMalmgren

    Joined:
    Aug 31, 2014
    Posts:
    5,358
    If I did something that stupid I would not publicly talk about it. I dont even have my projects on the same disks as os / unity

    edit: Sorry for being blunt :p
     
    Last edited: May 14, 2019
  3. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,769
    @AndersMalmgren has the point.
    Should never store any documents / projects files, in software installation directories.
    Preferably separate disk location. Or at least partition.
    In worse case scenario, there is Documents folder in Windows OS, and relevant on other OS.
    Also should have backups, and / or at least revisions.

    At least good lesson to learn.
     
    mabulous and RecursiveFrog like this.
  4. AndersMalmgren

    AndersMalmgren

    Joined:
    Aug 31, 2014
    Posts:
    5,358
    Also its good to make it a habit to create git repos even for the smallest of POCs
     
  5. Exzerios

    Exzerios

    Joined:
    Jun 25, 2015
    Posts:
    8
    Yes, yes. I know it wasn't my brightest idea. But I found complete folder wiping during uninstalls/updates to be a very rare practice, especially for such type of software (and a bad practice, since because of rareness it becomes an unexpected behavior), so I didn't expect Unity to catch me here. And yes, I was just lazy to do it properly for a few tests because I'm going to switch my PC after new Ryzen release, switch to 2019.2 and (possibly) heavily updated version of HDRP and will have to set up everything again. And "Hub" as a name (and, well, the app idea itself) was just too attracting to use it as a root folder for everything related to Unity.
    Anyway such careless approach from Unity team is disappointing.
     
    Abejka likes this.
  6. sxa

    sxa

    Joined:
    Aug 8, 2014
    Posts:
    741
    All mainstream operating systems make a distinction between locations for software and locations for project data (eg Program Files vs Documents).

    A user creating problems for themselves by storing their project data in a location reserved for applications isnt carelessness on the part of the application developer.

    On Windows you cant even create a project in the Unity Hub folder without manually changing the folder permissions first.
     
  7. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,769
    I was thinking the same actually, how win OS didn't cause issues, trying to save project in Program Files folder?
    Just a rhetoric question ...

    Unless disabled all permissions in system, which is rather bad move, and akin for more troubles.
     
  8. AndersMalmgren

    AndersMalmgren

    Joined:
    Aug 31, 2014
    Posts:
    5,358
    If you are local admin and have turned off UAC, I think
     
    Antypodish likes this.
  9. Exzerios

    Exzerios

    Joined:
    Jun 25, 2015
    Posts:
    8
    Thats because both unity and hub aren't installed in "Program Files" folder. System disk is small ssd for OS only.
     
  10. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,769
    That explains :)
     
  11. sxa

    sxa

    Joined:
    Aug 8, 2014
    Posts:
    741
    So there was a conscious knowledge that these were being relocated from Program Files, somewhere which is not suitable for user data?
     
  12. Murgilod

    Murgilod

    Joined:
    Nov 12, 2013
    Posts:
    10,137
    It wasn't Unity who was careless here.
     
    JoNax97, elmar1028, xVergilx and 3 others like this.
  13. Well, you need to examine more software then, because actually wiping out the installed folder is the norm. Back in the Windows XP-days it wasn't, sadly, so a lot of program folders and files was lingering around for no good reason. Subsequent Windows versions (and other OSes in general) do a better job to eliminate clutter after uninstall.
    Never ever put anything you create in a folder someone else did. Not even OS's own.
     
  14. Exzerios

    Exzerios

    Joined:
    Jun 25, 2015
    Posts:
    8
    I assume that any unoccupied place on any disk and in any unassociated folder is suitable for any data I want to store. That's the point of having additional disks.

    Certainly I was. But since it's at least common for installers to remember exactly what files they install for further deinstallation without accidental deletion of user data and since AFAIK Hub didn't generate any additional files in the installation folder during runtime, I didn't see any reasons for them not to do it more secure way. Still don't see. And at least was expecting one of those "gosh how many times will you ask this" dialog windows with something like "This will delete everything, ya know. Sure?", not a silent update on restart.
     
  15. ShilohGames

    ShilohGames

    Joined:
    Mar 24, 2014
    Posts:
    3,020
    Tips:
    1) Don't store documents in the folders where programs get installed.
    2) Take frequent backups of your documents.
    3) Take an additional backup right before installing, upgrading, or removing anything.
    4) Never blame other people when you don't follow tips 1, 2, and 3.
     
    xVergilx, Wandersoul and Ryiah like this.
  16. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,141
    This. Program Files (/Application on macOS, /usr/bin on Linux) should only contain programs as there is no guarantee that an uninstaller won't indiscriminately remove every file in the folder associated with that program.

    All of this sounds completely reasonable until you take a step back and realize it's exactly like labels saying that the liquid in a steaming hot cup of coffee may burn you, not to iron the shirt while you're wearing it, or not to breathe while under water.

    CoffeIsHot.png

    ClothesIronWarningLabel.jpg

    DoNotBreatheUnderWater.jpg
     
    Last edited: May 14, 2019
  17. Kiwasi

    Kiwasi

    Joined:
    Dec 5, 2013
    Posts:
    16,860
    I did this the other day. A simple "Are you sure?" would be handy.
     
    angrypenguin and Ony like this.
  18. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,141
    Or preventing people from choosing the installation folder if they have the need to wipe the folder.
     
    angrypenguin and Kiwasi like this.
  19. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,619
    It could be worth checking if the contents of the folder are non-standard. Installers can know what they're adding/removing, so doing a simple checksum and popping up a message if it doesn't match what's expected could be handy. "Installation folder has been modified. All contents will be deleted if you continue. Do you wish to continue?"

    However... given that this is such a simple solution I'm suspect that there's a good reason that it's not already implemented in standard installer packages.
     
    Kiwasi likes this.
  20. TheGaul

    TheGaul

    Joined:
    Apr 15, 2019
    Posts:
    199
    @Exerios Your main mistake here, was thinking you'd get sympathy on the Unity forum. ;)
    A bit like getting your leg bit by a fox and then dangling your leg in the ocean hoping a shark will lick it better! :D
     
  21. For example the OS users' 99.9% cab convey such simple information that do not put your stuff in the programs' folders. :) And we're talking about actual users, not developers.

    As a software developer I like to hold other people who are or pretending to be developers to a higher standard and even the simple users, who don't know too much about computers can understand such simple rule that we don't put data in programs' folder.
    I'm really sorry that he lost his project, but he started this conversation with pointing fingers... Which is rude and shows he cannot take responsibility for his own actions.
     
  22. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,141
    I'm most sympathetic to people who have had an unfortunate accident outside of their control, and to people who have had one due to ignorance but are willing to move forward and overcome their ignorance. I'm far less sympathetic to people who have had an accident not due to misfortune or ignorance but due to laziness.

    The OP openly admits that they didn't backup their project. A compressed archive only requires a few clicks to create and move to a secure location. His attitude suggests he's angry that he lost his work, yet he shows that he didn't care enough about it to even create an archive. It's very hard to be sympathetic in this case.

    If you want a good example of someone I'm very sympathetic towards, below is another example this issue happening to someone, and the first response from them was to politely ask how to prevent this from happening again. I gave them a good polite response in return.

    https://forum.unity.com/threads/unity-hub-update-deleted-my-project.678370/
     
  23. sxa

    sxa

    Joined:
    Aug 8, 2014
    Posts:
    741
    I have complete sympathy for anyone losing their only copy of critical data (the first time*). Round here (ie students) its almost always naivety, or lack of experience. However sometimes its just laziness, and once in a blue moon its arrogance; someone who thought they know it all and wouldnt take advice.
    In my experience its almost always the latter who come out of the gate hurling blame at everyone else, and I dont actually feel any need to maintain sympathy for that kind of behaviour.

    (* As an aside : anyone suffering a catastrophic failure of their only copy of their data more than once needs to stop using computers forever.)
     
    RecursiveFrog likes this.
  24. AndersMalmgren

    AndersMalmgren

    Joined:
    Aug 31, 2014
    Posts:
    5,358
    What you meant to say is that a new repo is just a click away

    upload_2019-5-16_12-57-29.png
     
  25. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,619
    That's all well and good for people who already know how to use version control and have an account set up.

    I'm all for the version control bandwagon, but do keep in mind that people aren't born knowing this stuff, and that's ok.

    (Edited for brevity.)
     
  26. AndersMalmgren

    AndersMalmgren

    Joined:
    Aug 31, 2014
    Posts:
    5,358
    Yeah thats why i have said that Unity should warn if project is not under version control. A bit hard though, you do not want to hardcode to git by looking for .git folder etc.
     
  27. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,769
    VS warns, if that changes anything. Chances are, message is ignored by many. Same as would be in Unity.
     
  28. AndersMalmgren

    AndersMalmgren

    Joined:
    Aug 31, 2014
    Posts:
    5,358
    You cant build systems for the dumbest procent
     
  29. Abejka

    Abejka

    Joined:
    Mar 20, 2018
    Posts:
    1
    2022, Unity Hub 3 - Same issue! Wtf, excuse me?
     
  30. Yes, in 2022 too you should use version control, backup and not putting your data in folders someone else made. You're excused.
     
  31. Murgilod

    Murgilod

    Joined:
    Nov 12, 2013
    Posts:
    10,137
    Why would you put your projects in the Hub folder in the first place? It very specifically does not use it as the default project directory for a reason. The Hub folder is for Hub.
     
    stain2319 likes this.
  32. Moonjump

    Moonjump

    Joined:
    Apr 15, 2010
    Posts:
    2,572
    I agree with all this. But will add that software should not update without warning. The update to Hub 3.0 happened to me without warning. I did not initiate it in any way. This happened on two separate macOS installs. I did not lose anything, but it first happened on a day I was trying to get a build out and it delayed me (new bug, was it due to the software change?). Software should not be updated near a deadline. That it was done without my control still has me annoyed.
     
    angrypenguin likes this.
  33. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,141
    This is an old thread but I feel the need to point out that just because it's rare doesn't mean it's a bad practice. In fact this is the way uninstallers are intended to be made. If you want to include an option that lets the user decide to leave some files (eg config files) behind that's one thing but uninstallers should by default remove everything.