From 33d048d11b80304a95b0bf25cd4947e24d772b5d Mon Sep 17 00:00:00 2001 From: junos Date: Thu, 24 Dec 2020 14:38:52 +0100 Subject: [PATCH] Remove pre-commit hooks. Because PyCharm does not activate conda environment, this doesn't work properly. I left in the formatting tools (black, isort etc.) which can be used manually. --- .pre-commit-config.yaml | 16 ---------------- config/environment.yml | 1 - config/setup.cfg | 19 ------------------- test/config.py | 5 +---- 4 files changed, 1 insertion(+), 40 deletions(-) delete mode 100644 .pre-commit-config.yaml delete mode 100644 config/setup.cfg diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml deleted file mode 100644 index 6552856..0000000 --- a/.pre-commit-config.yaml +++ /dev/null @@ -1,16 +0,0 @@ -repos: - - repo: local - hooks: - - id: isort - name: isort - stages: [commit] - language: system - entry: isort - types: [python] - - - id: black - name: black - stages: [commit] - language: system - entry: black - types: [python] \ No newline at end of file diff --git a/config/environment.yml b/config/environment.yml index 5f6df2a..2c9d069 100644 --- a/config/environment.yml +++ b/config/environment.yml @@ -8,6 +8,5 @@ dependencies: - isort - flake8 - mypy - - pre-commit - psycopg2 - python-dotenv \ No newline at end of file diff --git a/config/setup.cfg b/config/setup.cfg deleted file mode 100644 index 37105c9..0000000 --- a/config/setup.cfg +++ /dev/null @@ -1,19 +0,0 @@ -[mypy] -files=best_practices,test -ignore_missing_imports=true -#TODO We are assuming that our code lives in the best_practices package for the following config. - - -[flake8] -ignore = E203, E266, E501, W503 -max-line-length = 88 -max-complexity = 18 -select = B,C,E,F,W,T4 - - -[isort] -multi_line_output=3 -include_trailing_comma=True -force_grid_wrap=0 -use_parentheses=True -line_length=88 \ No newline at end of file diff --git a/test/config.py b/test/config.py index 6147aa4..991376f 100644 --- a/test/config.py +++ b/test/config.py @@ -4,10 +4,7 @@ from dotenv import load_dotenv load_dotenv() + class ConfigProject(unittest.TestCase): def test_env_variables(self): self.assertIsNotNone(os.getenv("DB_PASSWORD")) - - -if __name__ == '__main__': - unittest.main() \ No newline at end of file