Fix #7691: linkcheck: HEAD requests are not used for checking

sphinx.util.requests:head() sends a GET requests instead of HEAD...
This commit is contained in:
Takeshi KOMIYA 2020-07-10 22:12:00 +09:00
parent 2feb0b43b6
commit bd510c3be2
2 changed files with 2 additions and 1 deletions

View File

@ -33,6 +33,7 @@ Bugs fixed
* #7715: LaTeX: ``numfig_secnum_depth > 1`` leads to wrong figure links
* #7846: html theme: XML-invalid files were generated
* #7894: gettext: Wrong source info is shown when using rst_epilog
* #7691: linkcheck: HEAD requests are not used for checking
* #7869: :rst:role:`abbr` role without an explanation will show the explanation
from the previous abbr role
* C and C++, removed ``noindex`` directive option as it did

View File

@ -124,4 +124,4 @@ def head(url: str, **kwargs: Any) -> requests.Response:
headers.setdefault('User-Agent', useragent_header[0][1])
with ignore_insecure_warning(**kwargs):
return requests.get(url, **kwargs)
return requests.head(url, **kwargs)