The brake pedal switch connector (usually a 4-pin connector, brown or black) can get wet from wet shoes or leaking windshield seals. Corrosion on pins leads to intermittent signals.
Replace in this order (after confirming wiring good): renault dtc f00316 work
Knowing the cause is half the repair work. Here are the frequent culprits on Renault vehicles. The brake pedal switch connector (usually a 4-pin