Skip to content

Upgrade to Airflow 3.0.2 #159

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 11 commits into
base: master
Choose a base branch
from
Open

Upgrade to Airflow 3.0.2 #159

wants to merge 11 commits into from

Conversation

Lee-W
Copy link
Member

@Lee-W Lee-W commented Jun 7, 2025

Types of changes

  • New feature
  • Refactoring
  • Breaking change (any change that would cause existing functionality to not work as expected)
  • Documentation Update

Description

  • Update to airflow 3.0.2
    • build(pyproject.toml,Dockerfile): upgrade to airflow 3.0.2
    • feat(patch): update migration patch to 3.0.2 version
      • this includes the fixes that will be released in 3.0.3
    • fix(airflow.cfg): migrate to airflow 3
    • build(gitignore): add logs and simple_auth_manager_passwords.json.generated
    • build(docker-compose)
      • add dag-processor and rename airflow-related component
      • set up health checks for each airflow component
    • fix(dags)
      • replace schedule_interval as schedule since it's changed in airflow 3
      • upgrade to Airflow 3 syntax using ruff==0.11.13 AIR rules (basically just some import update)
    • feat: add apache-airflow-providers-fab for user management
      • it used to be the default in past airflow version, but it needs to be installed to enable it
  • feat(dags)
    • rewrite airflow-log-cleanup as airflow_log_cleanup
    • remove airflow-db-cleanup as db access is forbidden now. also discussed in the last meeting, this is not our bottleneck

Checklist

  • Add test cases to all the changes you introduce
  • Run make lint and make test locally to ensure all linter checks and testing pass
  • Update the documentation if necessary

Steps to Test This Pull Request

Expected behavior

Related Issue

Additional context

After this is merged and deployed, we'll need to do the following things.

  1. Disable the currently active dags and keep a record of the list.
  2. Back up the database.
  3. Upgrade the database.
  4. Delete the record of airflow-db-cleanup and airflow-log-cleanup (the new one is airflow_log_cleanup, keeping the old one can be confusing)
  5. Re-enable the dags that were previously turned on.

@Lee-W
Copy link
Member Author

Lee-W commented Jun 7, 2025

This PR is based on #158.

@Lee-W
Copy link
Member Author

Lee-W commented Jun 7, 2025

@henry410213028 henry410213028 force-pushed the upgrade-to-airflow-3 branch from c398232 to c423b49 Compare June 8, 2025 01:10
@Lee-W
Copy link
Member Author

Lee-W commented Jun 8, 2025

the root cause of 1 is that older dag run can have data_interval_start, data_interval_end and conf as none

@Lee-W
Copy link
Member Author

Lee-W commented Jun 8, 2025

the root cause of 1 is that older dag run can have data_interval_start, data_interval_end and conf as none

Fortunately, the conf part is fixed in 3.0.2. still have the data_interval part needs to be taken care

@Lee-W Lee-W force-pushed the upgrade-to-airflow-3 branch from c423b49 to 2e1b760 Compare June 8, 2025 07:27
@Lee-W
Copy link
Member Author

Lee-W commented Jun 8, 2025

  1. is pretty much resolved. 2 should be an easy one. We're close to Airflow 3 ready

@Lee-W Lee-W changed the title Upgrade to airflow 3 Upgrade to Airflow 3.0.1 Jun 8, 2025
@Lee-W Lee-W changed the title Upgrade to Airflow 3.0.1 Upgrade to Airflow 3 Jun 8, 2025
@Lee-W Lee-W force-pushed the upgrade-to-airflow-3 branch from ac460e3 to 47c6fd5 Compare June 14, 2025 04:27
@Lee-W Lee-W changed the title Upgrade to Airflow 3 Upgrade to Airflow 3.0.2 Jun 15, 2025
@Lee-W Lee-W marked this pull request as ready for review June 15, 2025 13:53
@Lee-W Lee-W requested a review from henry410213028 June 15, 2025 13:56
@Lee-W Lee-W force-pushed the upgrade-to-airflow-3 branch from cd2bd71 to 5f75a86 Compare June 15, 2025 14:12
@Lee-W
Copy link
Member Author

Lee-W commented Jun 15, 2025

Screenshot 2025-06-15 at 22-13-48 Airflow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant