Not your fault -- from Python/dbmmodule.c:
static struct methodlist dbm_methods[] = {
{"keys", (method)dbm_keys},
{"has_key", (method)dbm_has_key},
{NULL, NULL} /* sentinel */
};
I.e., dbm dicts support only "keys" and "has_key" methods. Guess you
could extend the C implementation, or write Python functions to fake the
effect building on keys(), or the latter but disguise them as methods of
a dbm wrapper class written in Python.
health-and-industry-hand-in-hand-ly y'rs - tim
Tim Peters tim@ksr.com
not speaking for Kendall Square Research Corp