0

I'm quite new to programming. For the last couple of months I was working with PyCharm without any issues and also didn't do any changes (not sure if I have by accident deleted anything in Pycharm in the external libraries which may be causing any issues?). When running python.exe via CMD I get below error. Same appears in PyCharm, only that the PYTHONPATH differs

PYTHONHOME = (not set)
  PYTHONPATH = (not set)
  program name = 'python.exe'
  isolated = 0
  environment = 1
  user site = 1
  import site = 1
  sys._base_executable = 'C:\\Users\\LXVFL\\AppData\\Local\\Programs\\Python\\Python310\\python.exe'
  sys.base_prefix = ''
  sys.base_exec_prefix = ''
  sys.platlibdir = 'lib'
  sys.executable = 'C:\\Users\\LXVFL\\AppData\\Local\\Programs\\Python\\Python310\\python.exe'
  sys.prefix = ''
  sys.exec_prefix = ''
  sys.path = [
    'C:\\Users\\LXVFL\\AppData\\Local\\Programs\\Python\\Python310\\python310.zip',
    'C:\\Users\\LXVFL\\AppData\\Local\\Programs\\Python\\Python310\\Lib\\',
    'C:\\Users\\LXVFL\\AppData\\Local\\Programs\\Python\\Python310\\DLLs\\',
    'C:\\Users\\LXVFL\\AppData\\Local\\Programs\\Python\\Python310',
  ]
Fatal Python error: init_fs_encoding: failed to get the Python codec of the filesystem encoding
Python runtime state: core initialized
ModuleNotFoundError: No module named 'encodings'

Current thread 0x00002e60 (most recent call first):
  <no Python frame>

What can I do here? Thanks for any kind of help :-)

2

2 Answers 2

1

Update: What finally solved my problem was to simply deinstall and reinstall Python. Still no clue what even caused the issue in the first place but it is gone

Sign up to request clarification or add additional context in comments.

1 Comment

My same problem has been solved when I converted C:\Python\python.exe to C:\Python
0

I encountered the same problem. Reinstalling python solved mine

1 Comment

This does not provide an answer to the question. Once you have sufficient reputation you will be able to comment on any post; instead, provide answers that don't require clarification from the asker. - From Review

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.