add validation on gap widget initialization.