-
Bug
-
Resolution: Done
-
Normal
-
6.15.z
-
2
-
False
-
rubygem-katello-4.19.0-0.2.pre.master.20251025032225git1f234b5.el9sat.noarch
-
Moderate
-
Artemis Sprint 156, Artemis Sprint 157
-
sat-artemis
-
None
-
None
-
None
-
Automated
Description of problem:
The following REST API is listing installable hosts but it should list applicable hosts.
curl -X POST -H "Content-Type: application/json" -H "Accept: application/json" -u admin:redhat -d '{"included":{"ids":[<host id>]}}' https://satellite.example.com/api/v2/hosts/bulk/applicable_errata | jq
This is because both installable_errata and applicable_errata are calling the same partial "katello/api/v2/hosts_bulk_actions/erratum". See below:
$ cat installable_errata.json.rabl object false extends "katello/api/v2/common/metadata" node :results do partial("katello/api/v2/hosts_bulk_actions/erratum", :object => @collection[:results]) end $ cat applicable_errata.json.rabl object false extends "katello/api/v2/common/metadata" node :results do partial("katello/api/v2/hosts_bulk_actions/erratum", :object => @collection[:results]) end
How reproducible:
Always
Is this issue a regression from an earlier version:
Not sure. Maybe not.