1
0
mirror of https://github.com/esphome/esphome.git synced 2025-09-03 11:52:20 +01:00

Bump python min to 3.9 (#3871)

This commit is contained in:
Jesse Hills
2022-10-05 20:09:27 +13:00
committed by GitHub
parent c3a8972550
commit d220d41182
25 changed files with 130 additions and 147 deletions

View File

@@ -1,7 +1,7 @@
import socket
import threading
import time
from typing import Dict, Optional
from typing import Optional
import logging
from dataclasses import dataclass
@@ -71,12 +71,12 @@ class DashboardStatus(threading.Thread):
threading.Thread.__init__(self)
self.zc = zc
self.query_hosts: set[str] = set()
self.key_to_host: Dict[str, str] = {}
self.key_to_host: dict[str, str] = {}
self.stop_event = threading.Event()
self.query_event = threading.Event()
self.on_update = on_update
def request_query(self, hosts: Dict[str, str]) -> None:
def request_query(self, hosts: dict[str, str]) -> None:
self.query_hosts = set(hosts.values())
self.key_to_host = hosts
self.query_event.set()