Forums

problems on 502-backend

My two apps worked very well for two years, and it suddenly showed something is wrong

" If you keep getting this message, you should check your site's server and error logs for any messages.

Error code: 502-backend"

I did not see anything on error logs, but server log said as below. I googled a little bit, somebody said about venv rebuild, but why my venv suddenly failed?

2022-11-30 16:35:51 Fatal Python error: Py_Initialize: Unable to get the locale encoding 2022-11-30 16:35:51 ModuleNotFoundError 2022-11-30 16:35:51 : 2022-11-30 16:35:51 No module named 'encodings' 2022-11-30 16:35:51 2022-11-30 16:35:51 2022-11-30 16:35:51 Current thread 0x 2022-11-30 16:35:51 00007f926aa3b780 2022-11-30 16:35:51 (most recent call first): 2022-11-30 16:35:51 !!! uWSGI process 1 got Segmentation Fault !!!

We deprecated the system image that you were using today and that has made your virtualenv not work. We have sent multiple emails warning about the change over the last year.

I delete venv and anything in cache as guided, then rebuild venv but still have the same problem. Did I miss anything?

And my python version is 3.6, I assume it is also available on new system image.

Hello, it looks like one of your websites is running ok. Have you managed to solve your problem? The other one isn't working because you haven't set up a virtual env.

Yes, I finally figured it out after rebuilding five times.

OK -- glad to hear that you got it working!