-
Notifications
You must be signed in to change notification settings - Fork 1.1k
tools: Download ARM deb package, disable fedora ARM test #6110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Signed-off-by: Abhijat Malviya <[email protected]>
The rpm is only built for this one architecture. Signed-off-by: Abhijat Malviya <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review completed. 2 suggestions posted.
Comment augment review to trigger a new review at any time.
| assert result.exit_code == 0, f"command {cmd} failed with result {result}" | ||
|
|
||
|
|
||
| @pytest.mark.skipif(platform.processor() != "x86_64", reason="rpm is only built for x86_64") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
platform.processor() can return an empty string on some Linux environments, which could cause this test to be skipped even on x86_64; platform.machine() tends to be more reliable for architecture checks.
🤖 Was this useful? React with 👍 or 👎
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@abhijat +1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider this
@pytest.mark.skipif(
platform.architecture()[0] != "64bit",
reason="test requires 64-bit platform"
)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
platform.architecture()[0] != "64bit",
Because this analyzes the output of the file command, it will also return true on 64 bit ARM which we have to skip, eg from an arm machine
# uname -a
Linux ... aarch64 aarch64 aarch64 GNU/Linux
>>> platform.architecture()
('64bit', 'ELF')
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did not apply the bot's suggestion because machine() can also return empty string on some environments, it doesn't appear to be any better than processor() which we already use in some other places in code.
| for package in packages: | ||
| if package.kind == AssetKind.DEB and deb_done: | ||
| # Download the latest arm and amd64 package for .deb format | ||
| if package.kind == AssetKind.DEB and deb_done == 2: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This logic assumes exactly two DEB architectures and relies on asset ordering; it may download two of the same arch across releases and miss the other. Tracking unique architectures downloaded would ensure one per arch regardless of order (also applies to the increment below).
🤖 Was this useful? React with 👍 or 👎
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a valid suggestion but kind of overkill as we have a specific schema and order for packages on the release page. It might be something to apply in a follow up PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no need
To fix failing installer tests in CI, the arm debian package is downloaded, this was earlier missing.
Also ARM rpm is not generated for fedora, so this test is skipped on ARM.
fixes #6109