Skip to content

Commit 492b0b6

Browse files
committed
http: api: devices: prettier random name
1 parent 961bfe3 commit 492b0b6

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/enapter/http/api/devices/client.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,8 @@ async def generate_communication_config(
156156

157157

158158
def random_device_name(device_type: DeviceType) -> str:
159-
return f"{device_type.value} ({time.time()})"
159+
timestamp = int(time.time())
160+
return f"{device_type.value}_{timestamp}"
160161

161162

162163
def random_hardware_id() -> str:

0 commit comments

Comments
 (0)