ModuleNotFoundError: No module named '_tkinter'

Mac上解决此问题

$ brew install tcl-tk
$ export LDFLAGS="-L/usr/local/opt/tcl-tk/lib"
$ export CPPFLAGS="-I/usr/local/opt/tcl-tk/include"
$ export PATH=$PATH:/usr/local/opt/tcl-tk/bin

参考资料
参考资料1

你可能感兴趣的:(Python)