Hi. Test suite for wget fails here on Test-metalink-http.py and Test-metalink- http-quoted.py
test-suite.log attached. -- Arkadiusz Miśkiewicz, arekm / ( maven.pl | pld-linux.org )
========================================= wget 1.19.2: testenv/test-suite.log ========================================= # TOTAL: 75 # PASS: 73 # SKIP: 0 # XFAIL: 0 # FAIL: 2 # XPASS: 0 # ERROR: 0 .. contents:: :depth: 2 FAIL: Test-metalink-http ======================== Setting --no-config (noconfig) to 1 Setting --metalink-over-http (metalinkoverhttp) to 1 Setting --preferred-location (preferredlocation) to uk DEBUG output created by Wget 1.19.2 on linux-gnu. Reading HSTS entries from /home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/Test-metalink-http.py-test/.wget-hsts URI encoding = 'ANSI_X3.4-1968' converted 'http://localhost:59326/test.meta' (ANSI_X3.4-1968) -> 'http://localhost:59326/test.meta' (UTF-8) Converted file name 'test.meta' (UTF-8) -> 'test.meta' (ANSI_X3.4-1968) --2017-10-29 13:41:59-- http://localhost:59326/test.meta Resolving localhost (localhost)... 127.0.0.1 Caching localhost => 127.0.0.1 Connecting to localhost (localhost)|127.0.0.1|:59326... connected. Created socket 3. Releasing 0x000000000257b840 (new refcount 1). ---request begin--- HEAD /test.meta HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: localhost:59326 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:41:59 GMT content-type: text/plain content-length: 13 link: <http://127.0.0.1:59326/File1_lowPref>; rel=duplicate; pri=9; geo=pl link: <http://this.is.no.good.example/File1_try2_badconnection>; rel =duplicate;pref; pri=7 link: <http://127.0.0.1:59326/Sig2.asc>; rel=describedby; type=application/pgp-signature link: <http://127.0.0.1:59326/Sig.asc>; rel=describedby; type=application/pgp-signature link: <http://127.0.0.1:59326/Sig.asc>; rel=describedby; type=application/pgp-signature link: <invalid_url>; rel=duplicate; pri=4 link: <http://127.0.0.1:59326/File1>; pri=1; pref link: <http://127.0.0.1:59326/File1>; rel=strange; pri=4 link: <http://127.0.0.1:59326/File1_try1_corrupted>; rel=duplicate; geo=su; pri=4; pref link: <http://127.0.0.1:59326/File1_badgeo>; rel =duplicate;pri=5 link: <http://127.0.0.1:59326/File1_try3_ok>; rel=duplicate; pri=5;geo=uk digest: SHA-256=j0o5IXK8oUh1b2xNIX5fgHFJITFO7oA98ZTuaIJ3p5I= ---response end--- 200 OK Registered socket 3 for persistent reuse. Checking for Metalink in HTTP response Processing Content-Type header... Content-Type: text/plain URL=http://127.0.0.1:59326/File1_lowPref rel=duplicate TYPE=http URL=http://this.is.no.good.example/File1_try2_badconnection rel=duplicate TYPE=http This resource has preference URL=http://127.0.0.1:59326/Sig2.asc rel=describedby URI encoding = 'ANSI_X3.4-1968' converted 'http://127.0.0.1:59326/Sig2.asc' (ANSI_X3.4-1968) -> 'http://127.0.0.1:59326/Sig2.asc' (UTF-8) Converted file name 'Sig2.asc' (UTF-8) -> 'Sig2.asc' (ANSI_X3.4-1968) --2017-10-29 13:41:59-- http://127.0.0.1:59326/Sig2.asc conaddr is: 127.0.0.1 Releasing 0x000000000257cc10 (new refcount 0). Deleting unused 0x000000000257cc10. Reusing existing connection to localhost:59326. Reusing fd 3. ---request begin--- GET /Sig2.asc HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: 127.0.0.1:59326 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 404 Not Found Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:41:59 GMT Connection: close Content-Type: text/html;charset=utf-8 Content-Length: 447 ---response end--- 404 Not Found URI content encoding = 'utf-8' Disabling further reuse of socket 3. Closed fd 3 2017-10-29 13:41:59 ERROR 404: Not Found. URL=http://127.0.0.1:59326/Sig.asc rel=describedby URI encoding = 'ANSI_X3.4-1968' converted 'http://127.0.0.1:59326/Sig.asc' (ANSI_X3.4-1968) -> 'http://127.0.0.1:59326/Sig.asc' (UTF-8) Converted file name 'Sig.asc' (UTF-8) -> 'Sig.asc' (ANSI_X3.4-1968) --2017-10-29 13:41:59-- http://127.0.0.1:59326/Sig.asc Connecting to 127.0.0.1:59326... connected. Created socket 4. Releasing 0x000000000257cd40 (new refcount 0). Deleting unused 0x000000000257cd40. ---request begin--- GET /Sig.asc HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: 127.0.0.1:59326 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:41:59 GMT content-type: text/plain content-length: 287 ---response end--- 200 OK Registered socket 4 for persistent reuse. Length: 287 [text/plain] Saving to: 'Sig.asc' Failed to set xattr 'user.xdg.origin.url'. 0K 100% 56.7M=0s 2017-10-29 13:41:59 (56.7 MB/s) - 'Sig.asc' saved [287/287] siglen=287 Signature (application/pgp-signature): -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (GNU/Linux) This is no valid signature. But it should be downloaded. The attempt to verify should fail but should not prevent a successful metalink resource retrieval (the sig failure should not be fatal). -----END PGP SIGNATURE----- URL=http://127.0.0.1:59326/Sig.asc rel=describedby This link header was not used for Metalink URL=invalid_url rel=duplicate Unsupported url scheme in invalid_url. Skipping resource. No rel value in Link header, skipping. URL=http://127.0.0.1:59326/File1 rel=strange This link header was not used for Metalink URL=http://127.0.0.1:59326/File1_try1_corrupted rel=duplicate TYPE=http This resource has preference URL=http://127.0.0.1:59326/File1_badgeo rel=duplicate TYPE=http URL=http://127.0.0.1:59326/File1_try3_ok rel=duplicate TYPE=http Metalink headers found. Switching to Metalink mode. Retrieving from Metalink 'http://localhost:59326/test.meta' Processing metalink file 'test.meta'... Metalink/HTTP --trust-server-names false --directory-prefix '' Counted metalink file 1 Planned metalink file 'test.meta' Trusted metalink file 'test.meta' Current metalink file 'test.meta' Cleaned metalink file 'test.meta' Secured metalink file 'test.meta' URI encoding = 'ANSI_X3.4-1968' converted 'http://127.0.0.1:59326/File1_try1_corrupted' (ANSI_X3.4-1968) -> 'http://127.0.0.1:59326/File1_try1_corrupted' (UTF-8) Storing to test.meta --2017-10-29 13:41:59-- http://127.0.0.1:59326/File1_try1_corrupted Reusing existing connection to 127.0.0.1:59326. Reusing fd 4. ---request begin--- GET /File1_try1_corrupted HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: 127.0.0.1:59326 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:41:59 GMT content-type: text/plain content-length: 27 ---response end--- 200 OK Length: 27 [text/plain] Saving to: 'test.meta' 0K 100% 688 =0.04s 2017-10-29 13:41:59 (688 B/s) - 'test.meta' saved [27/27] Computing size for 'test.meta' File size not declared. Skipping check. Computing checksum for 'test.meta' Declared hash: 8f4a392172bca148756f6c4d217e5f80714921314eee803df194ee688277a792 Computed hash: 780ad1249176a71151dbfe7a4d8b2625088f1cff3046b5e9cd7d74a3a7fcaf51 Checksum mismatch for file 'test.meta'. Removing 'test.meta'. URI encoding = 'ANSI_X3.4-1968' converted 'http://this.is.no.good.example/File1_try2_badconnection' (ANSI_X3.4-1968) -> 'http://this.is.no.good.example/File1_try2_badconnection' (UTF-8) Storing to test.meta --2017-10-29 13:41:59-- http://this.is.no.good.example/File1_try2_badconnection Resolving this.is.no.good.example (this.is.no.good.example)... failed: Device or resource busy. wget: unable to resolve host address 'this.is.no.good.example' URI encoding = 'ANSI_X3.4-1968' converted 'http://127.0.0.1:59326/File1_try3_ok' (ANSI_X3.4-1968) -> 'http://127.0.0.1:59326/File1_try3_ok' (UTF-8) Previous resource failed, continue with next resource. Storing to test.meta --2017-10-29 13:41:59-- http://127.0.0.1:59326/File1_try3_ok Reusing existing connection to 127.0.0.1:59326. Reusing fd 4. ---request begin--- GET /File1_try3_ok HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: 127.0.0.1:59326 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:41:59 GMT content-type: text/plain content-length: 24 ---response end--- 200 OK Length: 24 [text/plain] Saving to: 'test.meta' 0K 100% 601 =0.04s 2017-10-29 13:41:59 (601 B/s) - 'test.meta' saved [24/24] Computing size for 'test.meta' File size not declared. Skipping check. Computing checksum for 'test.meta' Declared hash: 8f4a392172bca148756f6c4d217e5f80714921314eee803df194ee688277a792 Computed hash: 8f4a392172bca148756f6c4d217e5f80714921314eee803df194ee688277a792 Checksum matches. Verifying signature 'application/pgp-signature': -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (GNU/Linux) This is no valid signature. But it should be downloaded. The attempt to verify should fail but should not prevent a successful metalink resource retrieval (the sig failure should not be fatal). -----END PGP SIGNATURE----- GPGME op_verify: No data URI encoding = 'ANSI_X3.4-1968' converted 'http://localhost:59326/File2' (ANSI_X3.4-1968) -> 'http://localhost:59326/File2' (UTF-8) Converted file name 'File2' (UTF-8) -> 'File2' (ANSI_X3.4-1968) --2017-10-29 13:42:00-- http://localhost:59326/File2 conaddr is: 127.0.0.1 Found localhost in host_name_addresses_map (0x257b840) Releasing 0x000000000257b840 (new refcount 1). Reusing existing connection to 127.0.0.1:59326. Reusing fd 4. ---request begin--- HEAD /File2 HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: localhost:59326 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:42:00 GMT content-type: text/plain content-length: 27 ---response end--- 200 OK Checking for Metalink in HTTP response Processing Content-Type header... Content-Type: text/plain No valid metalink references found. Could not find Metalink data in HTTP response. Downloading file using HTTP GET. --2017-10-29 13:42:01-- (try: 2) http://localhost:59326/File2 conaddr is: 127.0.0.1 Found localhost in host_name_addresses_map (0x257b840) Releasing 0x000000000257b840 (new refcount 1). Reusing existing connection to 127.0.0.1:59326. Reusing fd 4. ---request begin--- GET /File2 HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: localhost:59326 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:42:01 GMT content-type: text/plain content-length: 27 ---response end--- 200 OK Length: 27 [text/plain] Saving to: 'File2' 0K 100% 3.83M=0s 2017-10-29 13:42:01 (3.83 MB/s) - 'File2' saved [27/27] FINISHED --2017-10-29 13:42:01-- Total wall clock time: 1.9s Downloaded: 4 files, 365 in 0.08s (4.50 KB/s) Running Test Test-metalink-http.py Running Test Test-metalink-http.py /home/users/arekm/rpm/packages/wget/wget-1.19.2/src/wget --debug --no-config --metalink-over-http --preferred-location=uk http://localhost:59326/test.meta http://localhost:59326/File2 ['/home/users/arekm/rpm/packages/wget/wget-1.19.2/src/wget', '--debug', '--no-config', '--metalink-over-http', '--preferred-location=uk', 'http://localhost:59326/test.meta', 'http://localhost:59326/File2'] {'.gnupg/dirmngr.conf': {'content': '# dirmngr.conf - Options for Dirmngr\n# Written in 2015 by The GnuPG Project <https://gnupg.org>\n#\n# To the extent possible under law, the authors have dedicated all\n# copyright and related and neighboring rights to this file to the\n# public domain worldwide. This file is distributed without any\n# warranty. You should have received a copy of the CC0 Public Domain\n# Dedication along with this file. If not, see\n# <http://creativecommons.org/publicdomain/zero/1.0/>.\n#\n#\n# Unless you specify which option file to use (with the command line\n# option "--options filename"), the file ~/.gnupg/dirmngr.conf is used\n# by dirmngr. The file can contain any long options which are valid\n# for Dirmngr. If the first non white space character of a line is a\n# \'#\', the line is ignored. Empty lines are also ignored. See the\n# dirmngr man page or the manual for a list of options.\n#\n\n# --keyserver URI\n#\n# GPG can send and receive keys to and from a keyserver. These\n# servers can be HKP, Email, or LDAP (if GnuPG is built with LDAP\n# support).\n#\n# Example HKP keyservers:\n# hkp://keys.gnupg.net\n#\n# Example HKP keyserver using a Tor OnionBalance service\n# hkp://jirk5u4osbsr34t5.onion\n#\n# Example HKPS keyservers (see --hkp-cacert below):\n# hkps://hkps.pool.sks-keyservers.net\n#\n# Example LDAP keyservers:\n# ldap://pgp.surfnet.nl:11370\n#\n# Regular URL syntax applies, and you can set an alternate port\n# through the usual method:\n# hkp://keyserver.example.net:22742\n#\n# Most users just set the name and type of their preferred keyserver.\n# Note that most servers (with the notable exception of\n# ldap://keyserver.pgp.com) synchronize changes with each other. Note\n# also that a single server name may actually point to multiple\n# servers via DNS round-robin. hkp://keys.gnupg.net is an example of\n# such a "server", which spreads the load over a number of physical\n# servers.\n#\n# If exactly two keyservers are configured and only one is a Tor hidden\n# service, Dirmngr selects the keyserver to use depending on whether\n# Tor is locally running or not (on a per session base).\n\nkeyserver hkp://jirk5u4osbsr34t5.onion\nkeyserver hkp://keys.gnupg.net\n\n# --hkp-cacert FILENAME\n#\n# For the "hkps" scheme (keyserver access over TLS), Dirmngr needs to\n# know the root certificates for verification of the TLS certificates\n# used for the connection. Enter the full name of a file with the\n# root certificates here. If that file is in PEM format a ".pem"\n# suffix is expected. This option may be given multiple times to add\n# more root certificates. Tilde expansion is supported.\n\n#hkp-cacert /path/to/CA/sks-keyservers.netCA.pem\n'}, '.gnupg/gpg.conf': {'content': '# Options for GnuPG\n# Copyright 1998-2003, 2010 Free Software Foundation, Inc.\n# Copyright 1998-2003, 2010 Werner Koch\n#\n# This file is free software; as a special exception the author gives\n# unlimited permission to copy and/or distribute it, with or without\n# modifications, as long as this notice is preserved.\n#\n# This file is distributed in the hope that it will be useful, but\n# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the\n# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n#\n# Unless you specify which option file to use (with the command line\n# option "--options filename"), GnuPG uses the file ~/.gnupg/gpg.conf\n# by default.\n#\n# An options file can contain any long options which are available in\n# GnuPG. If the first non white space character of a line is a \'#\',\n# this line is ignored. Empty lines are also ignored.\n#\n# See the gpg man page for a list of options.\n\n\n# If you have more than 1 secret key in your keyring, you may want to\n# uncomment the following option and set your preferred keyid.\n\n#default-key 621CC013\n\n\n# If you do not pass a recipient to gpg, it will ask for one. Using\n# this option you can encrypt to a default key. Key validation will\n# not be done in this case. The second form uses the default key as\n# default recipient.\n\n#default-recipient some-user-id\n#default-recipient-self\n\n\n# Group names may be defined like this:\n# group mynames = paige 0x12345678 joe patti\n#\n# Any time "mynames" is a recipient (-r or --recipient), it will be\n# expanded to the names "paige", "joe", and "patti", and the key ID\n# "0x12345678". Note there is only one level of expansion - you\n# cannot make an group that points to another group. Note also that\n# if there are spaces in the recipient name, this will appear as two\n# recipients. In these cases it is better to use the key ID.\n\n#group mynames = paige 0x12345678 joe patti\n\n\n# GnuPG can automatically locate and retrieve keys as needed using\n# this option. This happens when encrypting to an email address (in\n# the "user@@example.com" form) and there are no keys matching\n# "u...@example.com" in the local keyring. This option takes any\n# number mechanisms which are tried in the given order. The default\n# is "--auto-key-locate local" to search for keys only in the local\n# key database. Uncomment the next line to locate a missing key using\n# two DNS based mechanisms.\n\n#auto-key-locate local,pka,dane\n\n\n# Common options for keyserver functions:\n# (Note that the --keyserver option has been moved to dirmngr.conf)\n#\n# include-disabled = when searching, include keys marked as "disabled"\n# on the keyserver (not all keyservers support this).\n#\n# no-include-revoked = when searching, do not include keys marked as\n# "revoked" on the keyserver.\n#\n# verbose = show more information as the keys are fetched.\n# Can be used more than once to increase the amount\n# of information shown.\n#\n# auto-key-retrieve = automatically fetch keys as needed from the keyserver\n# when verifying signatures or when importing keys that\n# have been revoked by a revocation key that is not\n# present on the keyring.\n#\n# no-include-attributes = do not include attribute IDs (aka "photo IDs")\n# when sending keys to the keyserver.\n\n#keyserver-options auto-key-retrieve\n\n\n# Uncomment this line to display photo user IDs in key listings and\n# when a signature from a key with a photo is verified.\n\n#show-photos\n\n\n# Use this program to display photo user IDs\n#\n# %i is expanded to a temporary file that contains the photo.\n# %I is the same as %i, but the file isn\'t deleted afterwards by GnuPG.\n# %k is expanded to the key ID of the key.\n# %K is expanded to the long OpenPGP key ID of the key.\n# %t is expanded to the extension of the image (e.g. "jpg").\n# %T is expanded to the MIME type of the image (e.g. "image/jpeg").\n# %f is expanded to the fingerprint of the key.\n# %% is %, of course.\n#\n# If %i or %I are not present, then the photo is supplied to the\n# viewer on standard input. If your platform supports it, standard\n# input is the best way to do this as it avoids the time and effort in\n# generating and then cleaning up a secure temp file.\n#\n# The default program is "xloadimage -fork -quiet -title \'KeyID 0x%k\' stdin"\n# On Mac OS X and Windows, the default is to use your regular JPEG image\n# viewer.\n#\n# Some other viewers:\n# photo-viewer "qiv %i"\n# photo-viewer "ee %i"\n# photo-viewer "display -title \'KeyID 0x%k\'"\n#\n# This one saves a copy of the photo ID in your home directory:\n# photo-viewer "cat > ~/photoid-for-key-%k.%t"\n#\n# Use your MIME handler to view photos:\n# photo-viewer "metamail -q -d -b -c %T -s \'KeyID 0x%k\' -f GnuPG"\n\n\n# Because some mailers change lines starting with "From " to ">From "\n# it is good to handle such lines in a special way when creating\n# cleartext signatures; all other PGP versions do it this way too.\n# To enable full OpenPGP compliance you may want to use this option.\n\n#no-escape-from-lines\n\n\n# Uncomment the following option to get rid of the copyright notice\n\n#no-greeting\n'}}127.0.0.1 - - [29/Oct/2017 13:41:59] "HEAD /test.meta HTTP/1.1" 200 - 127.0.0.1 - - [29/Oct/2017 13:41:59] code 404, message Not Found 127.0.0.1 - - [29/Oct/2017 13:41:59] "GET /Sig2.asc HTTP/1.1" 404 - 127.0.0.1 - - [29/Oct/2017 13:41:59] "GET /Sig.asc HTTP/1.1" 200 - 127.0.0.1 - - [29/Oct/2017 13:41:59] "GET /File1_try1_corrupted HTTP/1.1" 200 - 127.0.0.1 - - [29/Oct/2017 13:41:59] "GET /File1_try3_ok HTTP/1.1" 200 - 127.0.0.1 - - [29/Oct/2017 13:42:00] "HEAD /File2 HTTP/1.1" 200 - 127.0.0.1 - - [29/Oct/2017 13:42:01] "GET /File2 HTTP/1.1" 200 - Error: Extra files downloaded.. Traceback (most recent call last): File "./Test-metalink-http.py", line 124, in <module> err = http_test.begin () File "/home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/test/http_test.py", line 41, in begin self.do_test() File "/home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/test/base_test.py", line 187, in do_test self.post_hook_call() File "/home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/test/base_test.py", line 206, in post_hook_call self.hook_call(self.post_configs, 'Post Test Function') File "/home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/test/base_test.py", line 196, in hook_call conf.find_conf(conf_name)(conf_arg)(self) File "/home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/conf/expected_files.py", line 57, in __call__ raise TestFailed('Extra files downloaded.') exc.test_failed.TestFailed: Extra files downloaded. FAIL Test-metalink-http.py (exit status: 1) FAIL: Test-metalink-http-quoted =============================== Setting --no-config (noconfig) to 1 Setting --metalink-over-http (metalinkoverhttp) to 1 Setting --preferred-location (preferredlocation) to uk DEBUG output created by Wget 1.19.2 on linux-gnu. Reading HSTS entries from /home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/Test-metalink-http-quoted.py-test/.wget-hsts URI encoding = 'ANSI_X3.4-1968' converted 'http://localhost:46146/test.meta' (ANSI_X3.4-1968) -> 'http://localhost:46146/test.meta' (UTF-8) Converted file name 'test.meta' (UTF-8) -> 'test.meta' (ANSI_X3.4-1968) --2017-10-29 13:42:01-- http://localhost:46146/test.meta Resolving localhost (localhost)... 127.0.0.1 Caching localhost => 127.0.0.1 Connecting to localhost (localhost)|127.0.0.1|:46146... connected. Created socket 3. Releasing 0x0000000001db7850 (new refcount 1). ---request begin--- HEAD /test.meta HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: localhost:46146 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:42:01 GMT content-type: text/plain content-length: 13 link: <http://127.0.0.1:46146/File1_lowPref>; rel="duplicate"; pri="9"; geo="pl" link: <http://0.0.0.0/File1_try2_badconnection>; rel ="duplicate";pref; pri="7" link: <http://127.0.0.1:46146/Sig2.asc>; rel="describedby"; type="application/pgp-signature" link: <http://127.0.0.1:46146/Sig.asc>; rel="describedby"; type="application/pgp-signature" link: <http://127.0.0.1:46146/Sig.asc>; rel="describedby"; type="application/pgp-signature" link: <invalid_url>; rel="duplicate"; pri="4" link: <http://127.0.0.1:46146/File1>; pri="1"; pref link: <http://127.0.0.1:46146/File1>; rel="strange"; pri="4" link: <http://127.0.0.1:46146/File1_try1_corrupted>; rel="duplicate"; geo="su"; pri="4"; pref link: <http://127.0.0.1:46146/File1_badgeo>; rel ="duplicate";pri="5" link: <http://127.0.0.1:46146/File1_try3_ok>; rel='duplicate'; pri="5";geo="uk" digest: SHA-256='j0o5IXK8oUh1b2xNIX5fgHFJITFO7oA98ZTuaIJ3p5I=' ---response end--- 200 OK Registered socket 3 for persistent reuse. Checking for Metalink in HTTP response Processing Content-Type header... Content-Type: text/plain URL=http://127.0.0.1:46146/File1_lowPref rel=duplicate TYPE=http URL=http://0.0.0.0/File1_try2_badconnection rel=duplicate TYPE=http This resource has preference URL=http://127.0.0.1:46146/Sig2.asc rel=describedby URI encoding = 'ANSI_X3.4-1968' converted 'http://127.0.0.1:46146/Sig2.asc' (ANSI_X3.4-1968) -> 'http://127.0.0.1:46146/Sig2.asc' (UTF-8) Converted file name 'Sig2.asc' (UTF-8) -> 'Sig2.asc' (ANSI_X3.4-1968) --2017-10-29 13:42:01-- http://127.0.0.1:46146/Sig2.asc conaddr is: 127.0.0.1 Releasing 0x0000000001db9050 (new refcount 0). Deleting unused 0x0000000001db9050. Reusing existing connection to localhost:46146. Reusing fd 3. ---request begin--- GET /Sig2.asc HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: 127.0.0.1:46146 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 404 Not Found Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:42:01 GMT Connection: close Content-Type: text/html;charset=utf-8 Content-Length: 447 ---response end--- 404 Not Found URI content encoding = 'utf-8' Disabling further reuse of socket 3. Closed fd 3 2017-10-29 13:42:01 ERROR 404: Not Found. URL=http://127.0.0.1:46146/Sig.asc rel=describedby URI encoding = 'ANSI_X3.4-1968' converted 'http://127.0.0.1:46146/Sig.asc' (ANSI_X3.4-1968) -> 'http://127.0.0.1:46146/Sig.asc' (UTF-8) Converted file name 'Sig.asc' (UTF-8) -> 'Sig.asc' (ANSI_X3.4-1968) --2017-10-29 13:42:01-- http://127.0.0.1:46146/Sig.asc Connecting to 127.0.0.1:46146... connected. Created socket 4. Releasing 0x0000000001db9180 (new refcount 0). Deleting unused 0x0000000001db9180. ---request begin--- GET /Sig.asc HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: 127.0.0.1:46146 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:42:01 GMT content-type: text/plain content-length: 287 ---response end--- 200 OK Registered socket 4 for persistent reuse. Length: 287 [text/plain] Saving to: 'Sig.asc' Failed to set xattr 'user.xdg.origin.url'. 0K 100% 43.6M=0s 2017-10-29 13:42:01 (43.6 MB/s) - 'Sig.asc' saved [287/287] siglen=287 Signature (application/pgp-signature): -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (GNU/Linux) This is no valid signature. But it should be downloaded. The attempt to verify should fail but should not prevent a successful metalink resource retrieval (the sig failure should not be fatal). -----END PGP SIGNATURE----- URL=http://127.0.0.1:46146/Sig.asc rel=describedby This link header was not used for Metalink URL=invalid_url rel=duplicate Unsupported url scheme in invalid_url. Skipping resource. No rel value in Link header, skipping. URL=http://127.0.0.1:46146/File1 rel=strange This link header was not used for Metalink URL=http://127.0.0.1:46146/File1_try1_corrupted rel=duplicate TYPE=http This resource has preference URL=http://127.0.0.1:46146/File1_badgeo rel=duplicate TYPE=http URL=http://127.0.0.1:46146/File1_try3_ok rel=duplicate TYPE=http Metalink headers found. Switching to Metalink mode. Retrieving from Metalink 'http://localhost:46146/test.meta' Processing metalink file 'test.meta'... Metalink/HTTP --trust-server-names false --directory-prefix '' Counted metalink file 1 Planned metalink file 'test.meta' Trusted metalink file 'test.meta' Current metalink file 'test.meta' Cleaned metalink file 'test.meta' Secured metalink file 'test.meta' URI encoding = 'ANSI_X3.4-1968' converted 'http://127.0.0.1:46146/File1_try1_corrupted' (ANSI_X3.4-1968) -> 'http://127.0.0.1:46146/File1_try1_corrupted' (UTF-8) Storing to test.meta --2017-10-29 13:42:01-- http://127.0.0.1:46146/File1_try1_corrupted Reusing existing connection to 127.0.0.1:46146. Reusing fd 4. ---request begin--- GET /File1_try1_corrupted HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: 127.0.0.1:46146 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:42:01 GMT content-type: text/plain content-length: 27 ---response end--- 200 OK Length: 27 [text/plain] Saving to: 'test.meta' 0K 100% 721 =0.04s 2017-10-29 13:42:01 (721 B/s) - 'test.meta' saved [27/27] Computing size for 'test.meta' File size not declared. Skipping check. Computing checksum for 'test.meta' Declared hash: 8f4a392172bca148756f6c4d217e5f80714921314eee803df194ee688277a792 Computed hash: 780ad1249176a71151dbfe7a4d8b2625088f1cff3046b5e9cd7d74a3a7fcaf51 Checksum mismatch for file 'test.meta'. Removing 'test.meta'. URI encoding = 'ANSI_X3.4-1968' converted 'http://0.0.0.0/File1_try2_badconnection' (ANSI_X3.4-1968) -> 'http://0.0.0.0/File1_try2_badconnection' (UTF-8) Storing to test.meta --2017-10-29 13:42:01-- http://0.0.0.0/File1_try2_badconnection Connecting to 0.0.0.0:80... connected. Created socket 5. Releasing 0x0000000001dbe5a0 (new refcount 0). Deleting unused 0x0000000001dbe5a0. ---request begin--- GET /File1_try2_badconnection HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: 0.0.0.0 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 301 Moved Permanently Location: https://0.0.0.0/File1_try2_badconnection Content-Length: 0 Date: Sun, 29 Oct 2017 12:42:01 GMT Server: lighttpd/1.4.47 (PLD Linux) ---response end--- 301 Moved Permanently Disabling further reuse of socket 4. Closed fd 4 Registered socket 5 for persistent reuse. Location: https://0.0.0.0/File1_try2_badconnection [following] ] done. URI content encoding = None converted 'https://0.0.0.0/File1_try2_badconnection' (ANSI_X3.4-1968) -> 'https://0.0.0.0/File1_try2_badconnection' (UTF-8) --2017-10-29 13:42:01-- https://0.0.0.0/File1_try2_badconnection Certificates loaded: 196 Connecting to 0.0.0.0:443... connected. Created socket 4. Releasing 0x0000000002292810 (new refcount 0). Deleting unused 0x0000000002292810. The certificate's owner does not match hostname '0.0.0.0' URI encoding = 'ANSI_X3.4-1968' converted 'http://127.0.0.1:46146/File1_try3_ok' (ANSI_X3.4-1968) -> 'http://127.0.0.1:46146/File1_try3_ok' (UTF-8) Previous resource failed, continue with next resource. Storing to test.meta --2017-10-29 13:42:01-- http://127.0.0.1:46146/File1_try3_ok Connecting to 127.0.0.1:46146... connected. Created socket 4. Releasing 0x0000000002291e00 (new refcount 0). Deleting unused 0x0000000002291e00. ---request begin--- GET /File1_try3_ok HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: 127.0.0.1:46146 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:42:01 GMT content-type: text/plain content-length: 24 ---response end--- 200 OK Disabling further reuse of socket 5. Closed fd 5 Registered socket 4 for persistent reuse. Length: 24 [text/plain] Saving to: 'test.meta' 0K 100% 3.59M=0s 2017-10-29 13:42:01 (3.59 MB/s) - 'test.meta' saved [24/24] Computing size for 'test.meta' File size not declared. Skipping check. Computing checksum for 'test.meta' Declared hash: 8f4a392172bca148756f6c4d217e5f80714921314eee803df194ee688277a792 Computed hash: 8f4a392172bca148756f6c4d217e5f80714921314eee803df194ee688277a792 Checksum matches. Verifying signature 'application/pgp-signature': -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (GNU/Linux) This is no valid signature. But it should be downloaded. The attempt to verify should fail but should not prevent a successful metalink resource retrieval (the sig failure should not be fatal). -----END PGP SIGNATURE----- GPGME op_verify: No data URI encoding = 'ANSI_X3.4-1968' converted 'http://localhost:46146/File2' (ANSI_X3.4-1968) -> 'http://localhost:46146/File2' (UTF-8) Converted file name 'File2' (UTF-8) -> 'File2' (ANSI_X3.4-1968) --2017-10-29 13:42:02-- http://localhost:46146/File2 conaddr is: 127.0.0.1 Found localhost in host_name_addresses_map (0x1db7850) Releasing 0x0000000001db7850 (new refcount 1). Reusing existing connection to 127.0.0.1:46146. Reusing fd 4. ---request begin--- HEAD /File2 HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: localhost:46146 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:42:02 GMT content-type: text/plain content-length: 27 ---response end--- 200 OK Checking for Metalink in HTTP response Processing Content-Type header... Content-Type: text/plain No valid metalink references found. Could not find Metalink data in HTTP response. Downloading file using HTTP GET. --2017-10-29 13:42:03-- (try: 2) http://localhost:46146/File2 conaddr is: 127.0.0.1 Found localhost in host_name_addresses_map (0x1db7850) Releasing 0x0000000001db7850 (new refcount 1). Reusing existing connection to 127.0.0.1:46146. Reusing fd 4. ---request begin--- GET /File2 HTTP/1.1 User-Agent: Wget/1.19.2 (linux-gnu) Accept: */* Accept-Encoding: gzip Host: localhost:46146 Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Server: BaseHTTP/0.6 Python/3.6.3 Date: Sun, 29 Oct 2017 12:42:03 GMT content-type: text/plain content-length: 27 ---response end--- 200 OK Length: 27 [text/plain] Saving to: 'File2' 0K 100% 6.15M=0s 2017-10-29 13:42:03 (6.15 MB/s) - 'File2' saved [27/27] FINISHED --2017-10-29 13:42:03-- Total wall clock time: 1.9s Downloaded: 4 files, 365 in 0.04s (9.51 KB/s) Running Test Test-metalink-http-quoted.py Running Test Test-metalink-http-quoted.py /home/users/arekm/rpm/packages/wget/wget-1.19.2/src/wget --debug --no-config --metalink-over-http --preferred-location=uk http://localhost:46146/test.meta http://localhost:46146/File2 ['/home/users/arekm/rpm/packages/wget/wget-1.19.2/src/wget', '--debug', '--no-config', '--metalink-over-http', '--preferred-location=uk', 'http://localhost:46146/test.meta', 'http://localhost:46146/File2'] {'.gnupg/dirmngr.conf': {'content': '# dirmngr.conf - Options for Dirmngr\n# Written in 2015 by The GnuPG Project <https://gnupg.org>\n#\n# To the extent possible under law, the authors have dedicated all\n# copyright and related and neighboring rights to this file to the\n# public domain worldwide. This file is distributed without any\n# warranty. You should have received a copy of the CC0 Public Domain\n# Dedication along with this file. If not, see\n# <http://creativecommons.org/publicdomain/zero/1.0/>.\n#\n#\n# Unless you specify which option file to use (with the command line\n# option "--options filename"), the file ~/.gnupg/dirmngr.conf is used\n# by dirmngr. The file can contain any long options which are valid\n# for Dirmngr. If the first non white space character of a line is a\n# \'#\', the line is ignored. Empty lines are also ignored. See the\n# dirmngr man page or the manual for a list of options.\n#\n\n# --keyserver URI\n#\n# GPG can send and receive keys to and from a keyserver. These\n# servers can be HKP, Email, or LDAP (if GnuPG is built with LDAP\n# support).\n#\n# Example HKP keyservers:\n# hkp://keys.gnupg.net\n#\n# Example HKP keyserver using a Tor OnionBalance service\n# hkp://jirk5u4osbsr34t5.onion\n#\n# Example HKPS keyservers (see --hkp-cacert below):\n# hkps://hkps.pool.sks-keyservers.net\n#\n# Example LDAP keyservers:\n# ldap://pgp.surfnet.nl:11370\n#\n# Regular URL syntax applies, and you can set an alternate port\n# through the usual method:\n# hkp://keyserver.example.net:22742\n#\n# Most users just set the name and type of their preferred keyserver.\n# Note that most servers (with the notable exception of\n# ldap://keyserver.pgp.com) synchronize changes with each other. Note\n# also that a single server name may actually point to multiple\n# servers via DNS round-robin. hkp://keys.gnupg.net is an example of\n# such a "server", which spreads the load over a number of physical\n# servers.\n#\n# If exactly two keyservers are configured and only one is a Tor hidden\n# service, Dirmngr selects the keyserver to use depending on whether\n# Tor is locally running or not (on a per session base).\n\nkeyserver hkp://jirk5u4osbsr34t5.onion\nkeyserver hkp://keys.gnupg.net\n\n# --hkp-cacert FILENAME\n#\n# For the "hkps" scheme (keyserver access over TLS), Dirmngr needs to\n# know the root certificates for verification of the TLS certificates\n# used for the connection. Enter the full name of a file with the\n# root certificates here. If that file is in PEM format a ".pem"\n# suffix is expected. This option may be given multiple times to add\n# more root certificates. Tilde expansion is supported.\n\n#hkp-cacert /path/to/CA/sks-keyservers.netCA.pem\n'}, '.gnupg/gpg.conf': {'content': '# Options for GnuPG\n# Copyright 1998-2003, 2010 Free Software Foundation, Inc.\n# Copyright 1998-2003, 2010 Werner Koch\n#\n# This file is free software; as a special exception the author gives\n# unlimited permission to copy and/or distribute it, with or without\n# modifications, as long as this notice is preserved.\n#\n# This file is distributed in the hope that it will be useful, but\n# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the\n# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n#\n# Unless you specify which option file to use (with the command line\n# option "--options filename"), GnuPG uses the file ~/.gnupg/gpg.conf\n# by default.\n#\n# An options file can contain any long options which are available in\n# GnuPG. If the first non white space character of a line is a \'#\',\n# this line is ignored. Empty lines are also ignored.\n#\n# See the gpg man page for a list of options.\n\n\n# If you have more than 1 secret key in your keyring, you may want to\n# uncomment the following option and set your preferred keyid.\n\n#default-key 621CC013\n\n\n# If you do not pass a recipient to gpg, it will ask for one. Using\n# this option you can encrypt to a default key. Key validation will\n# not be done in this case. The second form uses the default key as\n# default recipient.\n\n#default-recipient some-user-id\n#default-recipient-self\n\n\n# Group names may be defined like this:\n# group mynames = paige 0x12345678 joe patti\n#\n# Any time "mynames" is a recipient (-r or --recipient), it will be\n# expanded to the names "paige", "joe", and "patti", and the key ID\n# "0x12345678". Note there is only one level of expansion - you\n# cannot make an group that points to another group. Note also that\n# if there are spaces in the recipient name, this will appear as two\n# recipients. In these cases it is better to use the key ID.\n\n#group mynames = paige 0x12345678 joe patti\n\n\n# GnuPG can automatically locate and retrieve keys as needed using\n# this option. This happens when encrypting to an email address (in\n# the "user@@example.com" form) and there are no keys matching\n# "u...@example.com" in the local keyring. This option takes any\n# number mechanisms which are tried in the given order. The default\n# is "--auto-key-locate local" to search for keys only in the local\n# key database. Uncomment the next line to locate a missing key using\n# two DNS based mechanisms.\n\n#auto-key-locate local,pka,dane\n\n\n# Common options for keyserver functions:\n# (Note that the --keyserver option has been moved to dirmngr.conf)\n#\n# include-disabled = when searching, include keys marked as "disabled"\n# on the keyserver (not all keyservers support this).\n#\n# no-include-revoked = when searching, do not include keys marked as\n# "revoked" on the keyserver.\n#\n# verbose = show more information as the keys are fetched.\n# Can be used more than once to increase the amount\n# of information shown.\n#\n# auto-key-retrieve = automatically fetch keys as needed from the keyserver\n# when verifying signatures or when importing keys that\n# have been revoked by a revocation key that is not\n# present on the keyring.\n#\n# no-include-attributes = do not include attribute IDs (aka "photo IDs")\n# when sending keys to the keyserver.\n\n#keyserver-options auto-key-retrieve\n\n\n# Uncomment this line to display photo user IDs in key listings and\n# when a signature from a key with a photo is verified.\n\n#show-photos\n\n\n# Use this program to display photo user IDs\n#\n# %i is expanded to a temporary file that contains the photo.\n# %I is the same as %i, but the file isn\'t deleted afterwards by GnuPG.\n# %k is expanded to the key ID of the key.\n# %K is expanded to the long OpenPGP key ID of the key.\n# %t is expanded to the extension of the image (e.g. "jpg").\n# %T is expanded to the MIME type of the image (e.g. "image/jpeg").\n# %f is expanded to the fingerprint of the key.\n# %% is %, of course.\n#\n# If %i or %I are not present, then the photo is supplied to the\n# viewer on standard input. If your platform supports it, standard\n# input is the best way to do this as it avoids the time and effort in\n# generating and then cleaning up a secure temp file.\n#\n# The default program is "xloadimage -fork -quiet -title \'KeyID 0x%k\' stdin"\n# On Mac OS X and Windows, the default is to use your regular JPEG image\n# viewer.\n#\n# Some other viewers:\n# photo-viewer "qiv %i"\n# photo-viewer "ee %i"\n# photo-viewer "display -title \'KeyID 0x%k\'"\n#\n# This one saves a copy of the photo ID in your home directory:\n# photo-viewer "cat > ~/photoid-for-key-%k.%t"\n#\n# Use your MIME handler to view photos:\n# photo-viewer "metamail -q -d -b -c %T -s \'KeyID 0x%k\' -f GnuPG"\n\n\n# Because some mailers change lines starting with "From " to ">From "\n# it is good to handle such lines in a special way when creating\n# cleartext signatures; all other PGP versions do it this way too.\n# To enable full OpenPGP compliance you may want to use this option.\n\n#no-escape-from-lines\n\n\n# Uncomment the following option to get rid of the copyright notice\n\n#no-greeting\n'}}127.0.0.1 - - [29/Oct/2017 13:42:01] "HEAD /test.meta HTTP/1.1" 200 - 127.0.0.1 - - [29/Oct/2017 13:42:01] code 404, message Not Found 127.0.0.1 - - [29/Oct/2017 13:42:01] "GET /Sig2.asc HTTP/1.1" 404 - 127.0.0.1 - - [29/Oct/2017 13:42:01] "GET /Sig.asc HTTP/1.1" 200 - 127.0.0.1 - - [29/Oct/2017 13:42:01] "GET /File1_try1_corrupted HTTP/1.1" 200 - 127.0.0.1 - - [29/Oct/2017 13:42:01] "GET /File1_try3_ok HTTP/1.1" 200 - 127.0.0.1 - - [29/Oct/2017 13:42:02] "HEAD /File2 HTTP/1.1" 200 - 127.0.0.1 - - [29/Oct/2017 13:42:03] "GET /File2 HTTP/1.1" 200 - Error: Extra files downloaded.. Traceback (most recent call last): File "./Test-metalink-http-quoted.py", line 124, in <module> err = http_test.begin () File "/home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/test/http_test.py", line 41, in begin self.do_test() File "/home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/test/base_test.py", line 187, in do_test self.post_hook_call() File "/home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/test/base_test.py", line 206, in post_hook_call self.hook_call(self.post_configs, 'Post Test Function') File "/home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/test/base_test.py", line 196, in hook_call conf.find_conf(conf_name)(conf_arg)(self) File "/home/users/arekm/rpm/packages/wget/wget-1.19.2/testenv/conf/expected_files.py", line 57, in __call__ raise TestFailed('Extra files downloaded.') exc.test_failed.TestFailed: Extra files downloaded. FAIL Test-metalink-http-quoted.py (exit status: 1)