joergi / joergi/MagPiDownloader
Linux: Downloader downloads the same issue over multiple issues.
- Dominant language
- Shell
- Stars
- 92
- Forks
- 26
- Avg merge
- 3m
- Merged PRs (30d)
- 1
Description
Running Ubuntu 24.04 on an AMD 7840U;
Executed the following commands:
```
git clone https://github.com/joergi/MagPiDownloader.git
cd MagPiDownloader
cd linux_mac
bash magpi-issue-downloader.sh
```

Open opening the files with a file viewer (VSCode, native file explorer), I discovered that all issues I opened were the same file as the first issue downloaded. With the above commands, all issues downloaded were Issue 1.
Performing the command `bash magpi-issue-downloader.sh -f 42 -l 45` with a limited issue range, all issues downloaded were Issue 42.
Performing the command `bash magpi-special-issue-downloader.sh` did download all special issues as expected.
Attached is the dump for the second command, with the 42-45 range.
```
linux_mac git:(main) bash magpi-issue-downloader.sh -f 42 -l 45
https://magpi.raspberrypi.com
--2025-02-23 21:42:58-- https://magpi.raspberrypi.com/downloads/eyJfcmFpbHMiOnsiZGF0YSI6MTYxMiwicHVyIjoiYmxvYl9pZCJ9fQ==--59ce774711ff66de86dd6dca1fbf2150c381d127/MagPi42.pdf
Resolving magpi.raspberrypi.com (magpi.raspberrypi.com)... 3.33.249.164, 99.83.185.157, 15.197.253.240, ...
Connecting to magpi.raspberrypi.com (magpi.raspberrypi.com)|3.33.249.164|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://storage.raspberrypi.com/rptl-magazines-blobs/ub0jz5nvg9v805ca4r9redsipk4d?response-content-disposition=attachment%3B%20filename%3D%22MagPi42.pdf%22%3B%20filename%2A%3DUTF-8%27%27MagPi42.pdf&response-content-type=application%2Fpdf&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=magazines-production%2F20250224%2Feu-west-1%2Fs3%2Faws4_request&X-Amz-Date=20250224T054259Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=acf7d763e442b6b48d89758b084a051ea63cb35012a3eca20276f73fe0c1022c [following]
--2025-02-23 21:42:59-- https://storage.raspberrypi.com/rptl-magazines-blobs/ub0jz5nvg9v805ca4r9redsipk4d?response-content-disposition=attachment%3B%20filename%3D%22MagPi42.pdf%22%3B%20filename%2A%3DUTF-8%27%27MagPi42.pdf&response-content-type=application%2Fpdf&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=magazines-production%2F20250224%2Feu-west-1%2Fs3%2Faws4_request&X-Amz-Date=20250224T054259Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=acf7d763e442b6b48d89758b084a051ea63cb35012a3eca20276f73fe0c1022c
Resolving storage.raspberrypi.com (storage.raspberrypi.com)... 2a00:1098:82:47::b:1, 2a00:1098:84:1e0::e4:fd, 2a00:1098:86:7f::1:1, ...
Connecting to storage.raspberrypi.com (storage.raspberrypi.com)|2a00:1098:82:47::b:1|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 23531400 (22M) [application/pdf]
Saving to: ‘./../issues/MagPi_42.pdf’
./../issues/MagPi_42.pdf 100%[==============================================================>] 22.44M 2.42MB/s in 15s
2025-02-23 21:43:15 (1.51 MB/s) - ‘./../issues/MagPi_42.pdf’ saved [23531400/23531400]
--2025-02-23 21:43:15-- https://magpi.raspberrypi.com/downloads/eyJfcmFpbHMiOnsiZGF0YSI6MTYxMiwicHVyIjoiYmxvYl9pZCJ9fQ==--59ce774711ff66de86dd6dca1fbf2150c381d127/MagPi42.pdf
Resolving magpi.raspberrypi.com (magpi.raspberrypi.com)... 3.33.249.164, 15.197.253.240, 52.223.53.203, ...
Connecting to magpi.raspberrypi.com (magpi.raspberrypi.com)|3.33.249.164|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://storage.raspberrypi.com/rptl-magazines-blobs/ub0jz5nvg9v805ca4r9redsipk4d?response-content-disposition=attachment%3B%20filename%3D%22MagPi42.pdf%22%3B%20filename%2A%3DUTF-8%27%27MagPi42.pdf&response-content-type=application%2Fpdf&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=magazines-production%2F20250224%2Feu-west-1%2Fs3%2Faws4_request&X-Amz-Date=20250224T054315Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=4ae37ea2d8ad5b47ffc024f9e6124a1eab8bc8cd6a957ad2d59cfe6e9a285b87 [following]
--2025-02-23 21:43:15-- https://storage.raspberrypi.com/rptl-magazines-blobs/ub0jz5nvg9v805ca4r9redsipk4d?response-content-disposition=attachment%3B%20filename%3D%22MagPi42.pdf%22%3B%20filename%2A%3DUTF-8%27%27MagPi42.pdf&response-content-type=application%2Fpdf&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=magazines-production%2F20250224%2Feu-west-1%2Fs3%2Faws4_request&X-Amz-Date=20250224T054315Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=4ae37ea2d8ad5b47ffc024f9e6124a1eab8bc8cd6a957ad2d59cfe6e9a285b87
Resolving storage.raspberrypi.com (storage.raspberrypi.com)... 2a00:1098:80:56::e:1, 2a00:1098:86:7f::1:1, 2a00:1098:82:47::b:1, ...
Connecting to storage.raspberrypi.com (storage.raspberrypi.com)|2a00:1098:80:56::e:1|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 23531400 (22M) [application/pdf]
Saving to: ‘./../issues/MagPi_43.pdf’
./../issues/MagPi_43.pdf 100%[==============================================================>] 22.44M 9.74MB/s in 2.3s
2025-02-23 21:43:18 (9.74 MB/s) - ‘./../issues/MagPi_43.pdf’ saved [23531400/23531400]
--2025-02-23 21:43:18-- https://magpi.raspberrypi.com/downloads/eyJfcmFpbHMiOnsiZGF0YSI6MTYxMiwicHVyIjoiYmxvYl9pZCJ9fQ==--59ce774711ff66de86dd6dca1fbf2150c381d127/MagPi42.pdf
Resolving magpi.raspberrypi.com (magpi.raspberrypi.com)... 15.197.253.240, 99.83.185.157, 52.223.53.203, ...
Connecting to magpi.raspberrypi.com (magpi.raspberrypi.com)|15.197.253.240|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://storage.raspberrypi.com/rptl-magazines-blobs/ub0jz5nvg9v805ca4r9redsipk4d?response-content-disposition=attachment%3B%20filename%3D%22MagPi42.pdf%22%3B%20filename%2A%3DUTF-8%27%27MagPi42.pdf&response-content-type=application%2Fpdf&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=magazines-production%2F20250224%2Feu-west-1%2Fs3%2Faws4_request&X-Amz-Date=20250224T054319Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=42fe91ed04c1e8b316397e5315036db8f351f57cba38d3cdcfd8b4c1ffb5e49e [following]
--2025-02-23 21:43:19-- https://storage.raspberrypi.com/rptl-magazines-blobs/ub0jz5nvg9v805ca4r9redsipk4d?response-content-disposition=attachment%3B%20filename%3D%22MagPi42.pdf%22%3B%20filename%2A%3DUTF-8%27%27MagPi42.pdf&response-content-type=application%2Fpdf&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=magazines-production%2F20250224%2Feu-west-1%2Fs3%2Faws4_request&X-Amz-Date=20250224T054319Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=42fe91ed04c1e8b316397e5315036db8f351f57cba38d3cdcfd8b4c1ffb5e49e
Resolving storage.raspberrypi.com (storage.raspberrypi.com)... 2a00:1098:84:1e0::e4:fd, 2a00:1098:80:56::e:1, 2a00:1098:86:7f::1:1, ...
Connecting to storage.raspberrypi.com (storage.raspberrypi.com)|2a00:1098:84:1e0::e4:fd|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 23531400 (22M) [application/pdf]
Saving to: ‘./../issues/MagPi_44.pdf’
./../issues/MagPi_44.pdf 100%[==============================================================>] 22.44M 6.76MB/s in 3.9s
2025-02-23 21:43:24 (5.80 MB/s) - ‘./../issues/MagPi_44.pdf’ saved [23531400/23531400]
--2025-02-23 21:43:24-- https://magpi.raspberrypi.com/downloads/eyJfcmFpbHMiOnsiZGF0YSI6MTYxMiwicHVyIjoiYmxvYl9pZCJ9fQ==--59ce774711ff66de86dd6dca1fbf2150c381d127/MagPi42.pdf
Resolving magpi.raspberrypi.com (magpi.raspberrypi.com)... 99.83.185.157, 3.33.249.164, 15.197.253.240, ...
Connecting to magpi.raspberrypi.com (magpi.raspberrypi.com)|99.83.185.157|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://storage.raspberrypi.com/rptl-magazines-blobs/ub0jz5nvg9v805ca4r9redsipk4d?response-content-disposition=attachment%3B%20filename%3D%22MagPi42.pdf%22%3B%20filename%2A%3DUTF-8%27%27MagPi42.pdf&response-content-type=application%2Fpdf&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=magazines-production%2F20250224%2Feu-west-1%2Fs3%2Faws4_request&X-Amz-Date=20250224T054325Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=0f2d203a49b74ab9b98e6ac3e928e7579de7b756e3e90159c5cecc68ae284b20 [following]
--2025-02-23 21:43:25-- https://storage.raspberrypi.com/rptl-magazines-blobs/ub0jz5nvg9v805ca4r9redsipk4d?response-content-disposition=attachment%3B%20filename%3D%22MagPi42.pdf%22%3B%20filename%2A%3DUTF-8%27%27MagPi42.pdf&response-content-type=application%2Fpdf&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=magazines-production%2F20250224%2Feu-west-1%2Fs3%2Faws4_request&X-Amz-Date=20250224T054325Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=0f2d203a49b74ab9b98e6ac3e928e7579de7b756e3e90159c5cecc68ae284b20
Resolving storage.raspberrypi.com (storage.raspberrypi.com)... 2a00:1098:82:47::b:1, 2a00:1098:84:1e0::e4:fd, 2a00:1098:86:7f::1:1, ...
Connecting to storage.raspberrypi.com (storage.raspberrypi.com)|2a00:1098:82:47::b:1|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 23531400 (22M) [application/pdf]
Saving to: ‘./../issues/MagPi_45.pdf’
./../issues/MagPi_45.pdf 100%[==============================================================>] 22.44M 9.88MB/s in 2.3s
2025-02-23 21:43:28 (9.88 MB/s) - ‘./../issues/MagPi_45.pdf’ saved [23531400/23531400]
```
On a brief inspection, the URL that the request points to is indeed not updated `https://storage.raspberrypi.com/rptl-magazines-blobs/ub0jz5nvg9v805ca4r9redsipk4d?response-content-disposition=attachment%3B%20filename%3D%22MagPi42.pdf%22%3B%20filename%2A%3DUTF-8%27%27MagPi42.pdf&response-content-type=application%2Fpdf&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=magazines-production%2F20250224%2Feu-west-1%2Fs3%2Faws4_request&X-Amz-Date=20250224T054315Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=4ae37ea2d8ad5b47ffc024f9e6124a1eab8bc8cd6a957ad2d59cfe6e9a285b87`
> attachment%3B%20filename%3D%22MagPi42.pdf
Haven't yet looked at the script.
Contributor guide
Assessment
This issue has not been assessed yet.