When changing the 'Match value' of a 'Wait for' action, the change does mark the recording as dirty and therefore does not regenerate the code when running the recording.
- Add recording step 'Wait for'
- Change it to AttributeEqual
- Set Match name to 'Enabled'
- Run the recording
- Change the Match value to either true or false (depending ont the associated repo item)
- Run the recording
The execution still fails with an error saying that value for 'Enabled' does not match expected value 'yourValue'.
I've seen this problem in 10.1.5 and 10.2.1.