diff --git a/Makefile b/Makefile index deda3f5..7cc8cfb 100644 --- a/Makefile +++ b/Makefile @@ -82,7 +82,7 @@ install: clean ## install the package to the active Python's site-packages pip install . environment: ## Handles environment creation - conda env create -f environment.yaml --name $(CONDA_ENV_NAME) --force + conda env create -f environment.yaml --name $(CONDA_ENV_NAME) --yes conda run --name $(CONDA_ENV_NAME) pip install -e . release: dist ## package and upload a release @@ -93,7 +93,7 @@ dist: clean ## builds source and wheel package ls -l dist dev: clean ## install the package's development version - conda env create -f environment.yaml --name $(CONDA_ENV_NAME) --force + conda env create -f environment.yaml --name $(CONDA_ENV_NAME) --yes conda run --name $(CONDA_ENV_NAME) pip install -e . $(CONDA_ACTIVATE) $(CONDA_ENV_NAME) && pre-commit install diff --git a/anaconda_linter/__init__.py b/anaconda_linter/__init__.py index 0ab4866..f45700a 100644 --- a/anaconda_linter/__init__.py +++ b/anaconda_linter/__init__.py @@ -2,6 +2,7 @@ File: __init__.py Description: Module configurations for the `anaconda-linter` project """ + __name__ = "anaconda_linter" # pylint: disable=redefined-builtin __version__ = "0.1.5" __author__ = "Anaconda, Inc." diff --git a/anaconda_linter/lint/__init__.py b/anaconda_linter/lint/__init__.py index 07b4e60..2b9f54e 100644 --- a/anaconda_linter/lint/__init__.py +++ b/anaconda_linter/lint/__init__.py @@ -79,6 +79,7 @@ check_url """ + from __future__ import annotations import abc diff --git a/anaconda_linter/lint/check_completeness.py b/anaconda_linter/lint/check_completeness.py index eda60b5..2509937 100644 --- a/anaconda_linter/lint/check_completeness.py +++ b/anaconda_linter/lint/check_completeness.py @@ -2,6 +2,7 @@ File: check_completeness.py Description: Contains linter checks for missing essential information. """ + from __future__ import annotations import os diff --git a/anaconda_linter/lint/check_multi_output.py b/anaconda_linter/lint/check_multi_output.py index f22a547..60b67b1 100644 --- a/anaconda_linter/lint/check_multi_output.py +++ b/anaconda_linter/lint/check_multi_output.py @@ -2,6 +2,7 @@ File: check_multi_output.py Description: Contains linter checks for multi-output based rules. """ + from __future__ import annotations from anaconda_linter import utils as _utils diff --git a/anaconda_linter/lint/check_spdx.py b/anaconda_linter/lint/check_spdx.py index aea35ad..007a391 100644 --- a/anaconda_linter/lint/check_spdx.py +++ b/anaconda_linter/lint/check_spdx.py @@ -2,6 +2,7 @@ File: check_spdx.py Description: Contains linter checks for SPDX licensing database based rules. """ + from __future__ import annotations import os diff --git a/anaconda_linter/lint/check_syntax.py b/anaconda_linter/lint/check_syntax.py index 5ce2415..c61d1eb 100644 --- a/anaconda_linter/lint/check_syntax.py +++ b/anaconda_linter/lint/check_syntax.py @@ -2,6 +2,7 @@ File: check_syntax.py Description: Contains linter checks for syntax rules. """ + from __future__ import annotations import re diff --git a/anaconda_linter/run.py b/anaconda_linter/run.py index 1443f9b..9928cce 100644 --- a/anaconda_linter/run.py +++ b/anaconda_linter/run.py @@ -2,6 +2,7 @@ File: run.py Description: Primary execution point of the linter's CLI """ + from __future__ import annotations import argparse diff --git a/anaconda_linter/utils.py b/anaconda_linter/utils.py index a3f456c..a5ec739 100644 --- a/anaconda_linter/utils.py +++ b/anaconda_linter/utils.py @@ -4,6 +4,7 @@ This module collects small pieces of code used throughout :py:mod:`anaconda_linter`. """ + from __future__ import annotations import logging diff --git a/scripts/update_licenses.py b/scripts/update_licenses.py index 72c25bd..d15d804 100644 --- a/scripts/update_licenses.py +++ b/scripts/update_licenses.py @@ -2,6 +2,7 @@ File: update_licenses.py Description: Stand-alone script """ + from __future__ import annotations import os diff --git a/tests/conftest.py b/tests/conftest.py index dafac41..28f684a 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -2,6 +2,7 @@ File: conftest.py Description: Provides utilities and test fixtures for test files. """ + from __future__ import annotations from pathlib import Path diff --git a/tests/lint/test_auto_fix_rules.py b/tests/lint/test_auto_fix_rules.py index 0a1d4f2..bcfb0d2 100644 --- a/tests/lint/test_auto_fix_rules.py +++ b/tests/lint/test_auto_fix_rules.py @@ -8,6 +8,7 @@ - An input test file that triggers the target linting rule - An output test file that matches an expected, automatically corrected, resulting file """ + from __future__ import annotations import pytest diff --git a/tests/lint/test_build_help.py b/tests/lint/test_build_help.py index 239c1e9..a9177ce 100644 --- a/tests/lint/test_build_help.py +++ b/tests/lint/test_build_help.py @@ -2,6 +2,7 @@ File: test_build_help.py Description: Tests build section rules """ + from __future__ import annotations from pathlib import Path diff --git a/tests/lint/test_completeness.py b/tests/lint/test_completeness.py index 56c65c4..38d6975 100644 --- a/tests/lint/test_completeness.py +++ b/tests/lint/test_completeness.py @@ -2,6 +2,7 @@ File: test_completeness.py Description: Tests completeness rules (i.e. `missing_*`) """ + from __future__ import annotations from pathlib import Path diff --git a/tests/lint/test_multi_output.py b/tests/lint/test_multi_output.py index ee616f2..fa044e7 100644 --- a/tests/lint/test_multi_output.py +++ b/tests/lint/test_multi_output.py @@ -2,6 +2,7 @@ File: test_multi_output.py Description: Tests multi-output-based rules """ + from __future__ import annotations import pytest diff --git a/tests/lint/test_spdx.py b/tests/lint/test_spdx.py index c7d778a..8b4d53b 100644 --- a/tests/lint/test_spdx.py +++ b/tests/lint/test_spdx.py @@ -2,6 +2,7 @@ File: test_spdx.py Description: Tests licensing rules using the SPDX database """ + from __future__ import annotations from conftest import check diff --git a/tests/lint/test_syntax.py b/tests/lint/test_syntax.py index 5629102..183dd71 100644 --- a/tests/lint/test_syntax.py +++ b/tests/lint/test_syntax.py @@ -2,6 +2,7 @@ File: test_syntax.py Description: Tests syntax-based rules """ + from __future__ import annotations from conftest import check diff --git a/tests/lint/test_url.py b/tests/lint/test_url.py index 424b1a7..2874eff 100644 --- a/tests/lint/test_url.py +++ b/tests/lint/test_url.py @@ -2,6 +2,7 @@ File: test_url.py Description: Tests URL-based rules """ + from __future__ import annotations import pytest diff --git a/tests/test_lint.py b/tests/test_lint.py index 34bf1ad..8949500 100644 --- a/tests/test_lint.py +++ b/tests/test_lint.py @@ -2,6 +2,7 @@ File: test_.py Description: Tests linting infrastructure """ + from __future__ import annotations from pathlib import Path