1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 12:59:34 +00:00

Improve performance of generating non-cryptographically secure uuids (#41314)

This commit is contained in:
J. Nick Koston
2020-10-07 09:37:01 -05:00
committed by GitHub
parent 451f27bba1
commit 8d5c124deb
6 changed files with 14 additions and 17 deletions

View File

@@ -73,7 +73,7 @@ class DeviceEntry:
area_id: str = attr.ib(default=None)
name_by_user: str = attr.ib(default=None)
entry_type: str = attr.ib(default=None)
id: str = attr.ib(factory=uuid_util.uuid_v1mc_hex)
id: str = attr.ib(factory=uuid_util.random_uuid_hex)
# This value is not stored, just used to keep track of events to fire.
is_new: bool = attr.ib(default=False)