Project

General

Profile

Refactor #25605

drop hypervisor_guest_uuids from SubscriptionFacet

Added by Evgeni Golov 7 months ago. Updated 6 months ago.

Status:
Closed
Priority:
Low
Assignee:
Category:
-
Target version:
Branch:
Difficulty:
Triaged:
Yes
Bugzilla link:
Team Backlog:
Fixed in Releases:
Found in Releases:

Description

currently, SubscriptionFacet.hypervisor_guest_uuids is never set, as the assignment is conditional on an non-existing key:

       def update_from_consumer_attributes(consumer_params)
         import_database_attributes(consumer_params)
         self.hypervisor_guest_uuids = consumer_params['guestIds'] unless consumer_params['hypervisor_guest_uuids'].blank?
         self.facts = consumer_params['facts'] unless consumer_params['facts'].blank?
       end

And if you change that to the correct key:

self.hypervisor_guest_uuids = consumer_params['guestIds'] unless consumer_params['guestIds'].blank?

you end up with an error:
NoMethodError: undefined method `hypervisor_guest_uuids=' for #<Katello::Host::SubscriptionFacet:0x000055d632ba3b60>

As such, I think hypervisor_guest_uuids is unused and can be removed.

Associated revisions

Revision d31bdd3d (diff)
Added by Evgeni Golov 6 months ago

Fixes #25605 - drop hypervisor_guest_uuids from SubscriptionFacet

History

#1 Updated by The Foreman Bot 7 months ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/Katello/katello/pull/7861 added

#2 Updated by Andrew Kofink 6 months ago

  • Triaged changed from No to Yes
  • Target version set to Katello 3.11.0

#3 Updated by Evgeni Golov 6 months ago

  • Status changed from Ready For Testing to Closed

Also available in: Atom PDF