1
0
mirror of https://github.com/norohind/jubilant-system-core.git synced 2025-04-17 03:32:19 +03:00

Human friendly names for hooks threads

This commit is contained in:
norohind 2022-04-10 23:17:13 +03:00
parent 23ebf1b608
commit a5e401ebea
Signed by: norohind
GPG Key ID: 01C3BECC26FB59E1

@ -55,4 +55,8 @@ class HookSystem:
@staticmethod
def _notify(operation_id, hooks: list[Hook]) -> None:
for hook in hooks:
threading.Thread(target=hook.update, args=(operation_id,)).start()
threading.Thread(
name=f'hook-{hook.__class__.__name__}-{operation_id}',
target=hook.update,
args=(operation_id,)
).start()