Skip to content

Commit 6f8b34a

Browse files
committed
Merge branch 'master' of github.com:bsdci/libioc into feature/add_config
2 parents deb7dcf + 72cbed7 commit 6f8b34a

File tree

6 files changed

+13
-7
lines changed

6 files changed

+13
-7
lines changed

MANIFEST.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ include LICENSE.txt
33
include *.md
44
include Makefile
55
include *.py
6-
recursive-include iocage *.py
6+
recursive-include libioc *.py

libioc/Jail.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1743,7 +1743,7 @@ def _exec_host_command(
17431743
)
17441744
except StopIteration as return_statement:
17451745
output: libioc.helpers.CommandOutput
1746-
output = return_statement.value
1746+
output = return_statement.value # noqa: T484
17471747
return output
17481748
except (KeyboardInterrupt, SystemExit):
17491749
raise libioc.errors.JailExecutionAborted(

libioc/JailState.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535

3636

3737
def _get_userland_version() -> float:
38-
return float(libioc.helpers.get_os_version()["userland"])
38+
return float(libioc.helpers.get_os_version()["userland"])
3939

4040

4141
def _parse(text: str) -> JailStatesDict:

libioc/ListableResource.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,8 +99,8 @@ def __iter__(
9999
for child_dataset in children:
100100
name = self._get_asset_name_from_dataset(child_dataset)
101101
if has_filters and (filters.match_key("name", name) is False):
102-
# Skip all jails that do not even match the name
103-
continue
102+
# Skip all jails that do not even match the name
103+
continue
104104

105105
# ToDo: Do not load jail if filters do not require to
106106
resource = self._get_resource_from_dataset(child_dataset)

setup.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,12 @@
3131
except ModuleNotFoundError:
3232
from pip.req import parse_requirements
3333

34+
try:
35+
import setuptools_scm.integration
36+
setuptools_scm.integration.find_files = lambda _: []
37+
except ImportError:
38+
pass
39+
3440

3541
def _read_requirements(
3642
filename: str="requirements.txt"

tests/test_Jail.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,12 +96,12 @@ def cleanup() -> None:
9696
data = read_jail_config_json(f"{dataset.mountpoint}/config.json")
9797

9898
try:
99-
assert data["basejail"] is "no"
99+
assert data["basejail"] == "no"
100100
except KeyError:
101101
pass
102102

103103
try:
104-
assert (data["basejail"] is "") or (data["basejail"] == "none")
104+
assert (data["basejail"] == "") or (data["basejail"] == "none")
105105
except KeyError:
106106
pass
107107

0 commit comments

Comments
 (0)