foreman-rake katello:reimport fails in Red Hat Satellite 6 with NoMethodError: undefined method '+' for nil:NilClass
Issue
-
When running
foreman-rake katello:reimport
hitting the following error:# foreman-rake katello:reimport /usr/share/foreman/lib/foreman.rb:8: warning: already initialized constant Foreman::UUID_REGEXP /usr/share/foreman/lib/foreman.rb:8: warning: previous definition of UUID_REGEXP was here /usr/share/foreman/lib/core_extensions.rb:182: warning: already initialized constant ActiveSupport::MessageEncryptor::DEFAULT_CIPHER /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activesupport-5.1.6/lib/active_support/message_encryptor.rb:22: warning: previous definition of DEFAULT_CIPHER was here Importing Katello::Erratum Importing Katello::PackageGroup Importing Katello::PuppetModule Importing Katello::Rpm Importing Katello::Srpm 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 rake aborted! NoMethodError: undefined method '+' for nil:NilClass /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.41/app/lib/katello/resources/candlepin/product.rb:25:in 'get' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.41/app/models/katello/content.rb:40:in `block (2 levels) in import_all' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in 'each' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in 'each' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.41/app/models/katello/content.rb:38:in 'block in import_all' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in `each' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in `each' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.41/app/models/katello/content.rb:37:in `import_all' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.41/lib/katello/tasks/reimport.rake:39:in `block (3 levels) in top (required)' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.41/lib/katello/tasks/reimport.rake:37:in `each' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.41/lib/katello/tasks/reimport.rake:37:in `block (2 levels) in top (required)' /opt/rh/rh-ruby24/root/usr/share/gems/gems/rake-12.0.0/exe/rake:27:in `top (required)' Tasks: TOP => katello:reimport (See full trace by running task with --trace)
Environment
- Red Hat Satellite 6.4
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.