Description of problem: channel.software.setUserSubscribable accepts values other than 'true' and 'false' for value. API should give an error saying 'invalid entry for value' How reproducible: >>> server.channel.software.setUserSubscribable(key, 'foobar', 'autoTestUser573', 'false') 1 >>> server.channel.software.setUserSubscribable(key, 'foobar', 'autoTestUser573', 'randomValue') 1 Expected results: API should give an error saying 'invalid entry for value'
Also, api docs say: "string" value Method: setUserSubscribable Description: Set the subscribable flag for a given channel and user. If value is set to 'true', this method will give the user subscribe permissions to the channel. Otherwise, that privilege is revoked. Parameters: * string sessionKey * string channelLabel - label of the channel * string login - login of the target user * string value - value of the flag to set <<<---- where actual signature of API accepts boolean value. ~SayliK
git commit: b9e7ce2cc164bbff57bf2197c347ccdde98cd6c8 API updated to take a Boolean as input (instead of primitive boolean). As a result, if API is executed with python should use format similar to: >>> client.channel.software.setUserSubscribable(key, 'rhel-x86_64-server-5', 'bbuckingham', True) 1 >>> client.channel.software.setUserSubscribable(key, 'rhel-x86_64-server-5', 'bbuckingham', False) 1 >>> Docs updated to reflect that 'value' is a boolean type: Method: setUserSubscribable Description: Set the subscribable flag for a given channel and user. If value is set to 'true', this method will give the user subscribe permissions to the channel. Otherwise, that privilege is revoked. Parameters: * string sessionKey * string channelLabel - label of the channel * string login - login of the target user * boolean value - value of the flag to set Returns: * int - 1 on success, exception thrown otherwise.
mass move to ON_QA
verified.
Verified in stage -> RELEASE_PENDING. $ ./xmlrpc-client.pl dell-pem710-01.rhts.eng.bos.redhat.com admin xxx channel.software.setUserSubscribable rhel-i386-server-5 user1 true OK $ ./xmlrpc-client.pl dell-pem710-01.rhts.eng.bos.redhat.com admin xxx channel.software.setUserSubscribable rhel-i386-server-5 user1 false OK $ ./xmlrpc-client.pl dell-pem710-01.rhts.eng.bos.redhat.com admin xxx channel.software.setUserSubscribable rhel-i386-server-5 user1 asdf Fault returned from XML RPC Server, fault code -1: com.redhat.rhn.common.translation.TranslationException: Could not find translator for class java.lang.String to class java.lang.Boolean Method: setUserSubscribable Description: Set the subscribable flag for a given channel and user. If value is set to 'true', this method will give the user subscribe permissions to the channel. Otherwise, that privilege is revoked. Parameters: string sessionKey string channelLabel - label of the channel string login - login of the target user boolean value - value of the flag to set Returns: int - 1 on success, exception thrown otherwise.
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHEA-2009-1434.html