For analysis of the first narration, please refer to:
Discussion 31467 • Reply 31498
The second narration doesn’t state who that woman was in relation to this man. It doesn’t even state any connection between his deed and the revelation of the verse – they could very well be two non-corelated events.