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 lemburg
Recipients HubTou, koobs, lemburg, terry.reedy
Date 2022-03-27.11:54:07
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <2f108553-66aa-6aaf-f3f2-5e53af6fdc4e@egenix.com>
In-reply-to <1648367783.07.0.0967367538655.issue47072@roundup.psfhosted.org>
Content
On 27.03.2022 09:56, Hubert Tournier wrote:
> 
> The storage format used under Windows is completely different from the one used under Unix (or *BSD).

The shelve module uses the dbm module underneath and this will pick
its storage mechanism based on what's available on the platform:

https://docs.python.org/3/library/dbm.html
https://github.com/python/cpython/blob/3.10/Lib/dbm/__init__.py

It's likely that you'll get the dbm.dumb interface on Windows.
On Linux, you typically have one of gdbm or the Berkley DB installed.

dbm.whichdb() will tell you which type of dbm implementation your
files are likely using.

More on the differences of DBM style libs:
http://www.ccl.net/cca/software/UNIX/apache/apacheRH7.0/local-copies/dbm.html

Aside: You are probably better off using SQLite with a pickle
layer to store arbitrary objects. This is much more mature than
the dbm modules.
History
Date User Action Args
2022-03-27 11:54:07lemburgsetrecipients: + lemburg, terry.reedy, koobs, HubTou
2022-03-27 11:54:07lemburglinkissue47072 messages
2022-03-27 11:54:07lemburgcreate