Update atexit_hook cookbook to be backward compatible with older pytables versions.