Browse Source

pipeline: enable pylint_import_requirements explicitly

> tests/test_switchbot.py:1:0: W6668: install_requires: 'PySwitchbot' does not seem to be used (unused-requirement)
https://github.com/fphammerle/switchbot-mqtt/runs/655909147
Fabian Peter Hammerle 3 years ago
parent
commit
663ae02dff
2 changed files with 2 additions and 9 deletions
  1. 2 5
      .github/workflows/python.yml
  2. 0 4
      .pylintrc

+ 2 - 5
.github/workflows/python.yml

@@ -34,12 +34,9 @@ jobs:
            pipenv install --dev importlib-metadata;
            fi
     - run: pipenv graph
-    - run: pipenv run pylint switchbot_mqtt
+    - run: pipenv run pylint --load-plugins=pylint_import_requirements switchbot_mqtt
     # https://github.com/PyCQA/pylint/issues/352
-    # disable parse-error due to:
-    # > tests/resources/__init__.py:1:0: F0010: error while code parsing: Unable to load file tests/resources/__init__.py:
-    # > [Errno 2] No such file or directory: 'tests/resources/__init__.py' (parse-error)
-    - run: pipenv run pylint --disable=missing-requirement --disable=parse-error tests/*
+    - run: pipenv run pylint tests/*
     - run: pipenv run mypy switchbot_mqtt tests
     - run: pipenv run pytest --cov=switchbot_mqtt --cov-report=term-missing --cov-fail-under=100
     - run: pipenv run black --check .

+ 0 - 4
.pylintrc

@@ -1,7 +1,3 @@
-[MASTER]
-
-load-plugins=pylint_import_requirements
-
 [MESSAGE CONTROL]
 
 disable=bad-continuation, # black