GDR! added the comment:
While it would be allowed by the spec in the quotation I pasted in the original
post, I understand your point, it makes sense.
I still think, however, that it should be available at least as an option.
There already is allow_none parameter available when marshaling
GDR! added the comment:
Also, I think that should be represented as Decimal when unmarshalling
XML-RPC data, because the standard doesn't give any limits on size on precision
of data, and the only representation it allows is the one with decimal point,
making it an excellent fit for De
GDR! added the comment:
I didn't mean to implicitly convert Decimal to float. My point was that
xmlrpclib should serialize Decimals natively to avoid loss of precision when
converting to float and then to string.
Whether other party will be able to represent this number exactly or not s
New submission from GDR! :
xmlrpc.client (and xmlrpclib in 2.x) can't serialize instances of Decimal,
throwing TypeError instead. Because XML is a textual format, converting from
decimal to float may cause loss of data.
According to http://www.xmlrpc.com/spec, encoding Decimal as XML-RPC