Open
Description
Describe the proposed change(s).
If Renovate attempts a PR automerge, and the attempt fails (e.g. is rejected by the platform), then Renovate should add a PR comment with information about the failure. This comment should remain in place indefinitely, either as-is or potentially being updated if the failure reason changes.
Implementation suggestion:
- Add a new
enum
configuration optionautomergeFailureComment
, which defaults to "never", and also accepts "on-error". - Update the
tryPrAutomerge()
function to return a result, either:- Successful
- Unsuccessful with a description (which may include logs)
- If unsuccessful, the worker layer will then check for the value of
automergeFailureComment
. If set to "never", no comment is added (same as today's functionality). If it's set to "on-error" then the worker should ensure a PR comment with title "Automerge failure notification" and include the failure description passed back from the platform.