Fix: Prevent Breeze crash when self-upgrade check fails#65656
Merged
potiuk merged 3 commits intoapache:mainfrom Apr 22, 2026
Merged
Fix: Prevent Breeze crash when self-upgrade check fails#65656potiuk merged 3 commits intoapache:mainfrom
potiuk merged 3 commits intoapache:mainfrom
Conversation
potiuk
approved these changes
Apr 22, 2026
Contributor
Backport successfully created: v3-2-testNote: As of Merging PRs targeted for Airflow 3.X In matter of doubt please ask in #release-management Slack channel.
|
Cloud-Architect-Emma
pushed a commit
to Cloud-Architect-Emma/airflow
that referenced
this pull request
Apr 30, 2026
* Fix: Prevent Breeze crash when self-upgrade check fails * test: add unit tests for Breeze self-upgrade check * style: rename test file and update breeze images
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Breeze used to crash with a
CalledProcessErrorwhen it was not installed as a globaluv toolor whenuvwas missing. This PR makes the self-upgrade check robust to ensure Breeze continues to function normally even if the check fails.Changes
Changed
check=Truetocheck=Falseinsubprocess.runto prevent crashing on non-zero exit codes (e.g., when Breeze is installed in a venv, not as a tool).Added exception handling for
FileNotFoundErrorto handle environments where uv is not installed.Added unit tests to verify that Breeze continues execution if the upgrade check fails.
Related Issue
closes: #65651
Tests Performed
We have verified the fix through both manual and automated testing.
1. Manual Verification
I confirmed that the crash no longer occurs when running Breeze in a uv venv environment without global tool installation.
2. Automated Unit Tests
I added new unit tests to dev/breeze/tests/test_path_utils.py to mock
FileNotFoundErrorandsubprocess.CalledProcessError(return code 1) to ensure the function returnsFalseand Breeze does not crash.Test Execution Results:

Was generative AI tooling used to co-author this PR?
Generated-by: Gemini following the guidelines
{pr_number}.significant.rst, in airflow-core/newsfragments. You can add this file in a follow-up commit after the PR is created so you know the PR number.