Skip to content

Commit

Permalink
Merge branch 'main' into print_scheduler_call_stack_sigusr2
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeffrharr authored Mar 6, 2025
2 parents b5444b5 + 0b79a47 commit 19df77d
Show file tree
Hide file tree
Showing 165 changed files with 1,466 additions and 511 deletions.
2 changes: 1 addition & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
!docs
!licenses
!providers/
!task_sdk/
!task-sdk/

# Add those folders to the context so that they are available in the CI container
!scripts
Expand Down
2 changes: 1 addition & 1 deletion .github/boring-cyborg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,7 @@ labelPRBasedOnFilePath:
- tests/system/**/*

area:task-sdk:
- task_sdk/**/*
- task-sdk/**/*

area:db-migrations:
- airflow/migrations/versions/*
Expand Down
2 changes: 1 addition & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ updates:
- /clients/python
- /dev/breeze
- /docker_tests
- /task_sdk
- /task-sdk
- /
schedule:
interval: daily
Expand Down
41 changes: 25 additions & 16 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -676,7 +676,7 @@ repos:
name: Sync template context variable refs
language: python
entry: ./scripts/ci/pre_commit/template_context_key_sync.py
files: ^airflow/models/taskinstance\.py$|^task_sdk/src/airflow/sdk/definitions/context\.py$|^docs/apache-airflow/templates-ref\.rst$
files: ^airflow/models/taskinstance\.py$|^task-sdk/src/airflow/sdk/definitions/context\.py$|^docs/apache-airflow/templates-ref\.rst$
- id: check-base-operator-usage
language: pygrep
name: Check BaseOperator core imports
Expand Down Expand Up @@ -1139,14 +1139,6 @@ repos:
additional_dependencies: ['rich>=12.4.4']
pass_filenames: false
files: ^tests/.*\.py$
- id: generate-openapi-spec
name: Generate the FastAPI API spec
language: python
entry: ./scripts/ci/pre_commit/update_fastapi_api_spec.py
pass_filenames: false
files: ^airflow/api_fastapi/.*\.py$|^airflow/auth/managers/simple/.*\.py$|^providers/fab/src/airflow/providers/fab/auth_manager/api_fastapi/.*\.py$
exclude: ^airflow/api_fastapi/execution_api/.*
additional_dependencies: ['rich>=12.4.4']
- id: ts-compile-format-lint-ui
name: Compile / format / lint UI
description: TS types generation / ESLint / Prettier new UI files
Expand Down Expand Up @@ -1182,9 +1174,9 @@ repos:
^tests/ |
^providers/tests/ |
^providers/.*/tests/ |
^task_sdk/src/airflow/sdk/definitions/dag.py$ |
^task_sdk/src/airflow/sdk/execution_time/secrets_masker.py$ |
^task_sdk/src/airflow/sdk/definitions/_internal/node.py$ |
^task-sdk/src/airflow/sdk/definitions/dag.py$ |
^task-sdk/src/airflow/sdk/execution_time/secrets_masker.py$ |
^task-sdk/src/airflow/sdk/definitions/_internal/node.py$ |
^dev/.*\.py$ |
^scripts/.*\.py$ |
^docker_tests/.*$ |
Expand Down Expand Up @@ -1301,7 +1293,7 @@ repos:
provider_packages|
providers/|
scripts|
task_sdk/|
task-sdk/|
tests/dags/test_imports\.py
)
require_serial: true
Expand Down Expand Up @@ -1352,18 +1344,35 @@ repos:
name: Run mypy for Task SDK
language: python
entry: ./scripts/ci/pre_commit/mypy.py --namespace-packages
files: ^task_sdk/src/airflow/sdk/.*\.py$|^task_sdk/tests//.*\.py$
files: ^task-sdk/src/airflow/sdk/.*\.py$|^task-sdk/tests//.*\.py$
require_serial: true
additional_dependencies: ['rich>=12.4.4']
- id: mypy-task-sdk
stages: ['manual']
name: Run mypy for Task SDK (manual)
language: python
entry: ./scripts/ci/pre_commit/mypy_folder.py task_sdk/src/airflow/sdk
entry: ./scripts/ci/pre_commit/mypy_folder.py task-sdk/src/airflow/sdk
pass_filenames: false
files: ^.*\.py$
require_serial: true
additional_dependencies: ['rich>=12.4.4']
- id: generate-openapi-spec
name: Generate the FastAPI API spec
language: python
entry: ./scripts/ci/pre_commit/update_fastapi_api_spec.py
pass_filenames: false
files: ^airflow/api_fastapi/.*\.py$|^airflow/auth/managers/simple/.*\.py$|^providers/fab/src/airflow/providers/fab/auth_manager/api_fastapi/.*\.py$
exclude: ^airflow/api_fastapi/execution_api/.*
additional_dependencies: ['rich>=12.4.4']
- id: ts-compile-format-lint-ui
name: Compile / format / lint UI
description: TS types generation / ESLint / Prettier new UI files
language: node
types_or: [javascript, ts, tsx, yaml, css, json]
files: ^airflow/ui/|^airflow/api_fastapi/core_api/openapi/v1-generated\.yaml$|^airflow/auth/managers/simple/ui/|^airflow/auth/managers/simple/openapi/v1-generated\.yaml$
entry: ./scripts/ci/pre_commit/lint_ui.py
additional_dependencies: ['pnpm@9.7.1']
pass_filenames: false
- id: check-provider-yaml-valid
name: Validate provider.yaml files
entry: ./scripts/ci/pre_commit/check_provider_yaml_files.py
Expand All @@ -1389,7 +1398,7 @@ repos:
- id: generate-tasksdk-datamodels
name: Generate Datamodels for TaskSDK client
language: python
entry: uv run --active --group codegen --project apache-airflow-task-sdk --directory task_sdk -s dev/generate_models.py
entry: uv run --active --group codegen --project apache-airflow-task-sdk --directory task-sdk -s dev/generate_models.py
pass_filenames: false
files: ^airflow/api_fastapi/execution_api/.*\.py$
require_serial: true
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -815,7 +815,7 @@ function install_airflow() {
local installation_command_flags
if [[ ${AIRFLOW_INSTALLATION_METHOD} == "." ]]; then
# When installing from sources - we always use `--editable` mode
installation_command_flags="--editable .[${AIRFLOW_EXTRAS}]${AIRFLOW_VERSION_SPECIFICATION} --editable ./task_sdk --editable ./devel-common"
installation_command_flags="--editable .[${AIRFLOW_EXTRAS}]${AIRFLOW_VERSION_SPECIFICATION} --editable ./task-sdk --editable ./devel-common"
while IFS= read -r -d '' pyproject_toml_file; do
project_folder=$(dirname ${pyproject_toml_file})
installation_command_flags="${installation_command_flags} --editable ${project_folder}"
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile.ci
Original file line number Diff line number Diff line change
Expand Up @@ -585,7 +585,7 @@ function install_airflow() {
local installation_command_flags
if [[ ${AIRFLOW_INSTALLATION_METHOD} == "." ]]; then
# When installing from sources - we always use `--editable` mode
installation_command_flags="--editable .[${AIRFLOW_EXTRAS}]${AIRFLOW_VERSION_SPECIFICATION} --editable ./task_sdk --editable ./devel-common"
installation_command_flags="--editable .[${AIRFLOW_EXTRAS}]${AIRFLOW_VERSION_SPECIFICATION} --editable ./task-sdk --editable ./devel-common"
while IFS= read -r -d '' pyproject_toml_file; do
project_folder=$(dirname ${pyproject_toml_file})
installation_command_flags="${installation_command_flags} --editable ${project_folder}"
Expand Down Expand Up @@ -1001,7 +1001,7 @@ function check_force_lowest_dependencies() {
echo
fi
set -x
uv pip install --python "$(which python)" --resolution lowest-direct --upgrade --editable ".${EXTRA}" --editable "./task_sdk" --editable "./devel-common"
uv pip install --python "$(which python)" --resolution lowest-direct --upgrade --editable ".${EXTRA}" --editable "./task-sdk" --editable "./devel-common"
set +x
}

Expand Down
48 changes: 44 additions & 4 deletions airflow/api_fastapi/core_api/openapi/v1-generated.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -528,6 +528,8 @@ paths:
summary: Get Assets
description: Get assets.
operationId: get_assets
security:
- OAuth2PasswordBearer: []
parameters:
- name: limit
in: query
Expand Down Expand Up @@ -728,6 +730,8 @@ paths:
summary: Get Asset Events
description: Get asset events.
operationId: get_asset_events
security:
- OAuth2PasswordBearer: []
parameters:
- name: limit
in: query
Expand Down Expand Up @@ -847,6 +851,8 @@ paths:
summary: Create Asset Event
description: Create asset events.
operationId: create_asset_event
security:
- OAuth2PasswordBearer: []
requestBody:
required: true
content:
Expand Down Expand Up @@ -891,6 +897,8 @@ paths:
summary: Materialize Asset
description: Materialize an asset by triggering a DAG run that produces it.
operationId: materialize_asset
security:
- OAuth2PasswordBearer: []
parameters:
- name: asset_id
in: path
Expand Down Expand Up @@ -942,6 +950,8 @@ paths:
summary: Get Asset Queued Events
description: Get queued asset events for an asset.
operationId: get_asset_queued_events
security:
- OAuth2PasswordBearer: []
parameters:
- name: asset_id
in: path
Expand Down Expand Up @@ -994,6 +1004,8 @@ paths:
summary: Delete Asset Queued Events
description: Delete queued asset events for an asset.
operationId: delete_asset_queued_events
security:
- OAuth2PasswordBearer: []
parameters:
- name: asset_id
in: path
Expand All @@ -1009,6 +1021,14 @@ paths:
- type: string
- type: 'null'
title: Before
- name: dag_id
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Dag Id
responses:
'204':
description: Successful Response
Expand Down Expand Up @@ -1043,6 +1063,8 @@ paths:
summary: Get Asset
description: Get an asset.
operationId: get_asset
security:
- OAuth2PasswordBearer: []
parameters:
- name: asset_id
in: path
Expand Down Expand Up @@ -1088,12 +1110,16 @@ paths:
summary: Get Dag Asset Queued Events
description: Get queued asset events for a DAG.
operationId: get_dag_asset_queued_events
security:
- OAuth2PasswordBearer: []
parameters:
- name: dag_id
in: path
required: true
schema:
type: string
anyOf:
- type: string
- type: 'null'
title: Dag Id
- name: before
in: query
Expand Down Expand Up @@ -1139,12 +1165,16 @@ paths:
- Asset
summary: Delete Dag Asset Queued Events
operationId: delete_dag_asset_queued_events
security:
- OAuth2PasswordBearer: []
parameters:
- name: dag_id
in: path
required: true
schema:
type: string
anyOf:
- type: string
- type: 'null'
title: Dag Id
- name: before
in: query
Expand Down Expand Up @@ -1194,12 +1224,16 @@ paths:
summary: Get Dag Asset Queued Event
description: Get a queued asset event for a DAG.
operationId: get_dag_asset_queued_event
security:
- OAuth2PasswordBearer: []
parameters:
- name: dag_id
in: path
required: true
schema:
type: string
anyOf:
- type: string
- type: 'null'
title: Dag Id
- name: asset_id
in: path
Expand Down Expand Up @@ -1252,12 +1286,16 @@ paths:
summary: Delete Dag Asset Queued Event
description: Delete a queued asset event for a DAG.
operationId: delete_dag_asset_queued_event
security:
- OAuth2PasswordBearer: []
parameters:
- name: dag_id
in: path
required: true
schema:
type: string
anyOf:
- type: string
- type: 'null'
title: Dag Id
- name: asset_id
in: path
Expand Down Expand Up @@ -2223,6 +2261,8 @@ paths:
description: If dag run is asset-triggered, return the asset events that triggered
it.
operationId: get_upstream_asset_events
security:
- OAuth2PasswordBearer: []
parameters:
- name: dag_id
in: path
Expand Down
Loading

0 comments on commit 19df77d

Please sign in to comment.