Staging
v0.5.0
https://github.com/python/cpython
Raw File
Tip revision: 07a4a3851d29eb117508dd292ee347db33b50a1a authored by Barry Warsaw on 21 August 2008, 01:15:08 UTC
Bump to 2.6b3.
Tip revision: 07a4a38
dbhash.py
"""Provide a (g)dbm-compatible interface to bsddb.hashopen."""

import sys
try:
    import bsddb
except ImportError:
    # prevent a second import of this module from spuriously succeeding
    del sys.modules[__name__]
    raise

__all__ = ["error","open"]

error = bsddb.error                     # Exported for anydbm

def open(file, flag = 'r', mode=0666):
    return bsddb.hashopen(file, flag, mode)
back to top