Skip to content

Commit

Permalink
Update pre-commit hooks to fix black in CI (#1380)
Browse files Browse the repository at this point in the history
* Update pre-commit hooks to fix black in CI

* Mark dummy token as security irrelevant
  • Loading branch information
rytilahti authored Apr 2, 2022
1 parent d26d877 commit f2d1346
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
14 changes: 7 additions & 7 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.0.1
rev: v4.1.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
Expand All @@ -12,19 +12,19 @@ repos:
- id: check-ast

- repo: https://github.com/psf/black
rev: 21.12b0
rev: 22.3.0
hooks:
- id: black
language_version: python3

- repo: https://github.com/pre-commit/mirrors-isort
rev: v5.9.3
rev: v5.10.1
hooks:
- id: isort
additional_dependencies: [toml]

- repo: https://github.com/PyCQA/doc8
rev: 0.10.1
rev: 0.11.1
hooks:
- id: doc8

Expand All @@ -41,20 +41,20 @@ repos:
additional_dependencies: [flake8-docstrings, flake8-bugbear, flake8-builtins, flake8-print, flake8-pytest-style, flake8-return, flake8-simplify, flake8-annotations]

- repo: https://github.com/PyCQA/bandit
rev: 1.7.1
rev: 1.7.4
hooks:
- id: bandit
args: [-x, 'tests', -x, '**/test_*.py']


- repo: https://github.com/pre-commit/mirrors-mypy
rev: v0.920
rev: v0.942
hooks:
- id: mypy
additional_dependencies: [types-attrs, types-PyYAML, types-requests, types-pytz, types-croniter]

- repo: https://github.com/asottile/pyupgrade
rev: v2.29.1
rev: v2.31.1
hooks:
- id: pyupgrade
args: ['--py37-plus']
2 changes: 1 addition & 1 deletion miio/tests/dummies.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def __init__(self, *args, **kwargs):
# TODO: ugly hack to check for pre-existing _model
if getattr(self, "_model", None) is None:
self._model = "dummy.model"
self.token = "ffffffffffffffffffffffffffffffff"
self.token = "ffffffffffffffffffffffffffffffff" # nosec
self.ip = "192.0.2.1"

def _reset_state(self):
Expand Down

0 comments on commit f2d1346

Please sign in to comment.