Based on the research, I can provide some important context about the UI notifications behavior:
1. The UI notifications feature is indeed handled differently from notification blocks, and it appears the behavior you're seeing in 2.20 (multiple notifications for retries) might be related to how state transitions are being handled in newer versions.
2. In the UI notifications settings, you can configure notifications based on state transitions. When you set it up for "Failed" state, it's responding to each time a flow run enters that state - which includes both temporary failures during retries and the final failure state.
To address this, you have a few options:
1. Short-term workaround: You could modify your flow to use a notification block instead of UI notifications, which would give you more control over when notifications are sent.
2. Report the issue: Since this appears to be a behavior change between versions that affects user experience, it would be valuable to report this as an issue on GitHub. The fact that 2.14.13 handled this more elegantly (single notification) suggests this might be unintended behavior in 2.20.
Would you like me to:
1. Help you set up a notification block as an alternative solution?
2. Help you draft a GitHub issue to report this behavior change?
3. Look into any other potential workarounds?
Also, it would be helpful to know if you're using any specific criteria in your notification settings (like specific tags or flow names) to better understand your setup.