Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1959901

Summary: foreman-rake katello:* fails with the error message The Dynflow world was not initialized yet
Product: Red Hat Satellite Reporter: Anand Agrawal <aagrawal>
Component: RepositoriesAssignee: Chris Roberts <chrobert>
Status: CLOSED ERRATA QA Contact: Tasos Papaioannou <tpapaioa>
Severity: high Docs Contact:
Priority: high    
Version: 6.9.0CC: ahumbe, chrobert, dhjoshi, jjeffers, saydas
Target Milestone: 6.9.3Keywords: Regression, Triaged, Upgrades
Target Release: Unused   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: tfm-rubygem-katello-3.18.1.30-1 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1962847 (view as bug list) Environment:
Last Closed: 2021-07-01 14:56:52 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Anand Agrawal 2021-05-12 15:03:55 UTC
Description of problem:

While running any foreman-rake command under Katello namespace fails with below error message.

{:status=>"FAIL", :message=>
      "The Dynflow world was not initialized yet. If your plugin uses it, make sure to call Rails.application.dynflow.require! in some initializer"},

Eg:
# foreman-rake katello:check_ping
{:services=>
  {:candlepin=>{:status=>"ok", :duration_ms=>"29"},
   :candlepin_auth=>{:status=>"ok", :duration_ms=>"27"},
   :foreman_tasks=>
    {:status=>"FAIL",
     :message=>
      "The Dynflow world was not initialized yet. If your plugin uses it, make sure to call Rails.application.dynflow.require! in some initializer"},
   :katello_events=>
    {:status=>"ok", :message=>"38 Processed, 0 Failed", :duration_ms=>"0"},
   :candlepin_events=>
    {:status=>"ok", :message=>"71 Processed, 0 Failed", :duration_ms=>"0"},
   :pulp=>{:status=>"ok", :duration_ms=>"82"},
   :pulp_auth=>{:status=>"ok", :duration_ms=>"40"}},
 :status=>"FAIL"}
rake aborted!
Not all the services have been started. Check the status report above and try again.
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.18.1.22/lib/katello/tasks/reimport.rake:10:in `block (2 levels) in <top (required)>'
/opt/rh/rh-ruby25/root/usr/share/gems/gems/rake-12.3.0/exe/rake:27:in `<top (required)>'
Tasks: TOP => katello:check_ping
(See full trace by running task with --trace)



Version-Release number of selected component (if applicable):
6.9

How reproducible:

Always
Steps to Reproduce:
1. execute any foreman-rake command with katello namespace.
2.
3.

Actual results:

The Dynflow world was not initialized yet. If your plugin uses it, make sure to call Rails.application.dynflow.require! in some initializer


Expected results:

This should work without error
Additional info:

Comment 1 Anand Agrawal 2021-05-12 15:04:30 UTC
*** Bug 1959888 has been marked as a duplicate of this bug. ***

Comment 2 Anand Agrawal 2021-05-12 15:05:45 UTC
*** Bug 1959878 has been marked as a duplicate of this bug. ***

Comment 4 Tasos Papaioannou 2021-06-07 14:43:36 UTC
Verified on 6.9.3 snap 1.0.

# foreman-rake katello:check_ping

# foreman-rake katello:clean_backend_objects --trace
** Invoke katello:clean_backend_objects (first_time)
** Invoke environment (first_time)
** Execute environment
** Invoke katello:check_ping (first_time)
** Invoke dynflow:client (first_time)
** Invoke environment 
** Execute dynflow:client
** Invoke environment 
** Execute katello:check_ping
** Execute katello:clean_backend_objects
The following changes will not actually be performed.  Rerun with COMMIT=true to apply the changes
0 orphaned consumer id(s) found in candlepin.
Candlepin orphaned consumers: []
0 orphaned consumer id(s) found in pulp.
Pulp orphaned consumers: []

Comment 9 errata-xmlrpc 2021-07-01 14:56:52 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 (Satellite 6.9.3 Async Bug Fix Update), and where to find the updated
files, follow the link below.

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

https://access.redhat.com/errata/RHBA-2021:2636