Переменная якобы не используется. Где ошибка?

Вылетает предупреждение Unused variable 'tmr_run'

def GUI():
    global tmr_run
    tmr_run=False
    def start():
        timeLbl.configure(text=w_Time)
        btn1.configure(text="Закончить работу",command=stop)
        tmr_run=True
    def stop():
        timeLbl.configure(text="00:00:00")
        btn1.configure(text="Начать работу",command=start)
        tmr_run=False

def _timer_():
    global w_Time_raw
    global nw_Time_raw
    global timeout_raw
    w_Time_raw=int(0)
    nw_Time_raw=int(0)
    timeout_raw=int(0)
    while True:
        if tmr_run == True:
            if work == True:
                w_Time_raw=w_Time_raw + 1
                time.sleep(1)
                timeout_raw=int(0)
                timeLbl.configure(text=datetime.timedelta(seconds=w_Time_raw))
            elif work != True and timeout_raw >= 10:
                nw_Time_raw = nw_Time_raw + 1
                time.sleep(1)
            else:
                timeout_raw = timeout_raw + 1
                w_Time_raw = w_Time_raw + 1
                time.sleep(1)

Цикличный вывод переменной tmr_run=False


Ответы (0 шт):