搁置模块的leveldb后端
leveldb-shelve的Python项目详细描述
python搁置模块的leveldb后端
安装
pip install leveldb-shelve
用法
import leveldb_shelve
with leveldb_shelve.open("/tmp/db_path") as d:
d["a"] = {"c": "CCC"}
print(d["a"])
del d["a"]
# see shelve docs for details https://docs.python.org/3.8/library/shelve.html