RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 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 "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". 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 "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-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 2064002 - TypeError: registerConsumer() got an unexpected keyword argument 'environment' in initial-setup-graphical
Summary: TypeError: registerConsumer() got an unexpected keyword argument 'environment...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: subscription-manager
Version: 8.6
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: 8.6
Assignee: Pino Toscano
QA Contact: Red Hat subscription-manager QE Team
URL:
Whiteboard:
Depends On:
Blocks: 2026666 2065209
TreeView+ depends on / blocked
 
Reported: 2022-03-14 21:01 UTC by Jan Stavel
Modified: 2023-04-24 08:09 UTC (History)
7 users (show)

Fixed In Version: subscription-manager-1.28.29-2.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2065209 (view as bug list)
Environment:
Last Closed: 2022-05-10 15:23:24 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
an error in registration dialog (67.45 KB, image/png)
2022-03-14 21:01 UTC, Jan Stavel
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github candlepin subscription-manager pull 3009 0 None Merged 2064002: fix named argument for `registerConsumer()` 2022-03-17 06:45:09 UTC
Github candlepin subscription-manager pull 3010 0 None Merged [1.28.29] 2064002: fix named argument for `registerConsumer()` 2022-03-17 14:03:33 UTC
Red Hat Issue Tracker ENT-4813 0 None None None 2022-03-15 15:11:57 UTC
Red Hat Issue Tracker RHELPLAN-115557 0 None None None 2022-03-14 21:04:53 UTC
Red Hat Product Errata RHBA-2022:2047 0 None None None 2022-05-10 15:23:40 UTC

Description Jan Stavel 2022-03-14 21:01:30 UTC
Created attachment 1865924 [details]
an error in registration dialog

Description of problem:


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

server type: This system is currently not registered.
subscription management server: 3.2.22-1
subscription management rules: 5.41
subscription-manager: 1.28.28-1.el8

Steps to Reproduce:

I want to register a system.
I've used RHEL-8.6.0-20220302.5
 

Actual results:
I used subscriptions plugin in anaconda and initial-setup-graphical.
I wanted to register a system against a stage candlepin server.

An error: TypeError: registerConsumer() got an unexpected keyword argument 'environment' in initial-setup-graphical
appeared.

I've attached a screenshot with the error message too.

Additional info:

/var/log/rhsm/rhsm.log:

oneType: None
2022-03-11 22:59:28,289 [ERR] initial-setup-graphical:3972:MainThread @utils.py:165 - None
Traceback (most recent call last):
  File "/usr/lib64/python3.6/site-packages/subscription_manager/gui/registergui.py", line 2000, in _register_consumer
    usage=syspurpose.get('usage')
TypeError: registerConsumer() got an unexpected keyword argument 'environment'
2022-03-11 22:59:28,984 [WRN] initial-setup-graphical:3972:RegisterConsumerThread @dmiinfo.py:130 - Error reading system DMI information: # SMBIOS implementations newer than version 2.7 are not
# fully supported by this version of dmidecode.

NoneType: None
2022-03-11 22:59:29,159 [ERR] initial-setup-graphical:3972:MainThread @utils.py:165 - None
Traceback (most recent call last):
  File "/usr/lib64/python3.6/site-packages/subscription_manager/gui/registergui.py", line 2000, in _register_consumer
    usage=syspurpose.get('usage')
TypeError: registerConsumer() got an unexpected keyword argument 'environment'
2022-03-11 23:02:52,177 [WARNING] rhsm-service:2611:Thread-FileSystemWatcher @logutil.py:170 - logging already initialized

Comment 1 Pino Toscano 2022-03-15 15:11:58 UTC
Uhh this is a regression in the GUI code, used only for the initial-setup addon, because of the changes for multi-environments (bug 1994056).
The fix seems easy though, luckily.

Comment 15 Archana Pandey 2022-03-28 08:09:11 UTC
verifying on subscription-manager-1.28.29-2.el8.x86_64

Steps for verification:

[root@localhost ~]# subscription-manager version
server type: This system is currently not registered.
subscription management server: 3.2.22-1
subscription management rules: 5.41
subscription-manager: 1.28.29-2.el8
[root@localhost ~]# 
[root@localhost ~]# rpm -qa --changelog subscription-manager | grep 2064002
- 2064002: fix named argument for registerConsumer() (ptoscano)
[root@localhost ~]# 
[root@localhost ~]# systemctl enable initial-setup
Created symlink /etc/systemd/system/graphical.target.wants/initial-setup.service → /usr/lib/systemd/system/initial-setup.service.
Created symlink /etc/systemd/system/multi-user.target.wants/initial-setup.service → /usr/lib/systemd/system/initial-setup.service.
[root@localhost ~]# 
[root@localhost ~]# reboot

******* Successfully Registered using initial setup GUI *********

Image attached attachment 1868665 [details]

[root@localhost ~]# subscription-manager status
+-------------------------------------------+
   System Status Details
+-------------------------------------------+
Overall Status: Current

System Purpose Status: Not Specified

Verification : Passed

Comment 17 errata-xmlrpc 2022-05-10 15:23:24 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 (subscription-manager bug fix and enhancement 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-2022:2047


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