Pycharm module not found even when installed (Linux)
I am using pycharm on manjaro.
My main.py file contains only 1 line:
```
import pygame
```
I have python 3.10 installed at path /usr/bin/python3.10
I have checked and pycharm is also using this as interpreter.
But the linter doesn't recognise the module as installed, even when I run it using pycharm it gives an error that module not found.
However, the pygame module definitely is installed as when I manually run python3.10 main.py, the file runs without any error.
Kindly help in fixing this.
Please sign in to leave a comment.
Hello,
Please take a screenshot of the **Settings | Project | Python interpreter** window and a screenshot of the Run configuration (right-click on the file in the editor or project structure, More Run/Debug | Modify Run configuration).
Also, please run the following code with PyCharm and with the system terminal and attach outputs to the thread:
Pycharm output:
```
/usr/bin/python3.10 /app/extra/plugins/python/helpers/pydev/pydevconsole.py --mode=client --host=127.0.0.1 --port=35627
import sys; print('Python %s on %s' % (sys.version, sys.platform))
sys.path.extend(['/home/pyrole/Programming/Python'])
PyDev console: starting.
Python 3.10.6 (main, Nov 10 2011, 15:00:00) [GCC 12.2.0] on linux
runfile('/home/pyrole/Programming/Python/touch.py', wdir='/home/pyrole/Programming/Python')
{'os.environ': {'ALSA_CONFIG_DIR': '/usr/share/alsa',
'ALSA_CONFIG_PATH': ['/usr/share/alsa/alsa-flatpak.conf'],
'ASYNCIO_REPL': 'True',
'AT_SPI_BUS_ADDRESS': 'unix:path=/run/flatpak/at-spi-bus',
'DBUS_SESSION_BUS_ADDRESS': 'unix:path=/run/flatpak/bus',
'DEBUGINFOD_URLS': 'https://debuginfod.archlinux.org ',
'DESKTOP_SESSION': 'gnome',
'DISPLAY': ':0',
'EDITOR': '/usr/bin/nano',
'FLATPAK_ID': 'com.jetbrains.PyCharm-Professional',
'FLATPAK_SANDBOX_DIR': '/home/pyrole/.var/app/com.jetbrains.PyCharm-Professional/sandbox',
'GDMSESSION': 'gnome',
'GDM_LANG': 'en_US.UTF-8',
'GIO_LAUNCHED_DESKTOP_FILE': '/var/lib/flatpak/exports/share/applications/com.jetbrains.PyCharm-Professional.desktop',
'GIO_LAUNCHED_DESKTOP_FILE_PID': '4117',
'GI_TYPELIB_PATH': ['/app/lib/girepository-1.0'],
'GJS_DEBUG_OUTPUT': 'stderr',
'GJS_DEBUG_TOPICS': 'JS ERROR;JS LOG',
'GNOME_SETUP_DISPLAY': ':1',
'GST_PLUGIN_SYSTEM_PATH': ['/app/lib/gstreamer-1.0',
'/usr/lib/extensions/gstreamer-1.0',
'/usr/lib/x86_64-linux-gnu/gstreamer-1.0'],
'HOME': '/home/pyrole',
'INVOCATION_ID': 'f48bb7f6c0344a5592bbe856ab27e2fc',
'IPYTHONENABLE': 'True',
'JOURNAL_STREAM': '8:28740',
'LANG': 'en_US.UTF-8',
'LC_ADDRESS': 'en_US.UTF-8',
'LC_IDENTIFICATION': 'en_US.UTF-8',
'LC_MEASUREMENT': 'en_US.UTF-8',
'LC_MONETARY': 'en_US.UTF-8',
'LC_NAME': 'en_US.UTF-8',
'LC_NUMERIC': 'en_US.UTF-8',
'LC_PAPER': 'en_US.UTF-8',
'LC_TELEPHONE': 'en_US.UTF-8',
'LC_TIME': 'en_US.UTF-8',
'LD_LIBRARY_PATH': [''],
'LOGNAME': 'pyrole',
'MAIL': '/var/spool/mail/pyrole',
'MANAGERPID': '1265',
'MOTD_SHOWN': 'pam',
'OLDPWD': '/home/pyrole',
'PATH': ['/app/bin', '/app/extensions/bin', '/usr/bin'],
'PULSE_CLIENTCONFIG': '/run/flatpak/pulse/config',
'PULSE_SERVER': 'unix:/run/flatpak/pulse/native',
'PWD': '/home/pyrole/Programming/Python',
'PYCHARM_DISPLAY_PORT': '63342',
'PYCHARM_HOSTED': '1',
'PYCHARM_JDK': '${FLATPAK_DEST}/pycharm/jre64/',
'PYCHARM_MATPLOTLIB_INDEX': '0',
'PYCHARM_MATPLOTLIB_INTERACTIVE': 'true',
'PYDEVD_LOAD_VALUES_ASYNC': 'True',
'PYTHONIOENCODING': 'UTF-8',
'PYTHONPATH': ['/app/extra/plugins/python/helpers/third_party/thriftpy',
'/app/extra/plugins/python/helpers/pydev',
'/home/pyrole/Programming/Python',
'/app/extra/plugins/python/helpers/pycharm_matplotlib_backend',
'/app/extra/plugins/python/helpers/pycharm_display'],
'PYTHONUNBUFFERED': '1',
'QT_AUTO_SCREEN_SCALE_FACTOR': '1',
'QT_IM_MODULE': 'ibus',
'SESSION_MANAGER': 'local/Aryan-Pavilion:@/tmp/.ICE-unix/1333,unix/Aryan-Pavilion:/tmp/.ICE-unix/1333',
'SHELL': '/bin/sh',
'SHLVL': '0',
'SSH_AUTH_SOCK': '/run/user/1000/keyring/ssh',
'SYSTEMD_EXEC_PID': '1353',
'USER': 'pyrole',
'USERNAME': 'pyrole',
'WAYLAND_DISPLAY': 'wayland-0',
'XAUTHORITY': '/run/flatpak/Xauthority',
'XDG_CACHE_HOME': '/home/pyrole/.var/app/com.jetbrains.PyCharm-Professional/cache',
'XDG_CONFIG_DIRS': '/app/etc/xdg:/etc/xdg',
'XDG_CONFIG_HOME': '/home/pyrole/.var/app/com.jetbrains.PyCharm-Professional/config',
'XDG_CURRENT_DESKTOP': 'GNOME',
'XDG_DATA_DIRS': '/app/share:/usr/share:/usr/share/runtime/share:/run/host/user-share:/run/host/share',
'XDG_DATA_HOME': '/home/pyrole/.var/app/com.jetbrains.PyCharm-Professional/data',
'XDG_MENU_PREFIX': 'gnome-',
'XDG_RUNTIME_DIR': '/run/user/1000',
'XDG_SESSION_CLASS': 'user',
'XDG_SESSION_DESKTOP': 'gnome',
'XDG_SESSION_TYPE': 'wayland',
'XDG_STATE_HOME': '/home/pyrole/.var/app/com.jetbrains.PyCharm-Professional/.local/state',
'XMODIFIERS': '@im=ibus',
'__EGL_EXTERNAL_PLATFORM_CONFIG_DIRS': '/etc/egl/egl_external_platform.d:/usr/lib/x86_64-linux-gnu/GL/egl/egl_external_platform.d:/usr/share/egl/egl_external_platform.d',
'container': 'flatpak'},
'pkg_resources.working_set': [CacheControl 0.12.11 (/app/lib/python3.10/site-packages),
SecretStorage 3.3.3 (/app/lib/python3.10/site-packages),
attrs 22.1.0 (/app/lib/python3.10/site-packages),
certifi 2022.9.24 (/app/lib/python3.10/site-packages),
cffi 1.15.1 (/app/lib/python3.10/site-packages),
charset-normalizer 2.1.1 (/app/lib/python3.10/site-packages),
cleo 2.0.1 (/app/lib/python3.10/site-packages),
crashtest 0.4.1 (/app/lib/python3.10/site-packages),
cryptography 37.0.4 (/app/lib/python3.10/site-packages),
distlib 0.3.6 (/app/lib/python3.10/site-packages),
dulwich 0.20.46 (/app/lib/python3.10/site-packages),
filelock 3.8.0 (/app/lib/python3.10/site-packages),
html5lib 1.1 (/app/lib/python3.10/site-packages),
idna 3.4 (/app/lib/python3.10/site-packages),
jaraco.classes 3.2.3 (/app/lib/python3.10/site-packages),
jeepney 0.8.0 (/app/lib/python3.10/site-packages),
jsonschema 4.16.0 (/app/lib/python3.10/site-packages),
keyring 23.9.3 (/app/lib/python3.10/site-packages),
lockfile 0.12.2 (/app/lib/python3.10/site-packages),
more-itertools 8.14.0 (/app/lib/python3.10/site-packages),
msgpack 1.0.4 (/app/lib/python3.10/site-packages),
packaging 22.0 (/app/lib/python3.10/site-packages),
pexpect 4.8.0 (/app/lib/python3.10/site-packages),
pipenv 2022.12.19 (/app/lib/python3.10/site-packages),
pkginfo 1.9.2 (/app/lib/python3.10/site-packages),
platformdirs 2.5.2 (/app/lib/python3.10/site-packages),
poetry 1.3.2 (/app/lib/python3.10/site-packages),
poetry-core 1.4.0 (/app/lib/python3.10/site-packages),
poetry-plugin-export 1.2.0 (/app/lib/python3.10/site-packages),
ptyprocess 0.7.0 (/app/lib/python3.10/site-packages),
pycparser 2.21 (/app/lib/python3.10/site-packages),
pyrsistent 0.18.1 (/app/lib/python3.10/site-packages),
rapidfuzz 2.13.7 (/app/lib/python3.10/site-packages),
requests 2.28.1 (/app/lib/python3.10/site-packages),
requests-toolbelt 0.9.1 (/app/lib/python3.10/site-packages),
shellingham 1.5.0 (/app/lib/python3.10/site-packages),
tomli 2.0.1 (/app/lib/python3.10/site-packages),
tomlkit 0.11.5 (/app/lib/python3.10/site-packages),
trove-classifiers 2022.12.22 (/app/lib/python3.10/site-packages),
urllib3 1.26.12 (/app/lib/python3.10/site-packages),
virtualenv 20.17.1 (/app/lib/python3.10/site-packages),
virtualenv-clone 0.5.7 (/app/lib/python3.10/site-packages),
webencodings 0.5.1 (/app/lib/python3.10/site-packages),
Cython 0.29.33 (/usr/lib/python3.10/site-packages),
Mako 1.2.4 (/usr/lib/python3.10/site-packages),
Markdown 3.4.1 (/usr/lib/python3.10/site-packages),
MarkupSafe 2.1.2 (/usr/lib/python3.10/site-packages),
Pygments 2.14.0 (/usr/lib/python3.10/site-packages),
meson 0.63.3 (/usr/lib/python3.10/site-packages),
pip 23.0.1 (/usr/lib/python3.10/site-packages),
setuptools 67.3.2 (/usr/lib/python3.10/site-packages),
six 1.16.0 (/usr/lib/python3.10/site-packages),
wheel 0.38.4 (/usr/lib/python3.10/site-packages)],
'sys.path': ['/home/pyrole/Programming/Python',
'/app/extra/plugins/python/helpers/pydev',
'/app/extra/plugins/python/helpers/third_party/thriftpy',
'/app/extra/plugins/python/helpers/pydev',
'/home/pyrole/Programming/Python',
'/app/extra/plugins/python/helpers/pycharm_display',
'/usr/lib/python310.zip',
'/usr/lib/python3.10',
'/usr/lib/python3.10/lib-dynload',
'/app/lib/python3.10/site-packages',
'/usr/lib/python3.10/site-packages',
'/app/extra/plugins/python/helpers/pycharm_matplotlib_backend',
'/home/pyrole/Programming/Python'],
'sys.prefix': '/usr',
'sys.version_info': sys.version_info(major=3, minor=10, micro=6, releaselevel='final', serial=0)}
```
Terminal:
```
{'os.environ': {'AUTOJUMP_ERROR_PATH': ['/home/pyrole/.local/share/autojump/errors.log'],
'AUTOJUMP_SOURCED': '1',
'COLORTERM': 'truecolor',
'CONDA_DEFAULT_ENV': 'base',
'CONDA_EXE': '/home/pyrole/anaconda3/bin/conda',
'CONDA_PREFIX': '/home/pyrole/anaconda3',
'CONDA_PROMPT_MODIFIER': '',
'CONDA_PYTHON_EXE': '/home/pyrole/anaconda3/bin/python',
'CONDA_SHLVL': '1',
'DBUS_SESSION_BUS_ADDRESS': 'unix:path=/run/user/1000/bus',
'DEBUGINFOD_URLS': 'https://debuginfod.archlinux.org ',
'DESKTOP_SESSION': 'gnome',
'DISPLAY': ':0',
'EDITOR': '/usr/bin/nano',
'GDMSESSION': 'gnome',
'GDM_LANG': 'en_US.UTF-8',
'GIO_LAUNCHED_DESKTOP_FILE_PID': '4943',
'GNOME_KEYRING_CONTROL': '/run/user/1000/keyring',
'GNOME_SETUP_DISPLAY': ':1',
'HOME': '/home/pyrole',
'INVOCATION_ID': '20f4de690e4e4969b245d21aef1f5b17',
'JOURNAL_STREAM': '8:22523',
'KITTY_INSTALLATION_DIR': '/usr/lib/kitty',
'KITTY_PID': '4943',
'KITTY_PUBLIC_KEY': '1:=3cN;;{>aF=JJn##0rHyQks`zQI*=KvTpI8E2ta{',
'KITTY_WINDOW_ID': '1',
'LANG': 'en_US.UTF-8',
'LC_ADDRESS': 'en_US.UTF-8',
'LC_IDENTIFICATION': 'en_US.UTF-8',
'LC_MEASUREMENT': 'en_US.UTF-8',
'LC_MONETARY': 'en_US.UTF-8',
'LC_NAME': 'en_US.UTF-8',
'LC_NUMERIC': 'en_US.UTF-8',
'LC_PAPER': 'en_US.UTF-8',
'LC_TELEPHONE': 'en_US.UTF-8',
'LC_TIME': 'en_US.UTF-8',
'LOGNAME': 'pyrole',
'MAIL': '/var/spool/mail/pyrole',
'MANAGERPID': '1265',
'MANPAGER': "sh -c 'col -bx | bat -l man -p'",
'MOTD_SHOWN': 'pam',
'NVM_BIN': '/home/pyrole/.nvm/versions/node/v19.4.0/bin',
'NVM_CD_FLAGS': '-q',
'NVM_DIR': '/home/pyrole/.nvm',
'NVM_INC': '/home/pyrole/.nvm/versions/node/v19.4.0/include/node',
'OLDPWD': '/home/pyrole/Programming',
'PATH': ['/home/pyrole/anaconda3/bin',
'/home/pyrole/anaconda3/condabin',
'/home/pyrole/.nvm/versions/node/v19.4.0/bin',
'/home/pyrole/.autojump/bin',
'/home/pyrole/.dotnet/tools',
'/home/pyrole/tools/node-v14.15.4-linux-x64/bin',
'/home/pyrole/.local/bin',
'/home/pyrole/.cargo/bin',
'/home/pyrole/bin',
'/home/pyrole/.local/bin',
'/usr/local/bin',
'/usr/bin',
'/var/lib/snapd/snap/bin',
'/usr/local/sbin',
'/var/lib/flatpak/exports/bin',
'/usr/lib/jvm/default/bin',
'/usr/bin/site_perl',
'/usr/bin/vendor_perl',
'/usr/bin/core_perl'],
'PWD': '/home/pyrole/Programming/Python',
'QT_AUTO_SCREEN_SCALE_FACTOR': '1',
'QT_IM_MODULE': 'ibus',
'SESSION_MANAGER': 'local/Aryan-Pavilion:@/tmp/.ICE-unix/1333,unix/Aryan-Pavilion:/tmp/.ICE-unix/1333',
'SHELL': '/bin/zsh',
'SHLVL': '1',
'SSH_AUTH_SOCK': '/run/user/1000/keyring/ssh',
'STARSHIP_SESSION_KEY': '2215120263807226',
'STARSHIP_SHELL': 'zsh',
'SYSTEMD_EXEC_PID': '1649',
'TERM': 'xterm-kitty',
'TERMINFO': '/usr/lib/kitty/terminfo',
'USER': 'pyrole',
'USERNAME': 'pyrole',
'WAYLAND_DISPLAY': 'wayland-0',
'XAUTHORITY': '/run/user/1000/.mutter-Xwaylandauth.4NZQ11',
'XDG_CURRENT_DESKTOP': 'GNOME',
'XDG_DATA_DIRS': '/home/pyrole/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/local/share/:/usr/share/:/var/lib/snapd/desktop',
'XDG_MENU_PREFIX': 'gnome-',
'XDG_RUNTIME_DIR': '/run/user/1000',
'XDG_SESSION_CLASS': 'user',
'XDG_SESSION_DESKTOP': 'gnome',
'XDG_SESSION_TYPE': 'wayland',
'XMODIFIERS': '@im=ibus',
'_': '/usr/bin/python3.10',
'_CE_CONDA': '',
'_CE_M': ''},
'pkg_resources.working_set': [astroid 2.12.13 (/home/pyrole/.local/lib/python3.10/site-packages),
autopep8 1.6.0 (/home/pyrole/.local/lib/python3.10/site-packages),
bs4 0.0.1 (/home/pyrole/.local/lib/python3.10/site-packages),
colorama 0.4.6 (/home/pyrole/.local/lib/python3.10/site-packages),
decorator 5.1.1 (/home/pyrole/.local/lib/python3.10/site-packages),
dill 0.3.6 (/home/pyrole/.local/lib/python3.10/site-packages),
docstring-to-markdown 0.11 (/home/pyrole/.local/lib/python3.10/site-packages),
flake8 5.0.4 (/home/pyrole/.local/lib/python3.10/site-packages),
isort 5.10.1 (/home/pyrole/.local/lib/python3.10/site-packages),
jedi 0.18.2 (/home/pyrole/.local/lib/python3.10/site-packages),
lazy-object-proxy 1.8.0 (/home/pyrole/.local/lib/python3.10/site-packages),
mccabe 0.7.0 (/home/pyrole/.local/lib/python3.10/site-packages),
mypy 0.991 (/home/pyrole/.local/lib/python3.10/site-packages),
mypy-extensions 0.4.3 (/home/pyrole/.local/lib/python3.10/site-packages),
neovim 0.3.1 (/home/pyrole/.local/lib/python3.10/site-packages),
parso 0.8.3 (/home/pyrole/.local/lib/python3.10/site-packages),
platformdirs 2.5.4 (/home/pyrole/.local/lib/python3.10/site-packages),
pluggy 1.0.0 (/home/pyrole/.local/lib/python3.10/site-packages),
pycodestyle 2.9.1 (/home/pyrole/.local/lib/python3.10/site-packages),
pydocstyle 6.1.1 (/home/pyrole/.local/lib/python3.10/site-packages),
pyflakes 2.5.0 (/home/pyrole/.local/lib/python3.10/site-packages),
pygame 2.2.0 (/home/pyrole/.local/lib/python3.10/site-packages),
pylint 2.15.7 (/home/pyrole/.local/lib/python3.10/site-packages),
pyls-isort 0.2.2 (/home/pyrole/.local/lib/python3.10/site-packages),
pylsp-mypy 0.6.3 (/home/pyrole/.local/lib/python3.10/site-packages),
pyte 0.8.1 (/home/pyrole/.local/lib/python3.10/site-packages),
python-lsp-jsonrpc 1.0.0 (/home/pyrole/.local/lib/python3.10/site-packages),
python-lsp-server 1.6.0 (/home/pyrole/.local/lib/python3.10/site-packages),
pytoolconfig 1.2.2 (/home/pyrole/.local/lib/python3.10/site-packages),
rope 1.5.1 (/home/pyrole/.local/lib/python3.10/site-packages),
snowballstemmer 2.2.0 (/home/pyrole/.local/lib/python3.10/site-packages),
thefuck 3.32 (/home/pyrole/.local/lib/python3.10/site-packages),
toml 0.10.2 (/home/pyrole/.local/lib/python3.10/site-packages),
tomlkit 0.11.6 (/home/pyrole/.local/lib/python3.10/site-packages),
ujson 5.6.0 (/home/pyrole/.local/lib/python3.10/site-packages),
wcwidth 0.2.5 (/home/pyrole/.local/lib/python3.10/site-packages),
whatthepatch 1.0.3 (/home/pyrole/.local/lib/python3.10/site-packages),
wrapt 1.14.1 (/home/pyrole/.local/lib/python3.10/site-packages),
yapf 0.32.0 (/home/pyrole/.local/lib/python3.10/site-packages),
Cython 0.29.33 (/usr/lib/python3.10/site-packages),
GNOME-AppFolders-Manager 0.4.7 (/usr/lib/python3.10/site-packages),
Jinja2 3.1.2 (/usr/lib/python3.10/site-packages),
LibAppArmor 3.1.2 (/usr/lib/python3.10/site-packages),
MarkupSafe 2.1.2 (/usr/lib/python3.10/site-packages),
Pillow 9.4.0 (/usr/lib/python3.10/site-packages),
PyDrive2 1.15.0 (/usr/lib/python3.10/site-packages),
PyGObject 3.42.2 (/usr/lib/python3.10/site-packages),
PyNaCl 1.4.0 (/usr/lib/python3.10/site-packages),
PyQt5 5.15.9 (/usr/lib/python3.10/site-packages),
PyQt5-sip 12.11.1 (/usr/lib/python3.10/site-packages),
PySide6 6.4.2 (/usr/lib/python3.10/site-packages),
PyYAML 6.0 (/usr/lib/python3.10/site-packages),
Pygments 2.14.0 (/usr/lib/python3.10/site-packages),
Yapsy 1.12.2 (/usr/lib/python3.10/site-packages),
ansicolor 0.3.2 (/usr/lib/python3.10/site-packages),
anyascii 0.3.1 (/usr/lib/python3.10/site-packages),
apparmor 3.1.2 (/usr/lib/python3.10/site-packages),
appdirs 1.4.4 (/usr/lib/python3.10/site-packages),
application-utility 1.3.2 (/usr/lib/python3.10/site-packages),
attrs 22.2.0 (/usr/lib/python3.10/site-packages),
autocommand 2.2.2 (/usr/lib/python3.10/site-packages),
bcrypt 4.0.1 (/usr/lib/python3.10/site-packages),
beautifulsoup4 4.11.1 (/usr/lib/python3.10/site-packages),
btrfsutil 6.1.3 (/usr/lib/python3.10/site-packages),
cachetools 5.3.0 (/usr/lib/python3.10/site-packages),
caffeine-ng 4.0.2 (/usr/lib/python3.10/site-packages),
certifi 2022.12.7 (/usr/lib/python3.10/site-packages),
cffi 1.15.1 (/usr/lib/python3.10/site-packages),
chardet 5.1.0 (/usr/lib/python3.10/site-packages),
click 8.1.3 (/usr/lib/python3.10/site-packages),
configobj 5.1.0.dev0 (/usr/lib/python3.10/site-packages),
cryptography 39.0.1 (/usr/lib/python3.10/site-packages),
cssselect 1.2.0 (/usr/lib/python3.10/site-packages),
cssselect2 0.7.0 (/usr/lib/python3.10/site-packages),
cssutils 2.6.0 (/usr/lib/python3.10/site-packages),
distro 1.8.0 (/usr/lib/python3.10/site-packages),
duplicity 1.2.1 (/usr/lib/python3.10/site-packages),
ewmh 0.1.6 (/usr/lib/python3.10/site-packages),
fasteners 0.18 (/usr/lib/python3.10/site-packages),
fastjsonschema 2.16.2 (/usr/lib/python3.10/site-packages),
filelock 3.8.2 (/usr/lib/python3.10/site-packages),
future 0.18.2 (/usr/lib/python3.10/site-packages),
google-api-core 2.11.0 (/usr/lib/python3.10/site-packages),
google-api-python-client 2.70.0 (/usr/lib/python3.10/site-packages),
google-auth 2.16.0 (/usr/lib/python3.10/site-packages),
google-auth-httplib2 0.1.0 (/usr/lib/python3.10/site-packages),
googleapis-common-protos 1.58.0 (/usr/lib/python3.10/site-packages),
greenlet 2.0.2 (/usr/lib/python3.10/site-packages),
gufw 22.4.0 (/usr/lib/python3.10/site-packages),
httplib2 0.21.0 (/usr/lib/python3.10/site-packages),
idna 3.4 (/usr/lib/python3.10/site-packages),
inflect 6.0.2 (/usr/lib/python3.10/site-packages),
jaraco.context 4.3.0 (/usr/lib/python3.10/site-packages),
jaraco.functools 3.5.2 (/usr/lib/python3.10/site-packages),
jaraco.text 3.11.1 (/usr/lib/python3.10/site-packages),
layoutswitcherlib 0.8.33 (/usr/lib/python3.10/site-packages),
libfdt 1.6.1 (/usr/lib/python3.10/site-packages),
lit 15.0.7.dev0 (/usr/lib/python3.10/site-packages),
lxml 4.9.2 (/usr/lib/python3.10/site-packages),
manjaro-sdk 0.1 (/usr/lib/python3.10/site-packages),
material-color-utilities-python 0.1.5 (/usr/lib/python3.10/site-packages),
meson 1.0.0 (/usr/lib/python3.10/site-packages),
more-itertools 9.0.0 (/usr/lib/python3.10/site-packages),
msgpack 1.0.4 (/usr/lib/python3.10/site-packages),
netsnmp-python 1.0a1 (/usr/lib/python3.10/site-packages),
nftables 0.1 (/usr/lib/python3.10/site-packages),
npyscreen 4.10.5 (/usr/lib/python3.10/site-packages),
nspektr 0.4.0 (/usr/lib/python3.10/site-packages),
numpy 1.24.1 (/usr/lib/python3.10/site-packages),
oauth2client 4.1.3 (/usr/lib/python3.10/site-packages),
ordered-set 4.1.0 (/usr/lib/python3.10/site-packages),
packaging 23.0 (/usr/lib/python3.10/site-packages),
pacman-mirrors 4.23.2 (/usr/lib/python3.10/site-packages),
paramiko 2.11.1 (/usr/lib/python3.10/site-packages),
pip 23.0 (/usr/lib/python3.10/site-packages),
ply 3.11 (/usr/lib/python3.10/site-packages),
protobuf 4.21.12 (/usr/lib/python3.10/site-packages),
psutil 5.9.4 (/usr/lib/python3.10/site-packages),
pulsectl 22.3.2 (/usr/lib/python3.10/site-packages),
pwquality 1.4.5 (/usr/lib/python3.10/site-packages),
pyOpenSSL 23.0.0 (/usr/lib/python3.10/site-packages),
pyaml 21.10.1 (/usr/lib/python3.10/site-packages),
pyasn1 0.4.8 (/usr/lib/python3.10/site-packages),
pyasn1-modules 0.2.8 (/usr/lib/python3.10/site-packages),
pycairo 1.23.0 (/usr/lib/python3.10/site-packages),
pycparser 2.21 (/usr/lib/python3.10/site-packages),
pydantic 1.10.4 (/usr/lib/python3.10/site-packages),
pynvim 0.4.3 (/usr/lib/python3.10/site-packages),
pyparsing 3.0.9 (/usr/lib/python3.10/site-packages),
pysmbc 1.0.23 (/usr/lib/python3.10/site-packages),
python-xlib 0.31 (/usr/lib/python3.10/site-packages),
pytz 2022.7 (/usr/lib/python3.10/site-packages),
pyxdg 0.28 (/usr/lib/python3.10/site-packages),
ranger-fm 1.9.3 (/usr/lib/python3.10/site-packages),
regex 2022.10.31 (/usr/lib/python3.10/site-packages),
reportlab 3.6.12 (/usr/lib/python3.10/site-packages),
requests 2.28.1 (/usr/lib/python3.10/site-packages),
requests-file 1.5.1 (/usr/lib/python3.10/site-packages),
rsa 4.9 (/usr/lib/python3.10/site-packages),
setproctitle 1.3.2 (/usr/lib/python3.10/site-packages),
setuptools 67.3.0 (/usr/lib/python3.10/site-packages),
shiboken6 6.4.2 (/usr/lib/python3.10/site-packages),
shiboken6-generator 6.4.2 (/usr/lib/python3.10/site-packages),
six 1.16.0 (/usr/lib/python3.10/site-packages),
soupsieve 2.3.2.post1 (/usr/lib/python3.10/site-packages),
svglib 1.5.1 (/usr/lib/python3.10/site-packages),
systemd-python 235 (/usr/lib/python3.10/site-packages),
team 1.0 (/usr/lib/python3.10/site-packages),
tinycss2 1.2.1 (/usr/lib/python3.10/site-packages),
tldextract 3.4.0 (/usr/lib/python3.10/site-packages),
tomli 2.0.1 (/usr/lib/python3.10/site-packages),
trove-classifiers 2023.2.9 (/usr/lib/python3.10/site-packages),
typing-extensions 4.4.0 (/usr/lib/python3.10/site-packages),
ufw 0.36.1 (/usr/lib/python3.10/site-packages),
uritemplate 4.1.1 (/usr/lib/python3.10/site-packages),
urllib3 1.26.12 (/usr/lib/python3.10/site-packages),
validate 5.1.0.dev0 (/usr/lib/python3.10/site-packages),
validate-pyproject 0.12.1 (/usr/lib/python3.10/site-packages),
vim-vint 0.3.21 (/usr/lib/python3.10/site-packages),
webencodings 0.5.1 (/usr/lib/python3.10/site-packages),
wheel 0.38.4 (/usr/lib/python3.10/site-packages)],
'sys.path': ['/home/pyrole/Programming/Python',
'/usr/lib/python310.zip',
'/usr/lib/python3.10',
'/usr/lib/python3.10/lib-dynload',
'/home/pyrole/.local/lib/python3.10/site-packages',
'/usr/lib/python3.10/site-packages'],
'sys.prefix': '/usr',
'sys.version_info': sys.version_info(major=3, minor=10, micro=9, releaselevel='final', serial=0)}
```
Hi,
As shown in the output, the pygame package is installed in the conda environment with this path '/home/pyrole/anaconda3/bin/conda', but in PyCharm, a Python system interpreter is set under '/usr/bin/python3.10'.
You can either set Anaconda as a Project interpreter or install pygame in the system interpreter; both options should fix the issue. If you open the PyCharm terminal and see the (base) prefix, then the auto-activation of the Conda environment is toggled on. You can disable it by running the following command:
works nicely thanks for the help