Forums

No module named 'encodings'

2023-04-19 13:59:15 Python version: 3.7.13 (default, Jul 22 2022, 17:01:12) [GCC 9.4.0] 2023-04-19 13:59:15 Set PythonHome to /home/Yahiba/.virtualenvs/haggisjaime 2023-04-19 13:59:15 Fatal Python error: 2023-04-19 13:59:15 initfsencoding 2023-04-19 13:59:15 : 2023-04-19 13:59:15 Unable to get the locale encoding 2023-04-19 13:59:15 2023-04-19 13:59:15 ModuleNotFoundError 2023-04-19 13:59:15 : 2023-04-19 13:59:15 No module named 'encodings' 2023-04-19 13:59:15 2023-04-19 13:59:15 2023-04-19 13:59:15 Current thread 0x 2023-04-19 13:59:15 00007fbb828f9780 2023-04-19 13:59:15 (most recent call first): 2023-04-19 13:59:15 !!! uWSGI process 1 got Segmentation Fault !!!

Hello,

I am trying to update from earlgrey to haggis but running into some problems.

Created a new virtual env after changing to haggis but after reloading the app I'm getting this error. I think it's related to an incorrect path but I verified and the new env I created is on the correct path.

How can I solve this?

Thank you

when I deactivate or «work on» the new env I get the following lines:

bash: /home/Yahiba/.local/bin/python: No such file or directory bash: /home/Yahiba/.local/bin/python: No such file or directory

Is that in a console that you created after you updated your system image? If not, then start a new console. You will also need to reload your web app after changing the virtualenv that it is using.

hello!

A new console solved the second problem but I still have the first question. The website is down. The server log files say: No module named 'encodings'. and segmentation fault.

If I change back to earlgrey and keep the new env it still doesn't work. but if keep earlgrey with the old env it does work. so I assume there is something wrong with the new env I've created.

I have no idea what could be causing this

If you create a virtualenv on one system image, it will not work in a different system image. It sounds like you created both virtualenvs on earlgrey. If you want a virtualenv that works on haggis, you need to create it on haggis.

I've tried doing that. Changed to haggis, then created new env in new console. Still getting segmentation fault. Any ideas? what could be causing this?

Solved, suddenly started getting another module missing (mysql). I didn't understand what triggered the change but installed another version of that module and it worked. Thanks for the support.

OK, glad to hear you solved the problem!