Python Forum
Trying to get a coherent python installation
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Trying to get a coherent python installation
#1
I'm finding it difficult to get a consistent/coherent python installation. I had originally installed a 3.6 version of python from python.org (Windows 10 laptop). This installed to (the default location) C:\Program Files\Python36. Some time later I upgraded my Visual Studio to VS 2019. As it turns out, this also installed its own version of python (3.7) to

C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python37_64\Lib\venv\scripts\nt
C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python37_64
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64

Not only did MS install three copies of python.exe, there are two more copies at

C:\Program Files (x86)\OpenOffice 4\program\python.exe
C:\Program Files (x86)\OpenOffice 4\program\python-core-2.7.6\bin\python.exe

Somewhat of a mess. It gets better.

While working with the C:\Program Files\Python36 version I had installed a few extra packages such as pymsgbox, win32com, etc. A couple of days ago I decided, to be consistent with the Visual Studio version (which I use for interactive debugging), I would upgrade the Python36 version to 3.7 as well so I downloaded that from Python.org and ran it. Naturally it upgraded the Visual Studio package and left the 3.6 version alone. Following that I uninstalled the 3.6 version (which didn't completely uninstall so I manually deleted the Python36 folder).

Now, of course, I had to manually add the VS 2019 version into my %PATH% and reinstall all the extra packages which no longer worked following the uninstall of Python36. Here's where it gets even more fun. Running any pip install, even from an admin shell, results in permission denied. So I did a "take ownership" of the Visual Studio folders and tried again. Here's the results:

D:\>pip install win32com
Collecting win32com
Could not find a version that satisfies the requirement win32com (from versions: )
No matching distribution found for win32com
You are using pip version 10.0.1, however version 19.1.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.

D:\>pip --version
pip 10.0.1 from C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\lib\site-packages\pip (python 3.7)

D:\>python -m pip install --upgrade pip
Requirement already up-to-date: pip in c:\program files (x86)\microsoft visual studio\shared\python37_64\lib\site-packages (19.1.1)

I mean, seriously? If I wanted this much grief configuring things I would have installed linux instead of Windows.

Can anyone tell me how to clear up this (rude word) mess? Python is a very nice language. I've been a software developer for over 40 years and I think it's pretty sweet (except for the "no backslash as the final character of a raw string" thing), but nothing should be this difficult to set up.
Reply
#2
I would start over, and follow https://python-forum.io/Thread-Part-1-Py...er-Windows
Reply
#3
It works better now. Fortunately I take an image of my system (C:) partition every morning so I dropped back to an image from before I tried to "fix" things. Rather than uninstall Python36 I just left it where it was and pointed the upgrade to the 36 folder. I can live with the name mismatch. Thanks for the link and the advice.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Python installation for old MacOS Yonix 1 488 Sep-21-2023, 03:32 PM
Last Post: menator01
  Installation of packages to newest Python version from previous one Andrzej_Andrzej 3 829 Jul-15-2023, 11:32 AM
Last Post: snippsat
  How to see the date of installation of python modules. newbieAuggie2019 4 1,574 Mar-31-2023, 12:40 PM
Last Post: newbieAuggie2019
  Getting "SSL client not supported by this Python installation" error prabirsarkar 0 951 Mar-13-2023, 05:01 PM
Last Post: prabirsarkar
  python installation/running inside singularity container erdemath 2 1,772 Sep-21-2022, 08:13 AM
Last Post: erdemath
Question Python V3.11 Installation Help Danno 2 1,093 Aug-11-2022, 02:30 AM
Last Post: Danno
  Portable installation of Python possible? pstein 2 3,076 Nov-15-2020, 12:14 PM
Last Post: snippsat
  python and openCV installation dejhost 16 10,817 Aug-04-2020, 02:23 AM
Last Post: snippsat
  No Scripts File present after python installation ag2207 5 4,883 Jul-30-2020, 11:11 AM
Last Post: buran
  Cannot find Python installation folder when I install Anaconda bsbsbsbs 1 2,219 Jul-14-2020, 03:14 PM
Last Post: dgrunwal

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020