Avainsanana wget

Some wget output shown despite -qq

25. syyskuuta 2020 klo 17.36
Sijainti: Vianhallintajärjestelmät: Github
Avainsanat: wget

The version I’m using:

yle-dl 20200807 with wget 1.20.3 (in Ubuntu 20.04)

Steps to reproduce:

$ /usr/local/bin/yle-dl -qq --backend wget --wget /usr/bin/wget https://areena.yle.fi/1-50636796

What I expect to happen:

For the download to complete without any output in the terminal.

What happens instead:

The command outputs this line (which to me seems like is from wget):

2020-09-25 17:25:27 URL:https://ylekaod-a.akamaihd.net/s/p/1955031/sp/195503100/serveFlavor/entryId/1_ldivkmki/v/11/ev/2/flavorId/1_b6wtzy8f/name/a.mp3?__hdnea__=st=1601043921~exp=1601058321~acl=/s/p/1955031/sp/195503100/serveFlavor/entryId/1_ldivkmki/v/11/ev/2/flavorId/1_b6wtzy8f/name/a.mp3*~hmac=bddcd801a98d3560990842beccee528da3861e588cf3438880642267aab03dc4 [21436961/21436961] -> "Kaverin puolesta kyselen: Koppuraiset kalsarit ja muita deittimokia-2020-09-25T06:45.mp3" [1]

Vastaa viestiin sen kontekstissa (Github)

”No data received”: UA spoofing required for download to work

5. heinäkuuta 2019 klo 15.12
Sijainti: Vianhallintajärjestelmät: Github
Avainsanat: wget

I’m using yle-dl 20190614 with GNU Wget 1.19.4 in Ubuntu 18.04.

When trying to download this (and so far this is the only example I’ve come across): https://areena.yle.fi/1-50192791

Wget fails like this:

Resolving ylekaod-a.akamaihd.net (ylekaod-a.akamaihd.net)... 62.183.170.32, 62.183.170.35
Connecting to ylekaod-a.akamaihd.net (ylekaod-a.akamaihd.net)|62.183.170.32|:443... connected.
HTTP request sent, awaiting response... No data received.
Retrying.

It tries a few more times, then gives up. I’m attaching --verbose log (with LC_ALL=C).

Workaround

I took the wget command from –verbose output and added UA spoofing with -U 'Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1312.27 Safari/537.17', and with the resulting command I was able to download the file.

Vastaa viestiin sen kontekstissa (Github)

Related but (FWICT) not precisely the same issues upstream

20. huhtikuuta 2018 klo 15.04
Sijainti: Vianhallintajärjestelmät: Launchpad
Avainsanat: wget

Red Hat issue: https://bugzilla.redhat.com/show_bug.cgi?id=1484411 ”Running wget with -O and -q in the background yields a file wget-log”

Related but (FWICT) not precisely the same issues upstream:

* https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=888691 ”wget -b produces empty wget-log file”
* https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=874590 ”wget: creates log file when run in the background”, forwarded to https://savannah.gnu.org/bugs/?51181 ”Unexpected ”Redirecting output to ’wget-log’.””

Vastaa viestiin sen kontekstissa (Launchpad)

wget-log file created despite -q when run in background with &

20. huhtikuuta 2018 klo 14.58
Sijainti: Vianhallintajärjestelmät: Launchpad
Avainsanat: wget

== Steps to reproduce ==
`wget -q https://www.google.com/ &`

== What happens ==
wget says it’s ”Redirecting output to ’wget-log'” and creates an empty wget-log file in the current directory.

== What I expect to happen ==
No wget-log file to be created.

== Details ==
Wget has a -b (–background) option, for which the man page says: ”If no output file is specified via the -o, output is redirected to wget-log.” There’s also the -q (–quiet) option, for which the man page says: ”Turn off Wget’s output.”

When both are given, wget goes to background, and no wget-log gets created, as expected.

When only -b is given, wget goes to background, and creates wget-log, also as expected.

When only -q is given, wget runs in the foreground, and no wget-log is created, still as expected.

When only -q is given, but & is added to the end of the command line, wget goes to background, but also creates wget-log, which I find unexpected (and inconsistent).

Vastaa viestiin sen kontekstissa (Launchpad)