logging, fixes #29