0

After installing wxPython (brew install wxpython) and then downloading wxGlade and putting it in my Home directory. I get a terminal window go to the wxGlade machine and run: python3 wxglade.py (or even python wxglade.py) I get an error:

    chrisanderson@Chriss-MBP wxGlade-1.0.2 % python wxglade.py             
Traceback (most recent call last):
  File "wxglade.py", line 47, in <module>
    import common, config, compat, log
  File "/Users/chrisanderson/wxGlade-1.0.2/common.py", line 24, in <module>
    import config, compat, plugins, misc
  File "/Users/chrisanderson/wxGlade-1.0.2/compat.py", line 25, in <module>
    import wx
ImportError: No module named wx

If I do a which wxpython or which wx it says it can't find either. All of the "tutorials" I've found say "run wxGlade" then goes to the next step. The wxGlade site says to run it by changing to that folder and running it with either python or python3 - which, as stated above - I have.

--Edit forgot to mention- if I try import wx in a py file, it says:

"wx" is not accessedPylance
Import "wx" could not be resolvedPylancereportMissingImports

Anyone help install/setup wxPython and wxGlade to run on BigSur properly?

ChrisA
  • 1
  • 1
  • how did you install wxPython? What version? What if you try to run the follwing: `python` and then `import wx`? Are you trying Phoenix or regular version of wxPython? – Igor Aug 24 '21 at 16:41
  • As stated in my first line: brew install wxpython I'm assuming that, like most other brew installs, it installed the latest. Not sure how to install, or what is Phoenix. Just trying to get up and running on wx as I've been using tkinter (python3). Yes, I've tried it from the terminal as well as within VSCode. – ChrisA Aug 24 '21 at 16:46
  • according to https://www.wxpython.org/pages/downloads/, you should try `pip install -U wxPython`. I don't know what brew did and I personally wouldn't trust it. Especially on the Python side, while it have its own way of installing things. – Igor Aug 24 '21 at 17:07
  • Fantasitc! That fixed it... – ChrisA Aug 24 '21 at 17:20
  • BTW, Phoenix is a new generation wxPython when you transition to python3. You can run either one of them `phoenix` or `classic`. I'm not sure which one is being set up by default though - I think it is classic. – Igor Aug 24 '21 at 17:27

0 Answers0