Why doesn't tkinter import on CentOs 7

前端 未结 4 1945
孤独总比滥情好
孤独总比滥情好 2021-01-24 21:29

I have the python3-tkinter installed, as shown below:

$ sudo yum install python3-tkinter
[sudo] password for abigail: 
Loaded plugins: fastestmirror, langpacks
L         


        
4条回答
  •  暗喜
    暗喜 (楼主)
    2021-01-24 22:05

    You have both IUS and nux-desktop repos enabled. It appears that nux-desktop has a package named python3 of version 3.3.2, with the related python3-tkinter package. IUS on the other hand has packages for python34u (3.4.6), python35u (3.5.3), and python36u (3.6.0), all with corresponding tkinter packages. So if you want to be able to import tkinter inside a python3.5 REPL, then run:

    yum install python35u-tkinter
    

提交回复
热议问题