"TypeError: cannot unpack non-iterable NoneType object" with ttkbootstrap Meter widget in Anaconda Python

25 views Asked by At

Trying to set a Meter Widget from ttkbootstrap using Python 3.11.5 from Anaconda Distribution. Running my code in ipython terminal responds:

  File ~\anaconda3\Lib\site-packages\ttkbootstrap\style.py:367 in update_hsv
    r, g, b = Colors.hex_to_rgb(color)

  File ~\anaconda3\Lib\site-packages\ttkbootstrap\style.py:315 in hex_to_rgb
    r, g, b = colorutils.color_to_rgb(color)

TypeError: cannot unpack non-iterable NoneType object

This may be a problem with Python version or Anaconda with ttkbootstrap? Someone had the same issue?

class MainWindow(ttk.Window):
    def __init__(self):
        super().__init__()
        self.title("Sys Monitor")
        self.resizable(0, 0)
        
        frm = ttk.Frame(self)
        frm.pack(padx=10, pady=10)
        
        meter_cpu = ttk.Meter(frm, amountused=25, meterthickness=20, subtext='CPU Use')        
        meter_cpu.grid(row=0, column=0, padx=10, pady=10)
 
MainWindow().mainloop()
0

There are 0 answers