Skip to content

Commit

Permalink
scripts/uninstall_module: import signal module
Browse files Browse the repository at this point in the history
With Python 3.13, the `subprocess` module now uses the
`posix_spawn()` function [1], which requires the `signal`
module to be imported.

Fixes: #2607

[1] https://docs.python.org/3/whatsnew/3.13.html#subprocess

Signed-off-by: Radostin Stoyanov <[email protected]>
  • Loading branch information
rst0git committed Mar 3, 2025
1 parent da7f5b7 commit 5c53af5
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions scripts/uninstall_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@
import subprocess
import sys

# With Python 3.13 the subprocess module uses `posix_spawn()` function
# which requires loading the `signal` module:
# https://docs.python.org/3/whatsnew/3.13.html#subprocess
# flake8: noqa: F401
import signal

Check notice

Code scanning / CodeQL

Unused import Note

Import of 'signal' is not used.

import importlib_metadata


Expand Down

0 comments on commit 5c53af5

Please sign in to comment.