From 7179abc47f16a377ee67996c9bbf1aebc589a114 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 5 Aug 2024 16:38:08 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- grayskull/strategy/abstract_strategy.py | 3 +-- grayskull/strategy/py_base.py | 7 ++++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/grayskull/strategy/abstract_strategy.py b/grayskull/strategy/abstract_strategy.py index 76b635d21..14a5951f6 100644 --- a/grayskull/strategy/abstract_strategy.py +++ b/grayskull/strategy/abstract_strategy.py @@ -4,5 +4,4 @@ class AbstractStrategy(metaclass=ABCMeta): @staticmethod @abstractmethod - def fetch_data(recipe, config, sections=None): - ... + def fetch_data(recipe, config, sections=None): ... diff --git a/grayskull/strategy/py_base.py b/grayskull/strategy/py_base.py index 5bc8452d4..45f3e4e5c 100644 --- a/grayskull/strategy/py_base.py +++ b/grayskull/strategy/py_base.py @@ -678,9 +678,10 @@ def download_sdist_pkg(sdist_url: str, dest: str, name: Optional[str] = None): response = requests.get(sdist_url, allow_redirects=True, stream=True, timeout=5) response.raise_for_status() total_size = int(response.headers.get("Content-length", 0)) - with manage_progressbar(max_value=total_size, prefix=f"{name} ") as bar, open( - dest, "wb" - ) as pkg_file: + with ( + manage_progressbar(max_value=total_size, prefix=f"{name} ") as bar, + open(dest, "wb") as pkg_file, + ): progress_val = 0 chunk_size = 512 for chunk_data in response.iter_content(chunk_size=chunk_size):