diff options
author | Helmut Grohne <helmut@subdivi.de> | 2024-03-12 09:27:05 +0100 |
---|---|---|
committer | Helmut Grohne <helmut@subdivi.de> | 2024-03-12 09:27:05 +0100 |
commit | 76fe71a4c990bd98938e94cc08356a4c917371f5 (patch) | |
tree | 002a9c037168061cd610fa7113f9e51a4cca2ad0 | |
parent | f9b0cf016effb397e32c413c9b0384eb6ee3b4a9 (diff) | |
download | python-linuxnamespaces-76fe71a4c990bd98938e94cc08356a4c917371f5.tar.gz |
work around mypy misdetection on bookworm
-rw-r--r-- | linuxnamespaces/syscalls.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/linuxnamespaces/syscalls.py b/linuxnamespaces/syscalls.py index 8f5e25b..de1b87e 100644 --- a/linuxnamespaces/syscalls.py +++ b/linuxnamespaces/syscalls.py @@ -224,6 +224,9 @@ class MountFlags(enum.IntFlag): parts: list[str] = [] remain = self for val, text in MountFlags.__flagvals: + # Older mypy think MountFlags.__flagvals and thus text was of type + # MountFlags. + assert isinstance(text, str) if remain & val == val: parts.insert(0, text) remain &= ~val |