Add experimental db.py
write the initial build_db_tree function.
Use ipdb and weakref to prove that expire works.
Add CursorKind to the DB.
Add partial DB support for type.