Last updated on July 21, 2020 by Dan Nanni
ImportError: No module named wxversion.How can I solve this error in the Python program?
Looking for python... 2.7.9 - Traceback (most recent call last): File "/home/dev/playonlinux/python/check_python.py", line 1, inimport os, wxversion ImportError: No module named wxversion failed tests
This error indicates that your Python application is GUI-based, relying on a missing Python module called wxPython. wxPython is a Python extension module for the wxWidgets GUI library, popularly used by C++ programmers to design GUI applications. The wxPython extension allows Python developers to easily design and integrate GUI within any Python application.
To solve this import error, you need to install wxPython on your Linux, as described below.
$ sudo apt-get install python-wxgtk2.8
$ sudo yum install wxPython
wxPython is available on the EPEL repository of CentOS/RHEL, not on base repositories. Thus, first enable EPEL repository on your system, and then use yum
command.
$ sudo yum install wxPython
$ sudo pacman -S wxpython
$ emerge wxPython
This website is made possible by minimal ads and your gracious donation via PayPal or credit card
Please note that this article is published by Xmodulo.com under a Creative Commons Attribution-ShareAlike 3.0 Unported License. If you would like to use the whole or any part of this article, you need to cite this web page at Xmodulo.com as the original source.
Xmodulo © 2021 ‒ About ‒ Write for Us ‒ Feed ‒ Powered by DigitalOcean