Skip to content

Conversation

Satellite-QE
Copy link
Collaborator

Cherrypick of PR: #20007

Test test_positive_update_hostname_default_prefix failed (semi)randomly. The failures were caused by invalid characters in the hostname prefix that is generated by generate_strings_list.
Allowed characters are following:
Value must start with a letter. Allowed characters: a-z, A-Z, 0-9 and -. Max length is 62 characters.
This fix generates string that meets this requirement.

@Satellite-QE Satellite-QE added 6.18.z Introduced in or relating directly to Satellite 6.18 Auto_Cherry_Picked Automatically cherrypicked PR using GHA No-CherryPick PR doesnt need CherryPick to previous branches labels Oct 16, 2025
@Satellite-QE
Copy link
Collaborator Author

trigger: test-robottelo
pytest: tests/foreman/api/test_settings.py -k 'test_positive_update_hostname_default_prefix'

@Satellite-QE Satellite-QE added the AutoMerge_Cherry_Picked The cherrypicked PRs of master PR would be automerged if all checks passing label Oct 16, 2025
Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey there - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@Satellite-QE
Copy link
Collaborator Author

PRT Result

Build Number: 13214
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_settings.py -k test_positive_update_hostname_default_prefix --external-logging
Test Result : =========== 1 failed, 26 deselected, 5 warnings in 702.84s (0:11:42) ===========

@Satellite-QE Satellite-QE added the PRT-Failed Indicates that latest PRT run is failed for the PR label Oct 16, 2025
Copy link
Contributor

@lpramuk lpramuk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PRT failed with NameError: name 'gen_string' is not defined

You need to introduce the following import in 6.18.z branch:

from fauxfactory import gen_string

@rmynar
Copy link
Contributor

rmynar commented Oct 21, 2025

Seems like the missing import is caused by not cherrypicking #19489
The cherrypick now exists: #20043
Let's wait for it to be merged and then rebase

fix generating of hostname prefix

Co-authored-by: Lukas Pramuk <[email protected]>
(cherry picked from commit 431c943)
@rmynar rmynar force-pushed the cherry-pick-6.18.z-431c94335b5a31c8172cc1a20734007bfab4be17 branch from 8764d07 to 0bb98b3 Compare October 21, 2025 12:06
@rmynar
Copy link
Contributor

rmynar commented Oct 21, 2025

trigger: test-robottelo
pytest: tests/foreman/api/test_settings.py -k 'test_positive_update_hostname_default_prefix'

@Satellite-QE
Copy link
Collaborator Author

PRT Result

Build Number: 13248
Build Status: SUCCESS
PRT Comment: pytest tests/foreman/api/test_settings.py -k test_positive_update_hostname_default_prefix --external-logging
Test Result : =========== 1 passed, 26 deselected, 5 warnings in 818.19s (0:13:38) ===========

@Satellite-QE Satellite-QE added PRT-Passed Indicates that latest PRT run is passed for the PR and removed PRT-Failed Indicates that latest PRT run is failed for the PR labels Oct 21, 2025
@Satellite-QE Satellite-QE merged commit d63c384 into 6.18.z Oct 21, 2025
13 of 14 checks passed
@Satellite-QE Satellite-QE deleted the cherry-pick-6.18.z-431c94335b5a31c8172cc1a20734007bfab4be17 branch October 21, 2025 12:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.18.z Introduced in or relating directly to Satellite 6.18 Auto_Cherry_Picked Automatically cherrypicked PR using GHA AutoMerge_Cherry_Picked The cherrypicked PRs of master PR would be automerged if all checks passing No-CherryPick PR doesnt need CherryPick to previous branches PRT-Passed Indicates that latest PRT run is passed for the PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants