Using balena os download should be consistent across ESR releases
Actual Behavior
The behavior of the balena os download command is inconsistent now with the introduction of unified OS releases
balena os download raspberrypi4-64 --version 2021.10.2 (pre unification) fails if not given a suffix (I would expect it to default to prod maybe?)
balena os download raspberrypi4-64 --version 2022.1.1 (post unification) fails if given a suffix (probably related to the introduction of the --dev flag to balena os configure)
The command feedback is not helpful either as when downloading an older version the CLI will show a hint about adding adding the suffix
** Hint: some OS releases require specifying the full OS version including
** the '.prod' or '.dev' suffix, e.g. '--version 2021.10.2.prod'
while on the newer version there is no hint, only
BalenaRequestError: Request error: "Server error"
This doesn't seem to affect non-ESR releases
$ balena os download raspberrypi4-64 --version 2.88.4+rev0 -o pi.img
Getting device operating system for raspberrypi4-64
Downloading balenaOS version 2.88.4+rev0.prod [ ] 1% eta 3m02s
$ balena os download raspberrypi4-64 --version 2.88.5+rev1.prod -o pi.img
Getting device operating system for raspberrypi4-64
Downloading balenaOS version 2.88.5+rev1 [= ] 5% eta 1m00s
x
Each of the above command lines executes different code behind the scenes, so quoting the
full command line is very helpful.
Running the CLI in debug mode (--debug flag or DEBUG=1 environment variable) may reveal
additional information. The --logs option reveals additional information for the commands:
This is the most important and helpful part of a bug report. If we cannot reproduce the
problem, it is difficult to tell what the fix should be, or whether code changes have
fixed it.
balena os download raspberrypi4-64 --version 2021.10.2 (pre unification) fails
balena os download raspberrypi4-64 --version 2021.10.2.prod (pre unification) succeeds
balena os download raspberrypi4-64 --version 2022.1.1 (post unification) succeeds
balena os download raspberrypi4-64 --version 2022.1.1.prod (post unification) fails
Specifications
balena CLI version:
balena-cli version "13.3.1"
Node.js version "12.20.0"
**Cloud backend: balenaCloud
Operating system version: macOS 11.4
32/64 bit OS and processor: 64-bit Intel processor
Expected Behavior
Using
balena os download
should be consistent across ESR releasesActual Behavior
The behavior of the balena os download command is inconsistent now with the introduction of unified OS releases
balena os download raspberrypi4-64 --version 2021.10.2
(pre unification) fails if not given a suffix (I would expect it to default to prod maybe?)balena os download raspberrypi4-64 --version 2022.1.1
(post unification) fails if given a suffix (probably related to the introduction of the--dev
flag tobalena os configure
)The command feedback is not helpful either as when downloading an older version the CLI will show a hint about adding adding the suffix
while on the newer version there is no hint, only
This doesn't seem to affect non-ESR releases
x Each of the above command lines executes different code behind the scenes, so quoting the full command line is very helpful.
Running the CLI in debug mode (
--debug
flag orDEBUG=1
environment variable) may reveal additional information. The--logs
option reveals additional information for the commands:Steps to Reproduce the Problem
This is the most important and helpful part of a bug report. If we cannot reproduce the problem, it is difficult to tell what the fix should be, or whether code changes have fixed it.
balena os download raspberrypi4-64 --version 2021.10.2
(pre unification) failsbalena os download raspberrypi4-64 --version 2021.10.2.prod
(pre unification) succeedsbalena os download raspberrypi4-64 --version 2022.1.1
(post unification) succeedsbalena os download raspberrypi4-64 --version 2022.1.1.prod
(post unification) failsSpecifications