Gns3-gui: Fatal Python error: Py_Initialize: Unable to get the locale encoding

Created on 13 Sep 2017  路  5Comments  路  Source: GNS3/gns3-gui

aungthuhan@boom:~$ gns3
Could not find platform independent libraries
Could not find platform dependent libraries
Consider setting $PYTHONHOME to [:]
Fatal Python error: Py_Initialize: Unable to get the locale encoding
ImportError: No module named 'encodings'
Aborted

Most helpful comment

I'm dealing with this issue for two days. It is so frusturating for me to see the solution was too easy.
Setting a particular Python path did the trick for me. In terminal:
gedit ~/.bashrc
We need to add a python path in there. This one below did the trick for me.
export PYTHONPATH=$PYTHONPATH:/usr/lib/python3.6

Please note that, I previously added codes below which didn't solve my problem. Just for warning.

#export PYTHONPATH=$PYTHONPATH:/usr/local/lib/python3.6/dist-packages
#export PYTHONPATH=$PYTHONPATH:/usr/bin/python3
#export PYTHONHOME=$PYTHONHOME:/usr/local/lib/python3.6/dist-packages

All 5 comments

There seems to be a problem with how Python has been installed. Also, we do not officially support the Deepin distribution. Please post on our community forum over at http://gns3.com/community for help.

Thanks!

Same here!

I'm dealing with this issue for two days. It is so frusturating for me to see the solution was too easy.
Setting a particular Python path did the trick for me. In terminal:
gedit ~/.bashrc
We need to add a python path in there. This one below did the trick for me.
export PYTHONPATH=$PYTHONPATH:/usr/lib/python3.6

Please note that, I previously added codes below which didn't solve my problem. Just for warning.

#export PYTHONPATH=$PYTHONPATH:/usr/local/lib/python3.6/dist-packages
#export PYTHONPATH=$PYTHONPATH:/usr/bin/python3
#export PYTHONHOME=$PYTHONHOME:/usr/local/lib/python3.6/dist-packages

Fatal Python error: Py_Initialize: can't initialize sys standard streams
is what I get.....

Was this page helpful?
0 / 5 - 0 ratings