运行python3.9.4时,我无法导入tkinter,但降级到3.8.2工作正常
我在 macOS Catalina 上运行 tcl 8.6.11,我使用安装了 python3
brew install python3
tclsh
% info patchlevel
8.6.11
当前版本的python 3.9.4
python3 --version
Python 3.9.4
>>> import tkinter
import _tkinter # If this fails your Python may not be configured for Tk
ModuleNotFoundError: No module named '_tkinter'
降级到 3.8.2
python3 --version
Python 3.8.2
>>> import tkinter
>>>
不确定是什么原因造成的,任何见解将不胜感激
THE END
二维码