Skip to content

Build python from source for CI - #52265

Merged
potiuk merged 11 commits into
apache:mainfrom
aritra24:install_python_from_source
Jul 5, 2025
Merged

potiuk merged 11 commits into
apache:mainfrom
aritra24:install_python_from_source

Conversation

@aritra24

@aritra24 aritra24 commented Jun 25, 2025 •

Copy link
Copy Markdown
Collaborator

closes: #52106

Builds python from source, also installs
golang from official distribution. Does
both of these for the ci image only.


^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

Builds python from source, also installs
golang from official distribution. Does
both of these for the ci image only.

@potiuk potiuk left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great and is IMHO "fast enough" - enough to merge and try it even now in CI image

aritra24 added 2 commits June 30, 2025 22:56
Adds support for using the airflow api to fetch
the newest python patch version available for specific
major_minor pair
@aritra24
aritra24 marked this pull request as ready for review June 30, 2025 17:38
@aritra24 aritra24 changed the title Draft: Build python from source Build python from source Jun 30, 2025
Comment thread .github/workflows/basic-tests.yml Resolved

@potiuk potiuk left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really nice - with one caveat only - that we should add golang in a similar fashion as uv

@potiuk

potiuk commented Jul 4, 2025

Copy link
Copy Markdown
Member

VEEERY NICE!

@potiuk

potiuk commented Jul 4, 2025

Copy link
Copy Markdown
Member

once we play with it in CI - we can do the next step and apply it to PROD images :) Looks really, really good - thanks to that our PROD image will have a chance to catch-up way faster with some 3rd-party CVEs.

@potiuk

potiuk commented Jul 4, 2025

Copy link
Copy Markdown
Member

@aritra24
Fixed go version sorting in pre_commit install
He he ... Classic !

@aritra24

aritra24 commented Jul 4, 2025

Copy link
Copy Markdown
Collaborator Author

Versions are hard 🙃 🥲

@potiuk

potiuk commented Jul 4, 2025

Copy link
Copy Markdown
Member

Versions are hard 🙃 🥲

Dependencies are harder 🙃

@gopidesupavan gopidesupavan left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aritra24 Great work :) just one small nit everything fine. Thanks for doing this.

@gopidesupavan

Copy link
Copy Markdown
Member

Versions are hard 🙃 🥲

Dependencies are harder 🙃

Indeed :)

Updated python fetch request during upgrade to use
github token and fixed the regex
@aritra24 aritra24 changed the title Build python from source Build python from source for CI Jul 5, 2025
Comment thread Dockerfile.ci Resolved
@aritra24

aritra24 commented Jul 5, 2025

Copy link
Copy Markdown
Collaborator Author

Is the redis test failure something we're seeing in other prs as well? I don't think I've touched anything to break redis 🤔

@potiuk

potiuk commented Jul 5, 2025

Copy link
Copy Markdown
Member

Is the redis test failure something we're seeing in other prs as well? I don't think I've touched anything to break redis 🤔

Yeah - we have a flaky redis tests that we need to address.

@potiuk
potiuk merged commit d06a27e into apache:main Jul 5, 2025
@potiuk

potiuk commented Jul 5, 2025

Copy link
Copy Markdown
Member

Let me merge it now - we can always iterate on details ;)

@github-actions

github-actions Bot commented Jul 5, 2025

Copy link
Copy Markdown
Contributor

Backport failed to create: v3-0-test. View the failure log Run details

Status Branch Result
❌ v3-0-test Commit Link

You can attempt to backport this manually by running:

cherry_picker d06a27e v3-0-test

This should apply the commit to the v3-0-test 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:

cherry_picker --continue

potiuk pushed a commit to potiuk/airflow that referenced this pull request Jul 5, 2025
* Draft: Build python from source

Builds python from source, also installs
golang from official distribution. Does
both of these for the ci image only.

* Updates path

* Adds version upgrade check for python version

Adds support for using the airflow api to fetch
the newest python patch version available for specific
major_minor pair

* Updated to use args in dockerfile for python

* Added support for golang upgrade

* Fixed go version sorting in pre_commit install

* Added github token usage and fixed version regex

Updated python fetch request during upgrade to use
github token and fixed the regex

* Updated dockerfile.ci file

(cherry picked from commit d06a27e)
potiuk added a commit to potiuk/airflow that referenced this pull request Jul 5, 2025
@potiuk

potiuk commented Jul 5, 2025

Copy link
Copy Markdown
Member

Hmmm.. We need to revert .. I found some issues with other versions of python :(

potiuk added a commit that referenced this pull request Jul 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Change sources of our docker images

3 participants