This is an automated email from the ASF dual-hosted git repository.

jscheffl 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 93552c2bcb5 Bugfix/skip commit checks on automated ci upgrades (#64856)
93552c2bcb5 is described below

commit 93552c2bcb5815fb5e131e13a56995a7b8e97695
Author: Jens Scheffler <[email protected]>
AuthorDate: Tue Apr 7 23:24:28 2026 +0200

    Bugfix/skip commit checks on automated ci upgrades (#64856)
    
    * Skip pre-commit checks on automated CI tool upgrades
    
    * Skip pre-commit checks on automated CI tool upgrades
    
    * Review feedback, attempt with checks once, collect auto-fixes and commit 
again
    
    * Shorten code
---
 dev/breeze/src/airflow_breeze/commands/ci_commands.py | 18 +++++++++++++++++-
 1 file changed, 17 insertions(+), 1 deletion(-)

diff --git a/dev/breeze/src/airflow_breeze/commands/ci_commands.py 
b/dev/breeze/src/airflow_breeze/commands/ci_commands.py
index a011f7ba6d3..b8d41383713 100644
--- a/dev/breeze/src/airflow_breeze/commands/ci_commands.py
+++ b/dev/breeze/src/airflow_breeze/commands/ci_commands.py
@@ -849,7 +849,23 @@ def upgrade(
 
         run_command(["git", "checkout", "-b", branch_name])
         run_command(["git", "add", "."])
-        run_command(["git", "commit", "-m", f"[{target_branch}] CI: Upgrade 
important CI environment"])
+        try:
+            run_command(
+                ["git", "commit", "--message", f"[{target_branch}] CI: Upgrade 
important CI environment"]
+            )
+        except subprocess.CalledProcessError:
+            console_print("[info]Commit failed, assume some auto-fixes might 
have been made...[/]")
+            run_command(["git", "add", "."])
+            run_command(
+                [
+                    "git",
+                    "commit",
+                    # postpone pre-commit checks to CI, not to fail in 
automation if e.g. mypy changes force code checks
+                    "--no-verify",
+                    "--message",
+                    f"[{target_branch}] CI: Upgrade important CI environment",
+                ]
+            )
 
         # Push the branch to origin (use detected origin or fallback to 
'origin')
         push_remote = origin_remote_name if origin_remote_name else "origin"

Reply via email to