You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Execution of the "Quickstart Tutorial" fails (with Tag v0.12.2 and current develop HEAD c63b7f3). It reports that the file 2.root.json cannot be found.
Current behavior:
Execution of the "Quickstart Tutorial" fails (with Tag v0.12.2 and current develop HEAD c63b7f3) with following message:
Could not download URL: 'http://localhost:8001/metadata/2.root.json'
Traceback (most recent call last):
File "/path/to/tuf/download.py", line 264, in _download_file
response.raise_for_status()
File "/usr/lib/python3/dist-packages/requests/models.py", line 940, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 404 Client Error: File not found for url: http://localhost:8001/metadata/2.root.json
Update failed from http://localhost:8001/metadata/2.root.json.
Traceback (most recent call last):
File "/path/to/tuf/client/updater.py", line 1507, in _get_metadata_file
upperbound_filelength)
File "/path/to/tuf/download.py", line 150, in unsafe_download
return _download_file(url, required_length, STRICT_REQUIRED_LENGTH=False)
File "/path/to/tuf/download.py", line 264, in _download_file
response.raise_for_status()
File "/usr/lib/python3/dist-packages/requests/models.py", line 940, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 404 Client Error: File not found for url: http://localhost:8001/metadata/2.root.json
Failed to update '2.root.json' from all mirrors: {'http://localhost:8001/metadata/2.root.json': HTTPError('404 Client Error: File not found for url: http://localhost:8001/metadata/2.root.json')}
ERROR:root:HTTP error for root version 2
Traceback (most recent call last):
File "/path/to/tuf/client/updater.py", line 1150, in _update_root_metadata
version=next_version)
File "/path/to/tuf/client/updater.py", line 1786, in _update_metadata
upperbound_filelength, version)
File "/path/to/tuf/client/updater.py", line 1602, in _get_metadata_file
raise tuf.exceptions.NoWorkingMirrorError(file_mirror_errors)
tuf.exceptions.NoWorkingMirrorError: No working mirror was found:
'localhost:8001': HTTPError('404 Client Error: File not found for url: http://localhost:8001/metadata/2.root.json')
INFO:tuf.download:Downloading: 'http://localhost:8001/metadata/timestamp.json'
INFO:tuf.download:Downloaded 557 bytes out of an upper limit of 16384 bytes.
INFO:tuf.download:Downloading: 'http://localhost:8001/metadata/snapshot.json'
INFO:tuf.download:Downloaded 472 bytes out of an upper limit of 2000000 bytes.
INFO:tuf.download:Downloading: 'http://localhost:8001/metadata/targets.json'
INFO:tuf.download:Downloaded 735 bytes out of an upper limit of 5000000 bytes.
INFO:tuf.client.updater:'targets.json' up-to-date.
INFO:tuf.client.updater:'targets.json' up-to-date.
INFO:tuf.download:Downloading: 'http://localhost:8001/targets/testfile'
INFO:tuf.download:Downloaded 10 bytes out of the expected 10 bytes.
INFO:tuf.client.updater:The file's sha256 hash is correct: 114811b0b8998cb9853a5379598021410feddf69bb2ee7b7145d052a7e9b5d45
INFO:tuf.client.updater:The file's sha512 hash is correct: 9484ec641bd36078436a993000045bbc380f77d8897e9dcc1b784c10642abe31f5469b9b6c31afa3a286abb4d0ce618468043883bce231c99aa984ea9ff14a64
Expected behavior:
The Quickstart Tutorial works without errors.
The text was updated successfully, but these errors were encountered:
Thanks for the report @Silvanoc. This is a known issue (see #983) where the logging in TUF is reporting errors despite things proceeding as expected.
You can see from the last four lines of INFO output that the file was downloaded and verified as matching the hashes in the targets metadata:
INFO:tuf.download:Downloading: 'http://localhost:8001/targets/testfile'
INFO:tuf.download:Downloaded 10 bytes out of the expected 10 bytes.
INFO:tuf.client.updater:The file's sha256 hash is correct: 114811b0b8998cb9853a5379598021410feddf69bb2ee7b7145d052a7e9b5d45
INFO:tuf.client.updater:The file's sha512 hash is correct: 9484ec641bd36078436a993000045bbc380f77d8897e9dcc1b784c10642abe31f5469b9b6c31afa3a286abb4d0ce618468043883bce231c99aa984ea9ff14a64
Description of issue or feature request:
Execution of the "Quickstart Tutorial" fails (with Tag
v0.12.2
and currentdevelop
HEAD c63b7f3). It reports that the file2.root.json
cannot be found.Current behavior:
Execution of the "Quickstart Tutorial" fails (with Tag
v0.12.2
and currentdevelop
HEAD c63b7f3) with following message:Expected behavior:
The Quickstart Tutorial works without errors.
The text was updated successfully, but these errors were encountered: