fiddle with logger
cleanup bad encoding handling (part1)
small fix