> Guido> - Use "exec ... in dict" to avoid having to walk on eggshells; > Guido> locals no don't have to start with underscore. > > Thanks. I have just been incredibly short on time lately. You're welcome. > Guido> - Only test dbhash if bsddb can be imported. (Wonder if there > Guido> are more like this?) > > Alpha testing should pick those up, yes? ;-) Yes. :-) > Guido> ! try: > Guido> ! import bsddb > Guido> ! except ImportError: > Guido> ! if verbose: > Guido> ! print "can't import bsddb, so skipping dbhash" > Guido> ! else: > Guido> ! check_all("dbhash") > > Instead of having to know that dbhash includes bsddb, shouldn't dbhash be > the module that's imported here? I think I saw a complaint about this that specifically said that when dbhash is imported when bsddb can't be imported, an incomplete dbhash is left behind in sys.modules, and then a second import of dbhash will succeed -- but of course it will define no objects. Since dbhash may be imported elsewhere, testing for bsddb is safer. --Guido van Rossum (home page: http://www.python.org/~guido/)
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4