launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #29617
[Merge] ~cjwatson/lpbuildbot-worker:pre-commit-update into lpbuildbot-worker:main
Colin Watson has proposed merging ~cjwatson/lpbuildbot-worker:pre-commit-update into lpbuildbot-worker:main.
Commit message:
Update pre-commit hooks
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
For more details, see:
https://code.launchpad.net/~cjwatson/lpbuildbot-worker/+git/lpbuildbot-worker/+merge/436539
Includes fix for https://github.com/PyCQA/isort/issues/2077.
I excluded `charm/templates/buildslave.j2` from the `end-of-file-fixer` hook because Jinja tends to remove a single newline from the end of a template, and so we deliberately have an extra one so that the output file still ends with a newline.
All code changes were automatic.
--
Your team Launchpad code reviewers is requested to review the proposed merge of ~cjwatson/lpbuildbot-worker:pre-commit-update into lpbuildbot-worker:main.
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
index 1d63864..e655559 100644
--- a/.pre-commit-config.yaml
+++ b/.pre-commit-config.yaml
@@ -2,7 +2,7 @@
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
- rev: v4.1.0
+ rev: v4.4.0
hooks:
- id: check-added-large-files
- id: check-ast
@@ -10,16 +10,17 @@ repos:
- id: check-yaml
- id: debug-statements
- id: end-of-file-fixer
+ exclude: charm/templates/buildslave.j2
- id: trailing-whitespace
- repo: https://github.com/PyCQA/isort
- rev: 5.10.1
+ rev: 5.12.0
hooks:
- id: isort
- repo: https://github.com/psf/black
- rev: 22.1.0
+ rev: 22.12.0
hooks:
- id: black
- repo: https://github.com/PyCQA/flake8
- rev: 4.0.1
+ rev: 6.0.0
hooks:
- id: flake8
diff --git a/create-lp-tests-lxd b/create-lp-tests-lxd
index 19c259e..fdd54fe 100755
--- a/create-lp-tests-lxd
+++ b/create-lp-tests-lxd
@@ -194,7 +194,11 @@ def install_code(container, series, directory):
_exec(container, ["adduser", "buildbot", "sudo"])
_, gid = _exec(
container,
- ["python3", "-c", "import pwd; print(pwd.getpwnam('buildbot').pw_gid)"],
+ [
+ "python3",
+ "-c",
+ "import pwd; print(pwd.getpwnam('buildbot').pw_gid)",
+ ],
return_stdout=True,
)
_exec(