[downloader:http] support using a different method than GET (#2433)
by setting the '_http_method' metadata field for a file
This commit is contained in:
@@ -120,9 +120,9 @@ class HttpDownloader(DownloaderBase):
|
||||
# connect to (remote) source
|
||||
try:
|
||||
response = self.session.request(
|
||||
"GET", url, stream=True, headers=headers,
|
||||
timeout=self.timeout, verify=self.verify,
|
||||
proxies=self.proxies)
|
||||
kwdict.get("_http_method", "GET"), url,
|
||||
stream=True, headers=headers, timeout=self.timeout,
|
||||
verify=self.verify, proxies=self.proxies)
|
||||
except (ConnectionError, Timeout) as exc:
|
||||
msg = str(exc)
|
||||
continue
|
||||
|
||||
Reference in New Issue
Block a user