Serhiy Storchaka added the comment:
As a workaround you can make Struct pickleable:
from struct import Struct
import copy, copyreg
def pickle_struct(s):
return Struct, (s.format,)
copyreg.pickle(Struct, pickle_struct)
s1 = Struct('
mesheb82 added the comment:
Thank you.
On Wed, Feb 22, 2017 at 9:22 PM, Serhiy Storchaka
wrote:
>
> Serhiy Storchaka added the comment:
>
> > When I run the following code on Windows/Linux for < Python 3.6, I have
> no problems.
>
> You have a problem. Did you try to
Serhiy Storchaka added the comment:
> When I run the following code on Windows/Linux for < Python 3.6, I have no
> problems.
You have a problem. Did you try to use the copied object? It is a broken Struct
object.
>>> copied = copy.deepcopy(this_fails)
>>> copied.format
>>> copied.size
-1
>>>
New submission from mesheb82:
When I run the following code on Windows/Linux for < Python 3.6, I have no
problems. When I run in Python 3.6.0, I get the subsequent traceback.
I checked the release notes and only saw the following struct module note
related to half-floats: Issue #11734
from