This is an automated email from the ASF dual-hosted git repository.
potiuk pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/main by this push:
new 348b61ec465 Fix formatting for backport failure message. (#44392)
348b61ec465 is described below
commit 348b61ec465423a7b9531907eb1bbc48811f8e94
Author: Jarek Potiuk <[email protected]>
AuthorDate: Tue Nov 26 22:05:00 2024 +0000
Fix formatting for backport failure message. (#44392)
---
dev/backport/update_backport_status.py | 55 +++++++++++++++++-----------------
1 file changed, 28 insertions(+), 27 deletions(-)
diff --git a/dev/backport/update_backport_status.py
b/dev/backport/update_backport_status.py
index a0354e07ac4..c7317d1f37b 100644
--- a/dev/backport/update_backport_status.py
+++ b/dev/backport/update_backport_status.py
@@ -41,33 +41,34 @@ def get_success_comment(branch: str, pr_url: str,
pr_number: str):
def get_failure_comment(branch: str, commit_sha_url: str, commit_sha: str):
commit_shield_url =
f"https://img.shields.io/badge/Commit-{commit_sha[:7]}-red"
- comment = f"""### Backport failed to create: {branch}. View the failure
log <a
href='https://github.com/{os.getenv("REPOSITORY")}/actions/runs/{os.getenv("RUN_ID")}'>
Run details </a>\n\n<table>
- <tr>
- <th>Status</th>
- <th>Branch</th>
- <th>Result</th>
- </tr>
- <tr>
- <td>❌</td>
- <td>{branch}</td>
- <td><a href="{commit_sha_url}"><img src='{commit_shield_url}'
alt='Commit Link'></a></td>
- </tr>
- </table>
-
- You can attempt to backport this manually by running:
-
- ```bash
- cherry_picker {commit_sha[:7]} {branch}
- ```
-
- This should apply the commit to the {branch} branch and leave the
commit in conflict state marking
- the files that need manual conflict resolution.
-
- After you have resolved the conflicts, you can continue the backport
process by running:
-
- ```bash
- cherry_picker --continue
- ```
+ comment = f"""### Backport failed to create: {branch}. View the failure
log <a
href='https://github.com/{os.getenv("REPOSITORY")}/actions/runs/{os.getenv("RUN_ID")}'>
Run details </a>\n
+<table>
+ <tr>
+ <th>Status</th>
+ <th>Branch</th>
+ <th>Result</th>
+ </tr>
+ <tr>
+ <td>❌</td>
+ <td>{branch}</td>
+ <td><a href="{commit_sha_url}"><img src='{commit_shield_url}'
alt='Commit Link'></a></td>
+ </tr>
+</table>
+
+You can attempt to backport this manually by running:
+
+```bash
+cherry_picker {commit_sha[:7]} {branch}
+```
+
+This should apply the commit to the {branch} branch and leave the commit in
conflict state marking
+the files that need manual conflict resolution.
+
+After you have resolved the conflicts, you can continue the backport process
by running:
+
+```bash
+cherry_picker --continue
+```
"""
return comment