Bug #39282
closedApplicable/Installable toggle is hidden for hosts assigned to rolling content views
Description
In ErrataTab.js, we have logic to decide whether to show the Applicable / Installable toggle group:
const hostIsNonLibrary = (
(contentFacet?.contentViewDefault === false ||
contentFacet.lifecycleEnvironmentLibrary === false) &&
contentFacet.contentView.rolling === false
);
The logic relies on contentFacet.contentView which only returns the first of many content view environments. This is incorrect. If a rolling CVEnv is first but there are multiple CVEnvs assigned, the host can still have applicable, non-installable errata.
Actual behavior:
The Applicable / Installable toggle does not show for a host assigned to multiple content view environments where the first one is rolling. If you have non-rolling CVEnvs after that, e.g. [rolling, non-rolling] you could still have non-installable errata in non-rolling.
Expected behavior:
I suggest changing the method logic from hostIsNonLibrary to hostIsLibraryOrRolling. Then:
The Applicable / Installable toggle should be hidden only
- for a “library” host, e.g. any host that lists Library/Default Org View as its first CVEnv;
- for a host that is assigned only to CVEnvs that contain rolling content views or rolling + library.
Examples:
Toggle should NOT show:
[Library]
[rolling, rolling]
[Library, non-rolling] (Library is first; therefore it’s a library host)
[rolling, Library] (all-rolling + Library = library host)
Toggle should show:
[non-rolling, Library]
[non-rolling, non-rolling]
[rolling, non-rolling]
Updated by The Foreman Bot about 1 month ago
- Status changed from New to Ready For Testing
- Pull request https://github.com/Katello/katello/pull/11723 added
Updated by Vladimir Sedmik about 1 month ago
- Category set to Hosts
- Target version set to Katello 4.20.1
- Triaged changed from No to Yes
Updated by Anonymous 28 days ago
- Status changed from Ready For Testing to Closed
Applied in changeset katello|9b461920c6ab2bac47e84b3e9ac3c089651d9845.