build: downloader: silently ignores errors in some cases
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
StarlingX |
Fix Released
|
Medium
|
Romulo Jose Lyra Leite |
Bug Description
Brief Description
-----------------
Downloader silently ignores errors while downloading source packages in some cases. See logs below.
Severity
--------
Major
Steps to Reproduce
------------------
Difficult to reproduce - see logs below
Expected Behavior
------------------
Download errors must result in "downloader" exiting with a non-zero status
Actual Behavior
----------------
Downloader exits with 0 even if some downloads failed.
Reproducibility
---------------
Seen once
System Configuration
-------
N/A
Branch/Pull Time/Commit
-------
master/2023-10-13
Last Pass
---------
N/A
Timestamp/Logs
--------------
11:37:21 2023-10-13 15:37:21,658 - debrepack - INFO: [ Run - "dget -d http://
11:37:25 2023-10-13 15:37:24,874 - debrepack - DEBUG: stdout: dget: retrieving http://
11:37:25 2023-10-13 15:37:24,875 - debrepack - DEBUG: stdout: dget: using existing lldpd_1.
11:37:25 2023-10-13 15:37:24,875 - debrepack - DEBUG: stdout: dget: using existing lldpd_1.
11:37:25 2023-10-13 15:37:24,875 - debrepack - DEBUG: stdout: dget: retrieving http://
11:37:25 2023-10-13 15:37:24,875 - debrepack - DEBUG: stdout: lldpd_1.
11:37:25 2023-10-13 15:37:24,875 - debrepack - DEBUG: stdout: Good signature found
11:37:25 2023-10-13 15:37:24,875 - debrepack - DEBUG: stdout: validating lldpd_1.
11:37:25 2023-10-13 15:37:24,875 - debrepack - DEBUG: stdout: validating lldpd_1.
11:37:25 2023-10-13 15:37:24,875 - debrepack - DEBUG: stdout: All files validated successfully.
11:37:25 2023-10-13 15:37:24,875 - debrepack - DEBUG: stderr: % Total % Received % Xferd Average Speed Time Time Time Current
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: Dload Upload Total Spent Left Speed
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: 100 2473 100 2473 0 0 4639 0 --:--:-- --:--:-- --:--:-- 10991
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: % Total % Received % Xferd Average Speed Time Time Time Current
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: Dload Upload Total Spent Left Speed
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: curl: (22) The requested URL returned error: 404 Not Found
11:37:25 2023-10-13 15:37:24,876 - debrepack - DEBUG: stderr: dget: curl lldpd_1.
11:37:25 2023-10-13 15:37:24,877 - debrepack - DEBUG: stderr: skipping lldpd_1.
=======
This download failed: ttp://mirror.
Note: this file is no longer missing on starlingx mirror
Test Activity
-------------
N/A
Workaround
----------
N/A
tags: | added: stx.build |
Changed in starlingx: | |
status: | New → In Progress |
Changed in starlingx: | |
importance: | Undecided → Medium |
tags: | added: stx.10.0 |
Changed in starlingx: | |
assignee: | nobody → Romulo Jose Lyra Leite (rlyra) |
One way to reproduce it is to serve a dsc file from some local web server you have access to (eg, stx-tools build environment includes one). And remove one of the files mentioned in .dsc, so that curl returns the 404 error for it. In this case "dget" would falsely succeed.
To fix: in the downloader script, parse the .dsc file after downloading and make sure each file referenced therein is present locally.