I am not sure how you know they are related.
The auto-sensing of wipers is based on LED reflection.
Rain-X creates a thin coating on windshield on the outside, supposedly transparent.
Could that be just a coincident?
I learned my lesson the hard way with this issue as well. It will take a few weeks but will eventually wear off. Next time you apply RainX be careful not to apply to the censer located at the top center of the windshield (Above the rear view mirror) and you should be good to go!