[FLINK-36900][python] Migrate from conda to uv for managing Python environments for PyFlink #26065
+158
−240
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.
What is the purpose of the change
Given the issues raised in https://issues.apache.org/jira/browse/LEGAL-688, we've decided to move away from using conda.
conda
is being used in Flink in the following ways:To summarise, conda is largely being used for the creation of Python virtual environments for both developers and CI. This PR replaces conda with uv, a fast Python package and virtual environment manager. In the cases where conda was being used to manage non-python packages (for example, installing the
zip
binary in the PyFlink yarn tests) this has instead been changed to use the package manager native to the environment (apt
, in this particular case).Brief change log
conda
withuv
for managing the creation of Python environments and installing Python packages for PyFlink in both testing, wheel building and developer contexts.tox-uv
so thattox
can manage the Python environments it uses viauv
.Verifying this change
This change is already covered by existing tests, such as:
Does this pull request potentially affect one of the following parts:
@Public(Evolving)
: (no)Documentation