mirror of
https://github.com/YunoHost/package_check.git
synced 2024-09-03 20:06:20 +02:00
curl tests: unintended variable redefinition
This commit is contained in:
parent
675c6297e5
commit
6d96c6ad0e
1 changed files with 4 additions and 4 deletions
|
@ -212,14 +212,14 @@ def test(
|
||||||
for asset in assets_to_check:
|
for asset in assets_to_check:
|
||||||
if asset.startswith(f"https://{domain}"):
|
if asset.startswith(f"https://{domain}"):
|
||||||
asset = asset.replace(f"https://{domain}", "")
|
asset = asset.replace(f"https://{domain}", "")
|
||||||
code, _, effective_url = curl(
|
asset_code, _, effective_asset_url = curl(
|
||||||
f"https://{domain}", asset, use_cookies=cookies
|
f"https://{domain}", asset, use_cookies=cookies
|
||||||
)
|
)
|
||||||
if code != 200:
|
if asset_code != 200:
|
||||||
errors.append(
|
errors.append(
|
||||||
f"Asset https://{domain}{asset} (automatically derived from the page's html) answered with code {code}, expected 200? Effective url: {effective_url}"
|
f"Asset https://{domain}{asset} (automatically derived from the page's html) answered with code {asset_code}, expected 200? Effective url: {effective_asset_url}"
|
||||||
)
|
)
|
||||||
assets.append((domain + asset, code))
|
assets.append((domain + asset, asset_code))
|
||||||
|
|
||||||
return {
|
return {
|
||||||
"url": f"{base_url}{path}",
|
"url": f"{base_url}{path}",
|
||||||
|
|
Loading…
Add table
Reference in a new issue