From e83817ca4eab4ebacd2e37c582e7f0dc959914b0 Mon Sep 17 00:00:00 2001 From: Will Greenberg Date: Tue, 30 Apr 2024 12:52:48 -0700 Subject: [PATCH] certbot-ci: appease the linter --- .../certbot_integration_tests/utils/pebble_artifacts.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/certbot-ci/certbot_integration_tests/utils/pebble_artifacts.py b/certbot-ci/certbot_integration_tests/utils/pebble_artifacts.py index bec2e7bb9..de98d1697 100644 --- a/certbot-ci/certbot_integration_tests/utils/pebble_artifacts.py +++ b/certbot-ci/certbot_integration_tests/utils/pebble_artifacts.py @@ -37,10 +37,11 @@ def fetch(workspace: str, http_01_port: int = DEFAULT_HTTP_01_PORT) -> Tuple[str def _fetch_asset(asset: str, assets_path: str) -> str: - asset_path = os.path.join(assets_path, '{0}_{1}_linux-amd64'.format(asset, PEBBLE_VERSION)) + platform = 'linux-amd64' + base_url = 'https://github.com/letsencrypt/pebble/releases/download' + asset_path = os.path.join(assets_path, f'{asset}_{PEBBLE_VERSION}_{platform}') if not os.path.exists(asset_path): - asset_url = ('https://github.com/letsencrypt/pebble/releases/download/{0}/{1}-linux-amd64.zip' - .format(PEBBLE_VERSION, asset)) + asset_url = f'{base_url}/{PEBBLE_VERSION}/{asset}-{platform}.zip' response = requests.get(asset_url, timeout=30) response.raise_for_status() asset_data = _unzip_asset(response.content, asset)