From 476cdee95c9233cb990bfcf864b7b5a74c1da81f Mon Sep 17 00:00:00 2001 From: Kai Schlamp Date: Fri, 27 Sep 2024 21:29:12 +0000 Subject: [PATCH] Fix lint task --- tasks.py | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/tasks.py b/tasks.py index 74318fe..4d2298a 100644 --- a/tasks.py +++ b/tasks.py @@ -2,7 +2,7 @@ from pathlib import Path from shutil import copy -from adit_radis_shared.invoke_tasks import bump_version, lint, show_outdated # noqa: F401 +from adit_radis_shared.invoke_tasks import show_outdated # noqa: F401 from invoke.context import Context from invoke.tasks import task @@ -69,6 +69,16 @@ def test( ctx.run(cmd, pty=True) +@task +def lint(ctx: Context): + """Lint the source code (ruff, djlint, pyright)""" + print("Linting Python code with ruff...") + ctx.run("poetry run ruff check .", pty=True) + + print("Linting Python code with pyright...") + ctx.run("poetry run pyright", pty=True) + + @task def publish_client(ctx: Context): """Publish RADIS Client to PyPI