Skip to content

Commit a20dd1c

Browse files
authored
Merge pull request #1333 from jupyterhub/pre-commit-ci-update-config
[pre-commit.ci] pre-commit autoupdate
2 parents 3221560 + f2c1cb7 commit a20dd1c

22 files changed

+37
-18
lines changed

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ repos:
2323

2424
# Autoformat: Python code
2525
- repo: https://github.com/psf/black
26-
rev: 23.12.1
26+
rev: 24.1.1
2727
hooks:
2828
- id: black
2929
args:

repo2docker/app.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
88
python -m repo2docker https://github.com/you/your-repo
99
"""
10+
1011
import getpass
1112
import json
1213
import logging

repo2docker/buildpacks/_r_base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
44
Keeping this in r.py would lead to cyclic imports.
55
"""
6+
67
from ..semver import parse_version as V
78

89

repo2docker/buildpacks/conda/__init__.py

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""BuildPack for conda environments"""
2+
23
import os
34
import re
45
import warnings
@@ -193,15 +194,15 @@ def get_build_script_files(self):
193194
raise ValueError(
194195
f"Python version {py_version} on {conda_platform} is not supported!"
195196
)
196-
files[
197-
f"conda/{lockfile_name}"
198-
] = self._kernel_environment_file = "/tmp/env/kernel-environment.lock"
197+
files[f"conda/{lockfile_name}"] = self._kernel_environment_file = (
198+
"/tmp/env/kernel-environment.lock"
199+
)
199200

200201
requirements_file_name = f"requirements.py-{py_version}.pip"
201202
if os.path.exists(os.path.join(HERE, requirements_file_name)):
202-
files[
203-
f"conda/{requirements_file_name}"
204-
] = self._kernel_requirements_file = "/tmp/env/kernel-requirements.txt"
203+
files[f"conda/{requirements_file_name}"] = (
204+
self._kernel_requirements_file
205+
) = "/tmp/env/kernel-requirements.txt"
205206
else:
206207
# server and kernel are the same
207208
server_py_version = py_version
@@ -216,15 +217,15 @@ def get_build_script_files(self):
216217
f"Python version {server_py_version} on {conda_platform} is not supported!"
217218
)
218219

219-
files[
220-
"conda/" + conda_frozen_name
221-
] = self._nb_environment_file = "/tmp/env/environment.lock"
220+
files["conda/" + conda_frozen_name] = self._nb_environment_file = (
221+
"/tmp/env/environment.lock"
222+
)
222223

223224
# add requirements.txt, if present
224225
if os.path.exists(os.path.join(HERE, pip_frozen_name)):
225-
files[
226-
"conda/" + pip_frozen_name
227-
] = self._nb_requirements_file = "/tmp/env/requirements.txt"
226+
files["conda/" + pip_frozen_name] = self._nb_requirements_file = (
227+
"/tmp/env/requirements.txt"
228+
)
228229

229230
files.update(super().get_build_script_files())
230231
return files

repo2docker/buildpacks/docker.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
"""Generates a variety of Dockerfiles based on an input matrix
22
"""
3+
34
import os
45

56
import docker

repo2docker/buildpacks/julia/julia_project.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""Generates a Dockerfile based on an input matrix for Julia"""
2+
23
import functools
34
import os
45
from functools import lru_cache

repo2docker/buildpacks/julia/julia_require.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ def get_assemble_scripts(self):
175175
r"""
176176
julia /tmp/install-repo-dependencies.jl "%(require)s"
177177
"""
178-
% {"require": require}
178+
% {"require": require},
179179
# TODO: For some reason, `rm`ing the file fails with permission denied.
180180
# && rm /tmp/install-repo-dependencies.jl
181181
)

repo2docker/buildpacks/legacy/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
88
Note: This buildpack has been deprecated.
99
"""
10+
1011
import logging
1112

1213

repo2docker/buildpacks/nix/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""BuildPack for nixpkgs environments"""
2+
23
import os
34
from functools import lru_cache
45

repo2docker/buildpacks/pipfile/__init__.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -173,9 +173,11 @@ def get_assemble_scripts(self):
173173
pipenv --clear \\
174174
)""".format(
175175
working_directory=working_directory,
176-
install_option="--ignore-pipfile"
177-
if os.path.exists(pipfile_lock)
178-
else "--skip-lock",
176+
install_option=(
177+
"--ignore-pipfile"
178+
if os.path.exists(pipfile_lock)
179+
else "--skip-lock"
180+
),
179181
),
180182
)
181183
)

0 commit comments

Comments
 (0)