Re: in a pickle

2019-03-06 Thread duncan smith
On 07/03/2019 00:18, Ethan Furman wrote: > On 03/06/2019 10:30 AM, duncan smith wrote: > >>  I've been trying to figure out why one of my classes can be >> pickled but not unpickled. (I realise the problem is probably with the >> pickling, but I get the error when I attempt to unpickle.) >> >> A r

Re: in a pickle

2019-03-06 Thread duncan smith
On 06/03/2019 20:24, Peter Otten wrote: > duncan smith wrote: > >> On 06/03/2019 16:14, duncan smith wrote: >>> Hello, >>> I've been trying to figure out why one of my classes can be >>> pickled but not unpickled. (I realise the problem is probably with the >>> pickling, but I get the error

Re: in a pickle

2019-03-06 Thread Ethan Furman
On 03/06/2019 10:30 AM, duncan smith wrote: I've been trying to figure out why one of my classes can be pickled but not unpickled. (I realise the problem is probably with the pickling, but I get the error when I attempt to unpickle.) A relatively minimal example is pasted below. --> import p

Re: in a pickle

2019-03-06 Thread Peter Otten
duncan smith wrote: > On 06/03/2019 16:14, duncan smith wrote: >> Hello, >> I've been trying to figure out why one of my classes can be >> pickled but not unpickled. (I realise the problem is probably with the >> pickling, but I get the error when I attempt to unpickle.) >> >> A relatively

Re: Class Issue`

2019-03-06 Thread Grant Edwards
On 2019-03-06, Marko Rauhamaa wrote: > Rhodri James : >> On 06/03/2019 14:15, Calvin Spealman wrote: C++ (a language I have no respect for) >>> This was uncalled for and inappropriate. Please keep discord civil. >> >> That was the civil version :-) > > C++ is a programming language without fe

Re: in a pickle

2019-03-06 Thread duncan smith
On 06/03/2019 16:14, duncan smith wrote: > Hello, > I've been trying to figure out why one of my classes can be > pickled but not unpickled. (I realise the problem is probably with the > pickling, but I get the error when I attempt to unpickle.) > > A relatively minimal example is pasted bel

RE: in a pickle

2019-03-06 Thread David Raymond
https://docs.python.org/3.7/library/pickle.html#pickling-class-instances includes 2 notes, which I think are the relevant ones: When a class instance is unpickled, its __init__() method is usually not invoked. The default behaviour first creates an uninitialized instance and then restores the s

Re: in a pickle

2019-03-06 Thread duncan smith
[snip] Sorry, this is Python 3.6 on Linux. Duncan -- https://mail.python.org/mailman/listinfo/python-list

Re: Class Issue`

2019-03-06 Thread Marko Rauhamaa
Rhodri James : > On 06/03/2019 14:15, Calvin Spealman wrote: >>> C++ (a language I have no respect for) >> This was uncalled for and inappropriate. Please keep discord civil. > > That was the civil version :-) C++ is a programming language without feelings. It's nobody's ethnicity, sexual orienta

in a pickle

2019-03-06 Thread duncan smith
Hello, I've been trying to figure out why one of my classes can be pickled but not unpickled. (I realise the problem is probably with the pickling, but I get the error when I attempt to unpickle.) A relatively minimal example is pasted below. >>> import pickle >>> class test(dict):

Re: Class Issue`

2019-03-06 Thread Rhodri James
On 06/03/2019 14:44, Chris Angelico wrote: Ouch, did C++ burn you in the past? I've tried and failed to learn the language three times. It's been suggested that my mistake was using Stroustrop's book :-) There just seem to be so much boilerplate and fiddly bits that it quickly gets too com

Re: Class Issue`

2019-03-06 Thread Chris Angelico
On Thu, Mar 7, 2019 at 1:34 AM Rhodri James wrote: > > On 06/03/2019 14:15, Calvin Spealman wrote: > >> C++ (a language I have no respect for) > > This was uncalled for and inappropriate. Please keep discord civil. > > That was the civil version :-) > Ouch, did C++ burn you in the past? IMO it's

Re: Class Issue`

2019-03-06 Thread Rhodri James
On 06/03/2019 14:15, Calvin Spealman wrote: C++ (a language I have no respect for) This was uncalled for and inappropriate. Please keep discord civil. That was the civil version :-) -- Rhodri James *-* Kynesim Ltd -- https://mail.python.org/mailman/listinfo/python-list

Re: Class Issue`

2019-03-06 Thread Calvin Spealman
> C++ (a language I have no respect for) This was uncalled for and inappropriate. Please keep discord civil. On Wed, Mar 6, 2019 at 7:12 AM Rhodri James wrote: > On 05/03/2019 22:39, Milt wrote: > > The following code gives me unusual results - base on experience with > C++. > > > > class Car:

Re: Class Issue`

2019-03-06 Thread Rhodri James
On 05/03/2019 22:39, Milt wrote: The following code gives me unusual results - base on experience with C++. class Car:    # carColor = None    # mileage = None    def __init__(self, color = None, miles = None):   self.mileage = miles   self.carColor = color    def print(self):  

Re: Decodificar base64 en Odoo 12

2019-03-06 Thread Peter Otten
angiielovee...@gmail.com wrote: > El martes, 5 de marzo de 2019, 3:05:07 (UTC-6), Peter Otten escribió: >> angiielovee...@gmail.com wrote: >> >> > El lunes, 4 de marzo de 2019, 11:07:40 (UTC-6), Peter Otten escribió: >> >> Angie GL wrote: >> >> >> >> > Hola a todos, tengo un problema al decodifi