Closed afh closed 1 year ago
It's manifesting as a HTML file that is downloaded instead of the actual source archive. Maybe this differs from the geographic region that the download is initiated; I reside in :eu:.
% curl -sLO https://tukaani.org/xz/xz-5.4.2.tar.gz
% file xz-5.4.2.tar.gz
xz-5.4.2.tar.gz: HTML document text, Unicode text, UTF-8 text, with very long lines (1113)
% head -5 xz-5.4.2.tar.gz
<!doctype html>
<html class="no-js" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
% curl -sLO -A wget/1.23.2 https://tukaani.org/xz/xz-5.4.2.tar.gz
% file xz-5.4.2.tar.gz
xz-5.4.2.tar.gz: gzip compressed data, max compression, from Unix, original size modulo 2^32 10905600
% tar ztf xz-5.4.2.tar.gz| head -5
xz-5.4.2/
xz-5.4.2/debug/
xz-5.4.2/debug/translation.bash
xz-5.4.2/debug/sync_flush.c
xz-5.4.2/debug/repeat.c
Apologies, I just realised that this is specific to my setup as I have set a custom user-agent set in ~/.curlrc
that I forgot about.
Would you agree that there is benefit in adding the --disable
option as the first parameter to curl? It causes curl to not read and use the config file. This would make all curl calls behave the same regardless on any customizations that users may have.
Ah! That explains it. In which case - yes - disabling any local config would definitely be worthwhile.
I'll update this PR accordingly, would you want a comment as a paper trail on this change too?
Also if I may ask: What were your personal highlights of PyCon?
from sourceforge.
I ran into issues with the Makefile when downloads xz, forward to and hosted on sourceforge, as the curl would download a HTML page instead of the source archive. Adding a wget user-agent fixed the issue for me.
PR Checklist: