common-workflow-language / common-workflow-language/schema_salad

need test for "check_exists does not follow redirects"

Open
#451 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
86
Forks
64
Avg merge
19h 24m
Merged PRs (30d)
19

Description

schema_salad.Fetcher.check_exists does a head() check on URLs. It turns out that the Python requests library does not follow redirects by default on HEAD requests. As a result, blanket redirects such as from http->https will be considered "success" even if it would be a 404 after the redirect.

The fix is to add the allow_redirects flag.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.