Python Forum
Eliminating error in Python update-alternatives
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Eliminating error in Python update-alternatives
#1
I made an error when typing this code:

 sudo update-alternatives --install /usr/bin/python3 python /usr/bin/python2.7 1
Obviously, I do not want to that. It create issues like this:

Output:
root@LAPTOP-8R8F1BRA:/home/james# python -V Python 2.7.17 root@LAPTOP-8R8F1BRA:/home/james# python3 -V Python 2.7.17
I clearly do not want my default python to be python 2.7.17, nor do I want python3 to be python 2.7.17.

So my question is how do I correct or eliminate this error?

I have tried some things, but none of them seem to work.

Respectfully,

LZ
Reply
#2
delete current version of python,
then reinstall following this tutorial (update version to what you want, current is 3.9.2)
[Part-1]Linux Python 3 environment
[Part-2]Python environment Windows

A better solution is to use pyenv, see:

pyenv Simple Python Version Management
Reply
#3
I should have said that this Ubuntu is running as an app in Windows 10. The error was made in the Ubuntu app in Windows 10. I downloaded Ubuntu 18.04 from the MS store. I already have an environment of some sort in python then. But, I agree it is best to start over.

So how do I uninstall Ubuntu from Windows 10? It is being treated as a Windows 10 app. So do I just uninstall it as I would any app?

Is that the way to do it?

Respectfully,

LZ
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Error 1064 (42000) when executing UPDATE SQL gratiszzzz 7 1,365 May-22-2023, 02:38 PM
Last Post: buran
  Is it possible to update a CSS file from Python bigAL_python 4 2,194 Apr-20-2022, 01:38 PM
Last Post: bigAL_python
  SSL error while trying to update conda ilango 0 2,121 Nov-04-2021, 08:38 AM
Last Post: ilango
  Selecting rows that contain certain values using two alternatives tgottsc1 1 1,547 Jan-24-2021, 08:34 PM
Last Post: nealc
  eliminating letters when typed in python window deebo 0 1,706 Jan-05-2021, 09:26 AM
Last Post: deebo
Question Python + Google Sheet | Best way to update specific cells in a single Update()? Vokofe 1 2,625 Dec-16-2020, 05:26 AM
Last Post: Vokofe
  Making lists using itertools and eliminating duplicates. mike3891 2 2,189 Oct-26-2020, 05:39 PM
Last Post: bowlofred
  Update Python Files Harshil 3 2,227 Aug-28-2020, 10:52 AM
Last Post: Harshil
  Are there any python alternatives for LuaMacros? NathanStanley 1 3,741 Apr-07-2020, 09:51 AM
Last Post: Larz60+
  Python 3.6 Alternatives to Cx_Freeze KipCarter 5 4,953 Jan-14-2020, 11:51 AM
Last Post: KipCarter

Forum Jump:

User Panel Messages

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