This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author phr
Recipients
Date 2001-10-12.20:16:21
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
Logged In: YES 
user_id=72053

Decimal is bad not just because of the data expansion but
because the arithmetic to convert a decimal string to binary
can be expensive (all that multiplication).  I'd rather use
hex than decimal for that reason.  One envisioned
application is communicating a cryptography coprocessor: an
8-bit microcontroller (with a public key accelerator)
connected to the host computer through a slow serial port.
Most of the ints involved would be around 300 decimal
digits.
A simple binary format is a lot easier to deal with
in that environment than something like xmlrpc.  Also,
the format would be used for data persistence, so again,
unnecessary data expansion isn't desirable.

I looked at XMLRPC and it's not designed for this purpose.
It's intended as an RPC protocol over HTTP and isn't
well suited for object persistence.  Also, it doesn't
support integers over 32 bits, and binary strings must be
base64 encoded (more bloat).  Finally, it's not included
with Python, so I'd have to bundle an implementation
written in Python (i.e. slow) with my application (I don't
know whether Fred's implementation is Python or C).  I
think the marshal format hasn't changed since before
Python 1.5, so basing serialization on marshal would mean
applications could interoperate with older versions of
Python as well as newer ones, which helps Python's maturity.
(Maturity of a program means, among other things, that
users rarely need to be told they need the latest version
in order to use some feature).

Really, the marshal functions are written the way they're
written because that's the simplest and most natural way
of doing this kind of thing.  So the proposal is mainly
to make them available for user applications, rather than
only for system internals.
History
Date User Action Args
2007-08-23 16:01:32adminlinkissue467384 messages
2007-08-23 16:01:32admincreate