http://bugs.python.org/issue6784 ("byte/unicode pickle
incompatibilities between python2 and python3")
Hello all,
Currently, pickle unpickles python2 'str' objects as python3 'str'
objects, where the encoding to use is passed to the Unpickler.
However, there are cases where it makes more sense to
Oops. I should re-read my mails before I send them, not /after/ I send them.
On 13 March 2012 12:44, Merlijn van Deen wrote:
pickled = BytestrPickler(data, bytestr=True); unpickled =
BytestrUnpickler(data, bytestr=True)
should of course read
pickled = BytestrPickler(data); unpic
On 13 Mar 2012, at 04:44, Merlijn van Deen wrote:
> http://bugs.python.org/issue6784 ("byte/unicode pickle
> incompatibilities between python2 and python3")
>
> Hello all,
>
> Currently, pickle unpickles python2 'str' objects as python3 'str'
> objects, where the encoding to use is passed to th
On Tue, Mar 13, 2012 at 12:42 PM, Michael Foord
wrote:
>
> On 13 Mar 2012, at 04:44, Merlijn van Deen wrote:
>
>> http://bugs.python.org/issue6784 ("byte/unicode pickle
>> incompatibilities between python2 and python3")
>>
>> Hello all,
>>
>> Currently, pickle unpickles python2 'str' objects as py
On 13 March 2012 22:13, Guido van Rossum wrote:
> Well, since trying to migrate data between versions using pickle is
> the "wrong" thing anyway, I think the status quo is just fine.
> Developers doing the "right" thing don't use pickle for this purpose.
I'm confused by this. "The pickle serializ
On Tue, Mar 13, 2012 at 2:50 PM, Merlijn van Deen wrote:
> On 13 March 2012 22:13, Guido van Rossum wrote:
>> Well, since trying to migrate data between versions using pickle is
>> the "wrong" thing anyway, I think the status quo is just fine.
>> Developers doing the "right" thing don't use pickl
On Wed, Mar 14, 2012 at 8:08 AM, Guido van Rossum wrote:
> If you can solve your problem with a suitably hacked Unpickler
> subclass that's fine with me, but I would personally use this
> opportunity to change the app to some other serialization format that
> is perhaps less general but more robus
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 03/13/2012 06:49 PM, Nick Coghlan wrote:
> On Wed, Mar 14, 2012 at 8:08 AM, Guido van Rossum
> wrote:
>> If you can solve your problem with a suitably hacked Unpickler
>> subclass that's fine with me, but I would personally use this
>> opportunit
On Thu, Mar 15, 2012 at 9:48 PM, Tres Seaver wrote:
> On 03/13/2012 06:49 PM, Nick Coghlan wrote:
>> On Wed, Mar 14, 2012 at 8:08 AM, Guido van Rossum
>> wrote:
>>> If you can solve your problem with a suitably hacked Unpickler
>>> subclass that's fine with me, but I would personally use this
>>>
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 03/16/2012 10:57 AM, Guido van Rossum wrote:
> On Thu, Mar 15, 2012 at 9:48 PM, Tres Seaver
> wrote:
>> On 03/13/2012 06:49 PM, Nick Coghlan wrote:
>>> On Wed, Mar 14, 2012 at 8:08 AM, Guido van Rossum
>>> wrote:
If you can solve your problem
On Fri, Mar 16, 2012 at 9:20 AM, Tres Seaver wrote:
> On 03/16/2012 10:57 AM, Guido van Rossum wrote:
>> On Thu, Mar 15, 2012 at 9:48 PM, Tres Seaver
>> wrote:
>>> On 03/13/2012 06:49 PM, Nick Coghlan wrote:
On Wed, Mar 14, 2012 at 8:08 AM, Guido van Rossum
wrote:
> If you can solv
Hi Guido,
Let me start with thanking you for your long reply. It has clarified
some points to me, but I am still not certain about some others. I
hope I can clarify why I'm confused about this issue in the following.
First of all, let me clarify that I wrote my original mail not as 'the
guy who w
OK, how about using encoding=bytes (yes, the type object!)? Or 'bytes' ?
--Guido van Rossum (sent from Android phone)
On Mar 16, 2012 2:19 PM, "Merlijn van Deen" wrote:
> Hi Guido,
>
> Let me start with thanking you for your long reply. It has clarified
> some points to me, but I am still not ce
On 17 March 2012 00:57, Guido van Rossum wrote:
> OK, how about using encoding=bytes (yes, the type object!)? Or 'bytes' ?
encoding=bytes makes (at least intuitive) sense to me;
encoding='bytes' would imply there is an encoding with name 'bytes'
that somehow does b''.decode('bytes')=b'', and woul
Guido van Rossum, 17.03.2012 00:57:
> OK, how about using encoding=bytes (yes, the type object!)? Or 'bytes' ?
In lxml, there was an "encoding=unicode" option that would let the
XML/HTML/text serialisation function return a Unicode string. This was
eventually deprecated in favour of "encoding='uni
On 17 March 2012 10:43, Stefan Behnel wrote:
> In lxml, there was an "encoding=unicode" option that would let the
> XML/HTML/text serialisation function return a Unicode string. This was
> eventually deprecated in favour of "encoding='unicode'" when ElementTree
> gained this feature as well some y
Merlijn van Deen, 17.03.2012 15:20:
> On 17 March 2012 10:43, Stefan Behnel wrote:
>> In lxml, there was an "encoding=unicode" option that would let the
>> XML/HTML/text serialisation function return a Unicode string. This was
>> eventually deprecated in favour of "encoding='unicode'" when ElementT
One reason to use 'bytes' instead of bytes is that it is a string that
can be specified e.g. in a config file.
On Sat, Mar 17, 2012 at 7:28 AM, Stefan Behnel wrote:
> Merlijn van Deen, 17.03.2012 15:20:
>> On 17 March 2012 10:43, Stefan Behnel wrote:
>>> In lxml, there was an "encoding=unicode" o
17.03.12 17:00, Guido van Rossum написав(ла):
One reason to use 'bytes' instead of bytes is that it is a string that
can be specified e.g. in a config file.
Thus, there are no reasons to use bytes instead of 'bytes'.
___
Python-Dev mailing list
Pytho
On 17 March 2012 16:28, Serhiy Storchaka wrote:
> Thus, there are no reasons to use bytes instead of 'bytes'.
Aesthetics ;-)
I've implemented the encoding="bytes" version [1]. Thank you all for your input!
Merlijn
[1] http://bugs.python.org/issue6784#msg156166
__
20 matches
Mail list logo