[Patches] [ python-Patches-764470 ] Bugfix for incorrect xmlrpclib.Fault representation
SourceForge.net
noreply@sourceforge.net
Sat, 12 Jul 2003 00:54:20 -0700
Patches item #764470, was opened at 2003-07-02 11:06
Message generated for change (Comment added) made by loewis
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=764470&group_id=5470
Category: Library (Lib)
Group: Python 2.2.x
>Status: Closed
>Resolution: Accepted
Priority: 5
Submitted By: Gavrie Philipson (gavrie)
Assigned to: Martin v. Löwis (loewis)
Summary: Bugfix for incorrect xmlrpclib.Fault representation
Initial Comment:
The xmlrpclib library represents a Fault object with an extraneous
'args' member field.
The reason for this is that the dump function blindly marshals all
variables of the Fault object, and since Fault is a subclass of
Exception it inherits the 'args' attribute.
According to the XML-RPC spec, adding additional fields to a Fault
response is not allowed.
The attached patch is a simple solution to the problem.
Sample Fault XML output that shows the problem:
<?xml version='1.0'?>
<methodResponse>
<fault>
<value><struct>
<member>
<name>faultCode</name>
<value><int>900</int></value>
</member>
<member>
<name>args</name>
<value><array><data>
</data></array></value>
</member>
<member>
<name>faultString</name>
<value><string>boo</string></value>
</member>
</struct></value>
</fault>
</methodResponse>
----------------------------------------------------------------------
>Comment By: Martin v. Löwis (loewis)
Date: 2003-07-12 09:54
Message:
Logged In: YES
user_id=21627
Thanks for the patch. Committed as xmlrpclib.py 1.29 and
1.15.4.1
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=764470&group_id=5470