From f9b94a1a47912a10f0c2152ad7dffb6040546706 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Vinot?= Date: Fri, 10 Nov 2023 17:25:18 +0100 Subject: [PATCH] fix invalid escape warning in registry string - closes #9 --- machineid/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/machineid/__init__.py b/machineid/__init__.py index baf818e..ee57e4c 100644 --- a/machineid/__init__.py +++ b/machineid/__init__.py @@ -67,7 +67,7 @@ def id(winregistry: bool = True) -> str: id = __exec__("ioreg -d2 -c IOPlatformExpertDevice | awk -F\\\" '/IOPlatformUUID/{print $(NF-1)}'") elif platform == 'win32' or platform == 'cygwin' or platform == 'msys': if winregistry: - id = __reg__('HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Cryptography', 'MachineGuid') + id = __reg__(r'HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Cryptography', 'MachineGuid') else: id = __exec__("powershell.exe -ExecutionPolicy bypass -command (Get-CimInstance -Class Win32_ComputerSystemProduct).UUID") if not id: