Measurement distortion and missing contingencies in optimal contracts