0

Yesterday I have installed Python 3.10 and today I’ve tried to login and I have stuck in the login loop. I’ve tried every suggestion on Reddit and ask ubuntu, but nothing seems to work. I’m so demoralized.

Edit:

Also when i enter terminal I always need to provide PATH to basic commands like (ls, sudo, etc.) after rebooting.

I’ve tried to reinstall python i’ve tried to install software-center, i got this issue Error: Package software center has no installation candidate after upgrade to 22.04 After this, when i’ve rebooted and tried to login i got this:

[8.890130] ACPI BIOS Error (bug): Could 
not resolue synbol (_IZ.EIDI, 
AE_NOT_FOUND (20220331/psargs-330)

[8.890265] ACPI Error: Aborting nethod ' SB. IEM. _OSC due to previous error (AF_NOT _FOUND) (20220331/psparse 529)

login error

1 Answers1

1

Since Python3.10 is available for Ubuntu 22.04 from the default repositories, you do not need to download it.

Furthermore, the system default Python version is Python3.10 and using a downloaded version to replace the default will break the system because much of the system depends on the particular default version.

Therefore, you should:

  • Boot into recovery mode from your Grub menu
  • select the option to drop to a root shell
  • run the following command:
mount -o remount,rw /
  • navigate to your user's home directory:
cd /home/PurpleAnteater

where PurpleAnteater is the actual username of your Ubuntu user (replace this with the actual username).

  • Finally, edit your .profile file:
nano .profile

and delete the path to python from the export PATH= line OR it would probably be better just to delete this line altogether. This is most likely the last line of the file.

After the line is deleted, press CTRL+o to save the file and CTRL+x to exit nano.

Use the command:

reboot

to reboot and then you should be able to log in successfully.

mchid
  • 43,546
  • 8
  • 97
  • 150
  • If you want to install an alternative version of Python or Python3.10, you should not have the manually installed version in your PATH if the manually installed version is called by the same name, e.g., python3.10 If you need to call the manually installed version, either create an alias for it or call it using the full path to the alternative python3.10 command. This way, the system will still use the default version where needed but you can use your alternate version for personal use. – mchid Mar 21 '23 at 01:03
  • Also, it should be noted that we almost never need to download software for Ubuntu because almost everything is available through the default repositories using apt. If you want to search for available software packages, run the command apt-cache search followed by the package name. Example: apt-cache search python3.10 This will list all available and related packages. To install a package for example, just run something like sudo apt update and then sudo apt install python3.10. – mchid Mar 21 '23 at 01:07
  • To find out more information about a package like the version number, you can run this for example: apt-cache show python3.10 . Finally, to filter your results, you can pipe the results to grep like in this command to only display results that contain the word "python": apt-cache search python3.10 | grep -i python And the -i option here disables case sensitivity for your matches. – mchid Mar 21 '23 at 01:10
  • 1
    THANK YOU SO MUCH!! Just followed your steps and it worked (deleted entire row in .profile) – Iggy Kuperson Mar 21 '23 at 09:19