7

My installation of Anaconda has gone sideways for some reason. I noticed it when I tried to open Jupyter. The start menu shortcut was broken. When I clicked on it, I got the infamous opening and closing of a command line window. I can start it by clicking on the executable but this winds up with the notebook opening in a weird location that I can't move out of.

When I try to uninstall and reinstall, I get the same behavior as before. I did some googling and found some Stackoverflow questions like this (which I've since lost so can't post the link), but when I followed the solutions offered, I just get more of the same. I thought there might be something that needed to be blown away from appdata but that didn't seem to fix the issue either.

Bob Wakefield
  • 3,739
  • 4
  • 20
  • 30
  • 1
    What makes you think you failed to completely uninstall it? It seems to me, unless you have some specific evidence to the contrary, that there's some other issue that needs to be resolved on your machine that isn't going to be fixed by simply reinstalling the software. – Silvio Mayolo Jan 13 '18 at 03:18
  • Check your environment variables and filetype/program associations. You can also try creating a shortcut for the executable, then right-click the shortcut and select "properties" it then alter the "start in" property to the directory you want it to start in. – sytech Jan 13 '18 at 03:18
  • Have you tried everything from [this](https://stackoverflow.com/questions/29337928/how-to-remove-anaconda-from-windows-completely) answer? – user3483203 Jan 13 '18 at 03:19
  • [Uninstalling conda on Windows](https://conda.io/docs/user-guide/install/windows.html#uninstalling-conda). – srikavineehari Jan 13 '18 at 04:19
  • Because when I uninstall and reinstall, there are several settings that I can tell didn't change whatsoever. But I'll try your workaround. – Bob Wakefield Jan 13 '18 at 05:16
  • Hmmm %USERPROFILE% appears to be missing... – Bob Wakefield Jan 13 '18 at 05:23
  • It looks like there was a Windows Update that removed an environment variable that Anaconda depended on. I'm going to install it on a machine that has never had it before and see what that looks like. – Bob Wakefield Jan 13 '18 at 05:39
  • `%USERPROFILE%` missing is pretty stunning. That should pretty much always be present by default. Maybe a virtual environment gone terribly wrong? – sytech Jan 13 '18 at 05:44
  • I might be looking in the wrong place. I assumed it's an environment variable. I installed on a machine that didn't have it and it's the same set up. The target for the shortcut points to a bunch of scripts but at the end it uses %USERPROFILE% but when I go look in environment variables, there is no such variable. – Bob Wakefield Jan 13 '18 at 07:45
  • cwp.py doesn't appear to be where it's supposed to be. – Bob Wakefield Jan 13 '18 at 07:54
  • Actually there is absolutely nothing in C:\Users\Bob\Anaconda3. No wonder the shortcut isn't working. – Bob Wakefield Jan 13 '18 at 07:56
  • To answer the question "what makes you think it failed to completely uninstall?" after an uninstall, the short cuts still exist. Obviously there are some things that aren't getting wiped out. – Bob Wakefield Jan 13 '18 at 08:16

2 Answers2

10

I'm running Windows 10 Pro Version 1703 OS Build 15063.786. I'm not sure if a Windows update is what caused the issue. Ultimately, all the shortcuts were pointing to things that no longer existed. I performed the following task.

  1. Uninstall Anaconda using the standard Windows uninstall process.
  2. Reboot.
  3. Scour the ENTIRE hard drive looking for anything remotely related to the Anaconda installation and manually delete it. I don't remember all the exact folders but I do remember specifically in C:\Users\Bob, there was a .Anaconda and a .IPython and a .Jupyter file. All those had to go. C:\Users\Bob\Anaconda3 also had to be manually deleted along with some files that were just hanging out in C:\ProgramData\Anaconda3 that somehow refused to be deleted.
  4. Manually delete the shortcuts in C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Anaconda3 (64-bit).
  5. Reboot.
  6. Reinstall Anaconda.
  7. Reboot.

Everything is back to normal. Special thanks to sytech. Checking the environment variables didn't provide a solution but it put me on the right investigative track.

Bob Wakefield
  • 3,739
  • 4
  • 20
  • 30
4

I think this is the official solution: https://docs.anaconda.com/anaconda/install/uninstall/

[Unfortunately I did the simple remove (Uninstall-Anaconda.exe in C:\Users\username\Anaconda3 following the answers in stack overflow) before I found the official article, so I have to get rid of everything manually.]

But for the rest of you the official full removal could be interesting, so I copied it here:

To uninstall Anaconda, you can do a simple remove of the program. This will leave a few files behind, which for most users is just fine. See Option A.

If you also want to remove all traces of the configuration files and directories from Anaconda and its programs, you can download and use the Anaconda-Clean program first, then do a simple remove. See Option B.

  1. Option A. Use simple remove to uninstall Anaconda:

    • Windows–In the Control Panel, choose Add or Remove Programs or Uninstall a program, and then select Python 3.6 (Anaconda) or your version of Python.
    • [... also solutions for Mac and Linux are provided here: https://docs.anaconda.com/anaconda/install/uninstall/ ]
  2. Option B: Full uninstall using Anaconda-Clean and simple remove.

    NOTE: Anaconda-Clean must be run before simple remove.

    • Install the Anaconda-Clean package from Anaconda Prompt (Terminal on Linux or macOS):

      conda install anaconda-clean
      
    • In the same window, run one of these commands:

      • Remove all Anaconda-related files and directories with a confirmation prompt before deleting each one:

        anaconda-clean
        
      • Or, remove all Anaconda-related files and directories without being prompted to delete each one:

        anaconda-clean --yes
        

      Anaconda-Clean creates a backup of all files and directories that might be removed in a folder named .anaconda_backup in your home directory. Also note that Anaconda-Clean leaves your data files in the AnacondaProjects directory untouched.

    • After using Anaconda-Clean, follow the instructions above in Option A to uninstall Anaconda.

Jakob
  • 1,063
  • 9
  • 17