Skip to content

Commit 3270640

Browse files
authored
Add python 3.10 to CI (#31)
* Add p3.10 * Fix linter * Fixup * Change to pytest for p3.10 support
1 parent b57565c commit 3270640

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

.github/workflows/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
strategy:
1919
fail-fast: false
2020
matrix:
21-
python-version: [3.6, 3.7, 3.8, 3.9]
21+
python-version: [3.6, 3.7, 3.8, 3.9, "3.10"]
2222

2323
steps:
2424
- uses: actions/checkout@v2

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ target_dirs := tests coqpit
88

99

1010
test: ## run tests.
11-
nosetests -x --with-cov -cov --cover-erase --cover-package coqpit tests --nologcapture --nocapture
11+
coverage run -m pytest && coverage report --show-missing
1212

1313
style: ## update code style.
1414
black ${target_dirs}

coqpit/coqpit.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -408,7 +408,7 @@ def deserialize(self, data: dict) -> "Serializable":
408408
init_kwargs[field.name] = value
409409
continue
410410
if value == MISSING:
411-
raise ValueError("deserialized with unknown value for {} in {}".format(field.name, self.__name__))
411+
raise ValueError(f"deserialized with unknown value for {field.name} in {self.__name__}")
412412
value = _deserialize(value, field.type)
413413
init_kwargs[field.name] = value
414414
for k, v in init_kwargs.items():
@@ -438,7 +438,7 @@ def deserialize_immutable(cls, data: dict) -> "Serializable":
438438
init_kwargs[field.name] = value
439439
continue
440440
if value == MISSING:
441-
raise ValueError("Deserialized with unknown value for {} in {}".format(field.name, cls.__name__))
441+
raise ValueError(f"Deserialized with unknown value for {field.name} in {cls.__name__}")
442442
value = _deserialize(value, field.type)
443443
init_kwargs[field.name] = value
444444
return cls(**init_kwargs)

requirements_dev.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
pylint
22
black
3-
nose
3+
pytest
44
coverage

0 commit comments

Comments
 (0)