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 1495568 - Providing invalid phase in foreman-maintain upgrade run shows undefined method `to_hash' for nil:NilClass
Summary: Providing invalid phase in foreman-maintain upgrade run shows undefined metho...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Satellite Maintain
Version: 6.3.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: Unspecified
Assignee: Kavita
QA Contact: Nikhil Kathole
URL:
Whiteboard:
Depends On:
Blocks: 1496794
TreeView+ depends on / blocked
 
Reported: 2017-09-26 10:15 UTC by Nikhil Kathole
Modified: 2019-09-26 15:38 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-02-19 17:22:26 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
log in foreman-maintain.log file (2.69 KB, text/plain)
2017-09-26 10:15 UTC, Nikhil Kathole
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 21211 0 None None None 2017-10-05 12:39:21 UTC
Red Hat Product Errata RHBA-2018:0330 0 normal SHIPPED_LIVE Satellite Maintenance bug fix update 2018-02-19 22:22:51 UTC

Description Nikhil Kathole 2017-09-26 10:15:27 UTC
Created attachment 1330971 [details]
log in foreman-maintain.log file

Description of problem: While running foreman-maintain upgrade run with option --phase provided invalid phase name shows "undefined method `to_hash' for nil:NilClass".


Version-Release number of selected component (if applicable): Foreman-maintain snap 2.0


How reproducible: always


Steps to Reproduce:

1. # foreman-maintain upgrade run --phase pre-upgrade


Actual results: 
Error as "undefined method `to_hash' for nil:NilClass"


Expected results: Error should get handled and proper message showing phase is invalid.


Additional info:

Comment 3 Satellite Program 2017-10-05 14:23:34 UTC
Upstream bug assigned to kgaikwad

Comment 4 Satellite Program 2017-10-10 12:12:26 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/21211 has been resolved.

Comment 5 Nikhil Kathole 2017-12-15 08:57:12 UTC
VERIFIED

Version Tested:

# rpm -q rubygem-foreman_maintain
rubygem-foreman_maintain-0.1.1-1.el7sat.noarch

# foreman-maintain upgrade run --phase pre-upgrade
Unknown phase pre-upgrade

Error handled and showed message as unknown phase. But if --phase not passed, it showed

# foreman-maintain upgrade run --phase
undefined method `to_sym' for nil:NilClass

Verifying this as this will be tracked by https://bugzilla.redhat.com/show_bug.cgi?id=1523933 .

Comment 8 errata-xmlrpc 2018-02-19 17:22:26 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.

https://access.redhat.com/errata/RHBA-2018:0330


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