Merge pull request #155 from long2ice/pyupgrade

Add pyupgrade linter
This commit is contained in:
Martijn Pieters
2023-05-16 13:07:56 +01:00
committed by GitHub
2 changed files with 2 additions and 1 deletions

View File

@@ -52,7 +52,7 @@ def object_hook(obj: Any) -> Any:
if _spec_type in CONVERTERS:
return CONVERTERS[_spec_type](obj["val"])
else:
raise TypeError("Unknown {}".format(_spec_type))
raise TypeError(f"Unknown {_spec_type}")
class Coder:

View File

@@ -86,6 +86,7 @@ select = [
"F", # pyflakes
"I", # isort
"W", # pycodestyle warnings
"UP", # pyupgrade
]
target-version = "py37"