Merge pull request #1143 from italomaia/bug/use-ruff

Bug: replaced black with ruff on pre-commit
This commit is contained in:
Povilas Kanapickas 2025-02-26 18:21:31 +02:00 committed by GitHub
commit 976847ef9b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 8 additions and 13 deletions

View File

@ -1,17 +1,9 @@
repos:
- repo: https://github.com/psf/black
rev: 23.3.0
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.9.6
hooks:
- id: black
# It is recommended to specify the latest version of Python
# supported by your project here, or alternatively use
# pre-commit's default_language_version, see
# https://pre-commit.com/#top_level-default_language_version
language_version: python3.10
- id: ruff
types: [python]
args: [
"--check", # Don't apply changes automatically
]
- repo: https://github.com/pycqa/flake8
rev: 6.0.0
hooks:

View File

@ -1299,7 +1299,8 @@ class ServiceDependencyCondition(Enum):
try:
return docker_to_podman_cond[value]
except KeyError:
raise ValueError(f"Value '{value}' is not a valid condition for a service dependency") # pylint: disable=raise-missing-from
# pylint: disable-next=raise-missing-from
raise ValueError(f"Value '{value}' is not a valid condition for a service dependency")
class ServiceDependency:

View File

@ -6,4 +6,6 @@ version = attr: podman_compose.__version__
[flake8]
# The GitHub editor is 127 chars wide
max-line-length=127
max-line-length=127
# These are not being followed yet
ignore=E222,E231,E272,E713,W503