log before the dict lookup