Bug 1696273 - Katello::Content uses removed Katello::Glue::Candlepin::Product.import_product_content
Summary: Katello::Content uses removed Katello::Glue::Candlepin::Product.import_produc...
Alias: None
Product: Red Hat Satellite 6
Classification: Red Hat
Component: Content Management
Version: 6.5.0
Hardware: Unspecified
OS: Unspecified
high vote
Target Milestone: Released
Assignee: Jonathon Turel
QA Contact: Mike McCune
Depends On:
TreeView+ depends on / blocked
Reported: 2019-04-04 12:50 UTC by Evgeni Golov
Modified: 2019-10-07 17:19 UTC (History)
2 users (show)

Fixed In Version: tfm-rubygem-katello-
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2019-05-14 12:40:38 UTC

Attachments (Terms of Use)

System ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2019:1222 None None None 2019-05-14 12:40:43 UTC
Foreman Issue Tracker 26535 None None None 2019-04-04 12:50:58 UTC

Description Evgeni Golov 2019-04-04 12:50:57 UTC
In #25981, we removed <code>import_product_content</code> from <code>Katello::Glue::Candlepin::Product</code>, however, this method is still used in <code>Katello::Content</code>:

    def self.import_all
      Organization.all.each do |org|
        org.products.each do |product|
            product_json = Katello::Resources::Candlepin::Product.get(org.label,
            product_content_attrs = product_json['productContent']
            Katello::Glue::Candlepin::Product.import_product_content(product, product_content_attrs)
          rescue RestClient::NotFound
            Rails.logger.warn _("Product with ID %s not found in Candlepin. Skipping content import for it.") % product.cp_id

I *think* this code is only called in the <code>katello:reimport</code> rake task, but that one will fail now.

Comment 1 Evgeni Golov 2019-04-04 12:51:00 UTC
Created from redmine issue https://projects.theforeman.org/issues/26535

Comment 2 Evgeni Golov 2019-04-04 12:51:03 UTC
Upstream bug assigned to None

Comment 6 Brad Buckingham 2019-04-05 18:12:59 UTC
The PR was merged yesterday, but seems automation did not move BZ to POST.  Doing it now.

Comment 10 Mike McCune 2019-04-18 04:28:29 UTC
VERIFIED in Snap 23

# foreman-rake katello:reimport
Importing Katello::Erratum
Importing Katello::PackageGroup
Importing Katello::PuppetModule
Importing Katello::Rpm
Importing Katello::Srpm
Importing Katello::ModuleStream
Importing Katello::YumMetadataFile
Importing Katello::Deb
Importing Katello::FileUnit
Importing Katello::Subscription
Importing Katello::Pool
Importing Katello::DockerManifest
Importing Katello::DockerManifestList
Importing Katello::DockerTag
Importing Katello::ContentViewPuppetEnvironment
Importing Katello::Content
Importing Katello::OstreeBranch
Importing Activation Key Subscriptions
Importing Linked Repositories

Comment 12 errata-xmlrpc 2019-05-14 12:40:38 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.