I ran against another issue with shove (see Shove knowing about an object but unable to retrieve it ), but this time I've got a pretty simple repro showing why the dump/load doesn't work.
Looking at the def in C:\Python27\lib\site-packages\shove-0.5.0-py2.7.egg\shove\base.py
for loads/dumps, it refers to ld,optimize in stuf.utils.
How come the below does not work?
>>> from stuf.utils import ld,optimize; d=[{'A':1},{'A':1}]; ld(optimize(d))
[{'A': 1}, {'A': 1}]
>>> from stuf.utils import ld,optimize; d=[{'AA':1},{'A':1}]; ld(optimize(d))
[{'AA': 1}, {'A': 1}]
>>> from stuf.utils import ld,optimize; d=[{'AA':1},{'AA':1}]; ld(optimize(d))
Traceback (most recent call last):
File "<pyshell#5>", line 1, in <module>
from stuf.utils import ld,optimize; d=[{'AA':1},{'AA':1}]; ld(optimize(d))
BadPickleGet: 3
>>>
Thx so much!
It seems that the versions of shove and stuf that are installed with, for example, pip, are not compatible. I was able to download source from github and build both stuf and shove quickly on both OSX and Linux with 2.7.
Resulted in these version numbers being installed:
where pip installs:
so I downgraded, but everything seems to be working okay now.