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 vstinner
Recipients Aaron.Meurer, cheryl.sabella, r.david.murray, rhettinger, serhiy.storchaka, vstinner
Date 2017-12-14.16:28:40
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1513268920.77.0.213398074469.issue32300@psf.upfronthosting.co.za>
In-reply-to
Content
Currently, repr(Shelf.keys()) doesn't dump the content of the shelf:

>>> import pickle, shelve
>>> s=shelve.Shelf({b'key': pickle.dumps('value')})
>>> k=s.keys()
>>> k
KeysView(<shelve.Shelf object at 0x7fba1f6189b0>)
>>> list(k)
['key']
>>> list(s.values())
['value']

I understand that changing KeysView.__repr__() changes repr(Shelf.keys()) behaviour.
History
Date User Action Args
2017-12-14 16:28:40vstinnersetrecipients: + vstinner, rhettinger, r.david.murray, Aaron.Meurer, serhiy.storchaka, cheryl.sabella
2017-12-14 16:28:40vstinnersetmessageid: <1513268920.77.0.213398074469.issue32300@psf.upfronthosting.co.za>
2017-12-14 16:28:40vstinnerlinkissue32300 messages
2017-12-14 16:28:40vstinnercreate