diff --git a/base-notebook/jupyter_notebook_config.py b/base-notebook/jupyter_notebook_config.py index e0c7d12a..ad41dafa 100644 --- a/base-notebook/jupyter_notebook_config.py +++ b/base-notebook/jupyter_notebook_config.py @@ -45,18 +45,13 @@ distinguished_name = req_distinguished_name "openssl", "req", "-new", - "-newkey", - "rsa:2048", - "-days", - "365", + "-newkey=rsa:2048", + "-days=365", "-nodes", "-x509", - "-subj", - "/C=XX/ST=XX/L=XX/O=generated/CN=generated", - "-keyout", - pem_file, - "-out", - pem_file, + "-subj=/C=XX/ST=XX/L=XX/O=generated/CN=generated", + f"-keyout={pem_file}", + f"-out={pem_file}", ] ) # Restrict access to the file diff --git a/conftest.py b/conftest.py index d13654bf..4c3056ad 100644 --- a/conftest.py +++ b/conftest.py @@ -97,7 +97,10 @@ def container(docker_client, image_name): Yields the container instance and kills it when the caller is done with it. """ container = TrackedContainer( - docker_client, image_name, detach=True, ports={"8888/tcp": 8888} + docker_client, + image_name, + detach=True, + ports={"8888/tcp": 8888}, ) yield container container.remove() diff --git a/scipy-notebook/test/data/matplotlib_1.py b/scipy-notebook/test/data/matplotlib_1.py index aab63ea7..57a93e70 100644 --- a/scipy-notebook/test/data/matplotlib_1.py +++ b/scipy-notebook/test/data/matplotlib_1.py @@ -15,7 +15,9 @@ fig, ax = plt.subplots() ax.plot(t, s) ax.set( - xlabel="time (s)", ylabel="voltage (mV)", title="About as simple as it gets, folks" + xlabel="time (s)", + ylabel="voltage (mV)", + title="About as simple as it gets, folks", ) ax.grid() # Note that the test can be run headless by checking if an image is produced diff --git a/tagging/create_manifests.py b/tagging/create_manifests.py index 03f984aa..b4064d82 100755 --- a/tagging/create_manifests.py +++ b/tagging/create_manifests.py @@ -20,7 +20,10 @@ MARKDOWN_LINE_BREAK = "
" def append_build_history_line( - short_image_name: str, owner: str, wiki_path: str, all_tags: List[str] + short_image_name: str, + owner: str, + wiki_path: str, + all_tags: List[str], ) -> None: logger.info("Appending build history line") diff --git a/tagging/taggers.py b/tagging/taggers.py index 392b2179..2f95d09b 100644 --- a/tagging/taggers.py +++ b/tagging/taggers.py @@ -25,7 +25,9 @@ def _get_env_variable(container, variable: str) -> str: def _get_pip_package_version(container, package: str) -> str: VERSION_PREFIX = "Version: " package_info = DockerRunner.run_simple_command( - container, cmd=f"pip show {package}", print_result=False + container, + cmd=f"pip show {package}", + print_result=False, ) version_line = package_info.split("\n")[1] assert version_line.startswith(VERSION_PREFIX) diff --git a/test/helpers.py b/test/helpers.py index b48ef70a..a36cab06 100644 --- a/test/helpers.py +++ b/test/helpers.py @@ -143,13 +143,15 @@ class CondaPackageHelper: continue current = min(inst_vs, key=CondaPackageHelper.semantic_cmp) newest = avail_vs[-1] - if avail_vs and current != newest: - if CondaPackageHelper.semantic_cmp( - current - ) < CondaPackageHelper.semantic_cmp(newest): - self.comparison.append( - {"Package": pkg, "Current": current, "Newest": newest} - ) + if ( + avail_vs + and current != newest + and CondaPackageHelper.semantic_cmp(current) + < CondaPackageHelper.semantic_cmp(newest) + ): + self.comparison.append( + {"Package": pkg, "Current": current, "Newest": newest} + ) return self.comparison @staticmethod