Skip to content

Commit

Permalink
Fix flake8
Browse files Browse the repository at this point in the history
  • Loading branch information
jeckel committed Oct 17, 2024
1 parent 8c20048 commit 881452a
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 13 deletions.
19 changes: 15 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,16 @@ repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.3.0
hooks:
- id: check-yaml
- id: end-of-file-fixer
- id: trailing-whitespace
- id: check-yaml
- id: end-of-file-fixer
- id: trailing-whitespace

- repo: https://github.com/psf/black
rev: 22.10.0
hooks:
- id: black
- id: black
files: src/
types: [file, python]

- repo: https://github.com/myint/autoflake
rev: v2.3.1
Expand All @@ -27,3 +29,12 @@ repos:
- id: isort
name: isort (python)
files: src/
types: [ file, python ]

- repo: https://github.com/pycqa/flake8
rev: 7.1.1
hooks:
- id: flake8
files: src/
types: [file, python]
args: [--max-line-length=131, --ignore, "F401"]
8 changes: 0 additions & 8 deletions src/composer_utils.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
import subprocess

from rich import print

from models import Project


def composer_updatable(path: str) -> dict[str, str]:
with subprocess.Popen(
Expand All @@ -13,11 +9,7 @@ def composer_updatable(path: str) -> dict[str, str]:
stderr=subprocess.PIPE,
text=True,
) as process:
# output = process.stdout.read().strip()
# print(f'Sortie {output}')
output = process.stderr.read().strip()
# print(f'SortieErr {output}')

# Split the output into lines
lines = output.strip().split("\n")
packages: dict[str, str] = {}
Expand Down
3 changes: 2 additions & 1 deletion src/presentation/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
from textual.app import App, ComposeResult
from textual.widgets import TabbedContent, Header, Footer
from textual.widgets import Footer, Header, TabbedContent

from models import Project

from .composer import ComposerPan
from .docker import DockerPan
from .summary import ProjectSummaryPan
Expand Down

0 comments on commit 881452a

Please sign in to comment.