Updated errors format
Fixed log creation