Bug 486085 - 'xmlrpclib.Fault: <Fault -1: ...' when creating new errata
Summary: 'xmlrpclib.Fault: <Fault -1: ...' when creating new errata
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: API
Version: 520
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Brad Buckingham
QA Contact: Brandon Perkins
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-02-18 10:14 UTC by Jan Hutař
Modified: 2009-02-19 04:46 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-02-18 16:24:28 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Jan Hutař 2009-02-18 10:14:46 UTC
Description of problem:
When I try to create a new errata, I'm getting traceback.


Version-Release number of selected component (if applicable):
Red Hat Network release 5.2.0


How reproducible:
always


Steps to Reproduce:
1. >>> client.errata.create(key, me, mb, mk, mp, True, 'test-0')


Actual results:
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
  File "/usr/lib64/python2.4/xmlrpclib.py", line 1096, in __call__
    return self.__send(self.__name, args)
  File "/usr/lib64/python2.4/xmlrpclib.py", line 1383, in __request
    verbose=self.__verbose
  File "/usr/lib64/python2.4/xmlrpclib.py", line 1147, in request
    return self._parse_response(h.getfile(), sock)
  File "/usr/lib64/python2.4/xmlrpclib.py", line 1286, in _parse_response
    return u.close()
  File "/usr/lib64/python2.4/xmlrpclib.py", line 744, in close
    raise Fault(**self._stack[0])
xmlrpclib.Fault: <Fault -1: 'com.redhat.rhn.common.translation.TranslationException: Could not find translator for class java.lang.String to interface java.util.List'>


Expected results:
Errata created


Additional info:
>>> print me
{'advisory_name': 'advisory_name', 'advisory_type': 'Bug Fix Advisory', 'product': 'product', 'description': 'description', 'notes': 'notes', 'solution': 'solution', 'topic': 'topic', 'synopsis': 'synopsis', 'references': 'references', 'advisory_release': 1}
>>> print mb
({'id': 123456, 'summary': 'bug 123456 summary'},)
>>> print mk
('keyword1', 'keyword2')
>>> print mp
(198,)
>>> a = client.errata.create(key, me, mb, mk, mp, True, 'test-0')
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
  File "/usr/lib64/python2.4/xmlrpclib.py", line 1096, in __call__
    return self.__send(self.__name, args)
  File "/usr/lib64/python2.4/xmlrpclib.py", line 1383, in __request
    verbose=self.__verbose
  File "/usr/lib64/python2.4/xmlrpclib.py", line 1147, in request
    return self._parse_response(h.getfile(), sock)
  File "/usr/lib64/python2.4/xmlrpclib.py", line 1286, in _parse_response
    return u.close()
  File "/usr/lib64/python2.4/xmlrpclib.py", line 744, in close
    raise Fault(**self._stack[0])
xmlrpclib.Fault: <Fault -1: 'com.redhat.rhn.common.translation.TranslationException: Could not find translator for class java.lang.String to interface java.util.List'>

I do not know what I'm doing wrong here.

Comment 1 Brad Buckingham 2009-02-18 15:55:31 UTC
Hi Jan,

The error appears to be related to the channel label being specified as a string ('test-0') vs an array (['test-0']).

Try the test using the same variables (me, mb, mk, mp); however, use the following:
 a = client.errata.create(key, me, mb, mk, mp, True, ['test-0'])


I tried this in my env (5.3) and it works Ok.

Comment 2 Jan Hutař 2009-02-18 16:24:28 UTC
Oh, you are right, thank you and sorry for the mess!

Thanks,
Jan


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