get rid of ValueError

This commit is contained in:
Jörg Thalheim
2024-09-03 18:07:36 +02:00
parent 29909e49d3
commit 5ac3ac63c2
11 changed files with 34 additions and 22 deletions

View File

@@ -146,7 +146,7 @@ def run_cmd(programs: list[str], cmd: list[str]) -> list[str]:
for program in programs:
if not Programs.is_allowed(program):
msg = f"Program not allowed: {program}"
raise ValueError(msg)
raise ClanError(msg)
if os.environ.get("IN_NIX_SANDBOX"):
return cmd
missing_packages = [