Can't open Lutris

Pushing that message from terminal

Traceback (most recent call last):
  File "/usr/bin/lutris", line 52, in <module>
    from lutris.gui.application import Application  # pylint: disable=no-name-in-module
  File "/usr/lib/python3.10/site-packages/lutris/gui/application.py", line 36, in <module>
    from lutris.api import parse_installer_url, get_runners
  File "/usr/lib/python3.10/site-packages/lutris/api.py", line 11, in <module>
    import requests
  File "/home/ass/.local/lib/python3.10/site-packages/requests/__init__.py", line 43, in <module>
    import urllib3
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/__init__.py", line 8, in <module>
    from .connectionpool import (
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/connectionpool.py", line 29, in <module>
    from .connection import (
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/connection.py", line 39, in <module>
    from .util.ssl_ import (
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/util/__init__.py", line 3, in <module>
    from .connection import is_connection_dropped
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/util/connection.py", line 3, in <module>
    from .wait import wait_for_read
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/util/wait.py", line 1, in <module>
    from .selectors import (
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/util/selectors.py", line 14, in <module>
    from collections import namedtuple, Mapping
ImportError: cannot import name 'Mapping' from 'collections' (/usr/lib/python3.10/collections/__init__.py)

What I’m suppose to do? Thanx in advance.


Moderator edit: In the future, please use proper formatting: [HowTo] Post command output and file content as formatted text

Reset your python environment and don’t install custom packages with pip.

1 Like

Greetings! And thanx for a quick answer, but please tell me how to reset my python environment. Thank you.

I literally can’t find any info how to do it, how to reset my python environment…

This shows you have installed system packages, as local packages with PIP or manually, and now it uses you local Python packages to run Lutris, which fails.

Remove all your Python packages you installed manually. See if the system is now working as intended. You did it, so now undo it.

I did that:

pip uninstall -r requirements.txt -y
WARNING: Skipping aesedb as it is not installed.
WARNING: Skipping aiohttp as it is not installed.
WARNING: Skipping aioresponses as it is not installed.
WARNING: Skipping aiosignal as it is not installed.
WARNING: Skipping aiosmb as it is not installed.
WARNING: Skipping aiowinreg as it is not installed.
WARNING: Skipping ansible as it is not installed.
WARNING: Skipping ansible-core as it is not installed.
WARNING: Skipping ansible-runner as it is not installed.
WARNING: Skipping antlr4-python3-runtime as it is not installed.
Found existing installation: anytree 2.8.0
Uninstalling anytree-2.8.0:
Successfully uninstalled anytree-2.8.0
Found existing installation: apparmor 3.1.3
Uninstalling apparmor-3.1.3:
Successfully uninstalled apparmor-3.1.3
Found existing installation: appdirs 1.4.4
Uninstalling appdirs-1.4.4:
Successfully uninstalled appdirs-1.4.4
Found existing installation: application-utility 1.3.2
Uninstalling application-utility-1.3.2:
Successfully uninstalled application-utility-1.3.2
WARNING: Skipping asgiref as it is not installed.
WARNING: Skipping asn1crypto as it is not installed.
WARNING: Skipping asyauth as it is not installed.
WARNING: Skipping async-generator as it is not installed.
Found existing installation: async-timeout 4.0.2
Uninstalling async-timeout-4.0.2:
Successfully uninstalled async-timeout-4.0.2
WARNING: Skipping asysocks as it is not installed.
Found existing installation: attrs 22.2.0
Uninstalling attrs-22.2.0:
Successfully uninstalled attrs-22.2.0
Found existing installation: autocommand 2.2.2
Uninstalling autocommand-2.2.2:
Successfully uninstalled autocommand-2.2.2
WARNING: Skipping Automat as it is not installed.
WARNING: Skipping backoff as it is not installed.
WARNING: Skipping badsecrets as it is not installed.
WARNING: Skipping bbot as it is not installed.
Found existing installation: bcrypt 4.0.1
Uninstalling bcrypt-4.0.1:
Successfully uninstalled bcrypt-4.0.1
WARNING: Skipping beautifulsoup4 as it is not installed.
Found existing installation: btrfsutil 6.2.2
Uninstalling btrfsutil-6.2.2:
Successfully uninstalled btrfsutil-6.2.2
Found existing installation: build 0.10.0
Uninstalling build-0.10.0:
Successfully uninstalled build-0.10.0
Found existing installation: cachetools 5.3.0
Uninstalling cachetools-5.3.0:
Successfully uninstalled cachetools-5.3.0
Found existing installation: catfish 4.16.4
ERROR: Cannot uninstall ‘catfish’. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.

But when I’m trying to open lutris it is giving me a:

Traceback (most recent call last):
File “/usr/bin/lutris”, line 52, in
from lutris.gui.application import Application # pylint: disable=no-name-in-module
File “/usr/lib/python3.10/site-packages/lutris/gui/application.py”, line 36, in
from lutris.api import parse_installer_url, get_runners
File “/usr/lib/python3.10/site-packages/lutris/api.py”, line 11, in
import requests
File “/home/ass/.local/lib/python3.10/site-packages/requests/**init**.py”, line 43, in
import urllib3
File “/home/ass/.local/lib/python3.10/site-packages/urllib3/**init**.py”, line 8, in
from .connectionpool import (
File “/home/ass/.local/lib/python3.10/site-packages/urllib3/connectionpool.py”, line 29, in
from .connection import (
File “/home/ass/.local/lib/python3.10/site-packages/urllib3/connection.py”, line 39, in
from .util.ssl_ import (
File “/home/ass/.local/lib/python3.10/site-packages/urllib3/util/**init**.py”, line 3, in
from .connection import is_connection_dropped
File “/home/ass/.local/lib/python3.10/site-packages/urllib3/util/connection.py”, line 3, in
from .wait import wait_for_read
File “/home/ass/.local/lib/python3.10/site-packages/urllib3/util/wait.py”, line 1, in
from .selectors import (
File “/home/ass/.local/lib/python3.10/site-packages/urllib3/util/selectors.py”, line 14, in
from collections import namedtuple, Mapping
ImportError: cannot import name ‘Mapping’ from ‘collections’ (/usr/lib/python3.10/collections/**init**.py)

Also I was trying to do that:

pip freeze | xargs pip uninstall -y

Trying to open Lutris again and have this:

Traceback (most recent call last):
  File "/usr/bin/lutris", line 52, in <module>
    from lutris.gui.application import Application  # pylint: disable=no-name-in-module
  File "/usr/lib/python3.10/site-packages/lutris/gui/application.py", line 36, in <module>
    from lutris.api import parse_installer_url, get_runners
  File "/usr/lib/python3.10/site-packages/lutris/api.py", line 11, in <module>
    import requests
  File "/home/ass/.local/lib/python3.10/site-packages/requests/__init__.py", line 43, in <module>
    import urllib3
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/__init__.py", line 8, in <module>
    from .connectionpool import (
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/connectionpool.py", line 29, in <module>
    from .connection import (
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/connection.py", line 39, in <module>
    from .util.ssl_ import (
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/util/__init__.py", line 3, in <module>
    from .connection import is_connection_dropped
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/util/connection.py", line 3, in <module>
    from .wait import wait_for_read
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/util/wait.py", line 1, in <module>
    from .selectors import (
  File "/home/ass/.local/lib/python3.10/site-packages/urllib3/util/selectors.py", line 14, in <module>
    from collections import namedtuple, Mapping
ImportError: cannot import name 'Mapping' from 'collections' (/usr/lib/python3.10/collections/__init__.py)

Moderator edit: In the future, please use proper formatting: [HowTo] Post command output and file content as formatted text

Still the same exact situation. Local Python packages overriding the system packages apparently.

Please help me, what I’m suppose to do? Can you connect to my machine through the Anydesk and help me?

You have packages here apparently, I guess clean this folder, but I can’t recommend you how to undo what you did because I don’t know what you did.

It is starts! Thanks alot bud!

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.