Hi,
I have the same problem. Have you managed to solve it?
This was my issue too. I opened the sonoff and connected the sensor without the container and it worked, so I removed the 4 screws and pushed the board as near as possible to the side of the jack connector then closed it back and now I'm able to insert the jack even when it is closed in the container.
Maybe you have same issue as I had. The whole in white plastic casing was too small and it did not let connector to plug in fully. After making hole bigger and pushing connector deeper it works.
Osman İNAN