check the engine grounds from engine to frame there are probably some ground studs on the inside of the frame rails that will have several wires attached they can get corrosion and cause this problem
also the coolant sensor works from resistance in the coolant to determine coolant level if it has been a long time sense the coolant has been changed or if it has been contaminated this may not be the answer but it is something to check. the check engine light on will not harm the engine as long as the engine temp is ok but it may depending on the ecm is programed it may derate the engine power