From 14a8f2b47757e3b8f0aceadbd0a93e9bb9030f4d Mon Sep 17 00:00:00 2001 From: L0m1g Date: Sat, 3 May 2025 16:19:45 +0200 Subject: [PATCH] Fix: black error on pre-commit --- Makefile | 1 + erminig/system/security.py | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 4ec82b9..ef6e999 100644 --- a/Makefile +++ b/Makefile @@ -8,6 +8,7 @@ test: fmt: black erminig tests + git add erminig tests docker-build: podman-compose -f docker-compose.yml build diff --git a/erminig/system/security.py b/erminig/system/security.py index 98bc2f1..a1c420d 100644 --- a/erminig/system/security.py +++ b/erminig/system/security.py @@ -41,7 +41,9 @@ def run_as_user(username): if pid > 0: # Parent : attendre le child, ne pas exit, juste return proprement _, status = os.waitpid(pid, 0) - return status >> 8 # récupère le code retour du fils (comme exit code) + return ( + status >> 8 + ) # récupère le code retour du fils (comme exit code) # Child pw_record = pwd.getpwnam(username) @@ -60,4 +62,4 @@ def run_as_user(username): return wrapper - return decorator \ No newline at end of file + return decorator