Project

General

Profile

Actions

Bug #32556

closed

CV Promotion/Composite cv publish failed with NoMethodError: undefined method `get_status' for nil:NilClass

Added by Partha Aji almost 3 years ago. Updated over 2 years ago.

Status:
Closed
Priority:
Normal
Category:
Content Views
Target version:
Difficulty:
Triaged:
Yes
Fixed in Releases:
Found in Releases:

Description

Description of problem:

After publish and promoting a CV, it gives a warning with the following msg under Task -> Click on the Promote task -> Dynflow Console -> Finalize:
~~~
27: Actions::Katello::ContentView::PromoteToEnvironment (skipped) [ 0.03s / 0.03s ]

Error:

NoMethodError

undefined method `get_status' for nil:NilClass

---
- "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.16.0.26/app/models/katello/host/content_facet.rb:230:in
`update_errata_status'"
- "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.16.0.26/app/lib/actions/katello/content_view/promote_to_environment.rb:50:in
`block in finalize'"
~~~

Version-Release number of selected component (if applicable):
Katello 3.16
How reproducible:
100%

Steps to Reproduce:
1. Create 2 Locations 'Location_A' and 'Location_B'
2. under Location 'Location_A' create a CV named CV_Test and promote it to the Dev environment
3. Assign the CV and Env to a host under Location_A
4. Assign the host to 'Location_B'
5. Change the Context to 'Location_A'
6. Publish the CV_Test and promote it to Dev

Actual results:
The promotion does not complete with success and ends with the following msg:

~~~
27: Actions::Katello::ContentView::PromoteToEnvironment (skipped) [ 0.03s / 0.03s ]

Error:

NoMethodError

undefined method `get_status' for nil:NilClass

---
- "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.16.0.26/app/models/katello/host/content_facet.rb:230:in
`update_errata_status'"
- "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.16.0.26/app/lib/actions/katello/content_view/promote_to_environment.rb:50:in
`block in finalize'"
~~~

Expected results:
The promotion finish with success w/o taking the taxonomy into account.

Work Around:
1. Change the context to "Any Location"
2. Publish and promote the CV

Similar issue also occurs for Composite CV Publish

Actions #1

Updated by Partha Aji almost 3 years ago

  • Bugzilla link set to 1957035
Actions #2

Updated by Justin Sherrill almost 3 years ago

  • Target version set to Katello 4.2.0
  • Triaged changed from No to Yes
Actions #3

Updated by Justin Sherrill over 2 years ago

  • Target version changed from Katello 4.2.0 to Katello 4.2.1
Actions #4

Updated by The Foreman Bot over 2 years ago

  • Status changed from New to Ready For Testing
  • Assignee set to Justin Sherrill
  • Pull request https://github.com/Katello/katello/pull/9613 added
Actions #5

Updated by The Foreman Bot over 2 years ago

  • Fixed in Releases Katello 4.3.0 added
Actions #6

Updated by Justin Sherrill over 2 years ago

  • Status changed from Ready For Testing to Closed
Actions

Also available in: Atom PDF