Solved how to write a python GUI app in freebsd14 gnome

dear all :
i an new guy for python, now i have installed python3.10 in my freebsd 14 gnome. i want to write a GUI app with python3.10. so i installed a wxPython with command "pkg install py39-wxPython42-4.2.0_1 " . i write a program with wxpython dll use "import wx". the program is not work. and error was below :
#
Traceback (most recent call last):
File "/home/game/document/python_app/test.py", line 6, in <module>
import wx
ModuleNotFoundError: No module named 'wx'
#

anyone, can help me ? thanks.
 
dear all :
thanks for your help , i have find solution for my issue. below is the step :
1. pkg install python39-3.9.18
2. pkg install py39-wxPython42-4.2.0_1
3. pkg install vscode
4. vscode install python (ms-python) and python debugger.
5. open vscode File menu--->preferences-->settings---->extensions----->python---->Default interpreter Path----> in this place , we must input our python location (example : /usr/local/bin/python3.9).

import things : if you install much more version python. ,now we only use python3.9 and py39-wxpython42-4 to write a GUI app in freebsd 14.


ok. all done. when you import wx GUI model . they will work normal. thanks for all.
 
Back
Top