Bug 1428831 - spacecmd system_setconfigchannelorder fails with ERROR: 'list' object is not callable
Summary: spacecmd system_setconfigchannelorder fails with ERROR: 'list' object is not ...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Server
Version: 580
Hardware: All
OS: All
unspecified
medium
Target Milestone: ---
Assignee: Tomáš Kašpárek
QA Contact: Pavel Studeník
URL:
Whiteboard:
Depends On: 1189291
Blocks: sat580-low
TreeView+ depends on / blocked
 
Reported: 2017-03-03 13:02 UTC by Tomáš Kašpárek
Modified: 2017-06-21 12:13 UTC (History)
3 users (show)

Fixed In Version: spacecmd-2.5.0-9-sat
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 1189291
Environment:
Last Closed: 2017-06-21 12:13:45 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Tomáš Kašpárek 2017-03-03 13:02:05 UTC
+++ This bug was initially created as a clone of Bug #1189291 +++

Description of problem:
spacecmd system_setconfigchannelorder <servername>
#(interaction omitted)
a[dd], r[emove], c[lear], d[one]: d
New Configuration Channels
--------------------------
ERROR: 'list' object is not callable


Version-Release number of selected component (if applicable):
Found in production on spacecmd-2.2.11-1.el6.noarch
Verified in nightly (2015-02-04): spacecmd-2.3.14-1.el6.noarch

How reproducible:
ALWAYS


Steps to Reproduce:
1. spacecmd system_setconfigchannelorder <systemname>
2. type "d" <enter> for done
3. See the error :)

Actual results:

a[dd], r[emove], c[lear], d[one]: d

New Configuration Channels
--------------------------
ERROR: 'list' object is not callable

(and the new list is not saved, in the case where you actually change the order)


Expected results:
No error, new channel list saved.


Additional info:
We use this command via a shell script to sort our configuration channels, otherwise I can't comprehend anyone actually interacting with this.


The error appears to be at:
https://git.fedorahosted.org/cgit/spacewalk.git/tree/spacecmd/src/lib/system.py#n1401
(as of today)


    print
    print 'New Configuration Channels'
    print '--------------------------'
    for i, new_channel in new_channels(new_channels, 1):
        print '[%i] %s' % (i, new_channel)

--- Additional comment from Tommy McNeely on 2015-02-04 17:04:44 EST ---

# Workaround:

Comment out the "for" loop (for line and the line below it). It won't print the new channel list, but it was just emitted above before pressing "d" for done, so its not like it really needs to be printed again.

This is at like 1441 for spacecmd-2.2.11-1.el6.noarch

--- Additional comment from Tomáš Kašpárek on 2017-03-03 07:48:38 EST ---

spacewalk.git(master): 11394cc4a8d01aaec725a55c69e8a595400db12c

Comment 3 Pavel Studeník 2017-03-23 12:09:57 UTC
Verified spacecmd-2.5.0-9.el6sat.noarch


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