You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by pi...@apache.org on 2024/11/14 10:29:45 UTC

(airflow) branch main updated: Remove ORM references from datamodels for assets (#44010)

This is an automated email from the ASF dual-hosted git repository.

pierrejeambrun pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/main by this push:
     new b00a81000b1 Remove ORM references from datamodels for assets (#44010)
b00a81000b1 is described below

commit b00a81000b1efe7c47a4c0e8a6167a0718dc909e
Author: Amogh Desai <am...@gmail.com>
AuthorDate: Thu Nov 14 15:59:35 2024 +0530

    Remove ORM references from datamodels for assets (#44010)
---
 airflow/api_fastapi/core_api/datamodels/assets.py      | 6 +++---
 airflow/api_fastapi/core_api/openapi/v1-generated.yaml | 6 +++---
 airflow/ui/openapi-gen/requests/schemas.gen.ts         | 9 +++------
 airflow/ui/openapi-gen/requests/types.gen.ts           | 6 +++---
 4 files changed, 12 insertions(+), 15 deletions(-)

diff --git a/airflow/api_fastapi/core_api/datamodels/assets.py b/airflow/api_fastapi/core_api/datamodels/assets.py
index 85e41ff7b56..1295b33fbf7 100644
--- a/airflow/api_fastapi/core_api/datamodels/assets.py
+++ b/airflow/api_fastapi/core_api/datamodels/assets.py
@@ -23,7 +23,7 @@ from pydantic import BaseModel, Field
 
 
 class DagScheduleAssetReference(BaseModel):
-    """Serializable version of the DagScheduleAssetReference ORM SqlAlchemyModel."""
+    """DAG schedule reference serializer for assets."""
 
     dag_id: str
     created_at: datetime
@@ -31,7 +31,7 @@ class DagScheduleAssetReference(BaseModel):
 
 
 class TaskOutletAssetReference(BaseModel):
-    """Serializable version of the TaskOutletAssetReference ORM SqlAlchemyModel."""
+    """Task outlet reference serializer for assets."""
 
     dag_id: str
     task_id: str
@@ -40,7 +40,7 @@ class TaskOutletAssetReference(BaseModel):
 
 
 class AssetAliasSchema(BaseModel):
-    """Serializable version of the AssetAliasSchema ORM SqlAlchemyModel."""
+    """Asset alias serializer for assets."""
 
     id: int
     name: str
diff --git a/airflow/api_fastapi/core_api/openapi/v1-generated.yaml b/airflow/api_fastapi/core_api/openapi/v1-generated.yaml
index b99b389de51..b5dc0db0741 100644
--- a/airflow/api_fastapi/core_api/openapi/v1-generated.yaml
+++ b/airflow/api_fastapi/core_api/openapi/v1-generated.yaml
@@ -3650,7 +3650,7 @@ components:
       - id
       - name
       title: AssetAliasSchema
-      description: Serializable version of the AssetAliasSchema ORM SqlAlchemyModel.
+      description: Asset alias serializer for assets.
     AssetCollectionResponse:
       properties:
         assets:
@@ -4900,7 +4900,7 @@ components:
       - created_at
       - updated_at
       title: DagScheduleAssetReference
-      description: Serializable version of the DagScheduleAssetReference ORM SqlAlchemyModel.
+      description: DAG schedule reference serializer for assets.
     DagStatsCollectionResponse:
       properties:
         dags:
@@ -5800,7 +5800,7 @@ components:
       - created_at
       - updated_at
       title: TaskOutletAssetReference
-      description: Serializable version of the TaskOutletAssetReference ORM SqlAlchemyModel.
+      description: Task outlet reference serializer for assets.
     TaskResponse:
       properties:
         task_id:
diff --git a/airflow/ui/openapi-gen/requests/schemas.gen.ts b/airflow/ui/openapi-gen/requests/schemas.gen.ts
index 7bf8f4b0296..8a8a50bb743 100644
--- a/airflow/ui/openapi-gen/requests/schemas.gen.ts
+++ b/airflow/ui/openapi-gen/requests/schemas.gen.ts
@@ -103,8 +103,7 @@ export const $AssetAliasSchema = {
   type: "object",
   required: ["id", "name"],
   title: "AssetAliasSchema",
-  description:
-    "Serializable version of the AssetAliasSchema ORM SqlAlchemyModel.",
+  description: "Asset alias serializer for assets.",
 } as const;
 
 export const $AssetCollectionResponse = {
@@ -2012,8 +2011,7 @@ export const $DagScheduleAssetReference = {
   type: "object",
   required: ["dag_id", "created_at", "updated_at"],
   title: "DagScheduleAssetReference",
-  description:
-    "Serializable version of the DagScheduleAssetReference ORM SqlAlchemyModel.",
+  description: "DAG schedule reference serializer for assets.",
 } as const;
 
 export const $DagStatsCollectionResponse = {
@@ -3327,8 +3325,7 @@ export const $TaskOutletAssetReference = {
   type: "object",
   required: ["dag_id", "task_id", "created_at", "updated_at"],
   title: "TaskOutletAssetReference",
-  description:
-    "Serializable version of the TaskOutletAssetReference ORM SqlAlchemyModel.",
+  description: "Task outlet reference serializer for assets.",
 } as const;
 
 export const $TaskResponse = {
diff --git a/airflow/ui/openapi-gen/requests/types.gen.ts b/airflow/ui/openapi-gen/requests/types.gen.ts
index c4eee6b97c2..5267c193f48 100644
--- a/airflow/ui/openapi-gen/requests/types.gen.ts
+++ b/airflow/ui/openapi-gen/requests/types.gen.ts
@@ -22,7 +22,7 @@ export type AppBuilderViewResponse = {
 };
 
 /**
- * Serializable version of the AssetAliasSchema ORM SqlAlchemyModel.
+ * Asset alias serializer for assets.
  */
 export type AssetAliasSchema = {
   id: number;
@@ -457,7 +457,7 @@ export type DagRunType =
   | "asset_triggered";
 
 /**
- * Serializable version of the DagScheduleAssetReference ORM SqlAlchemyModel.
+ * DAG schedule reference serializer for assets.
  */
 export type DagScheduleAssetReference = {
   dag_id: string;
@@ -809,7 +809,7 @@ export type TaskInstanceStateCount = {
 };
 
 /**
- * Serializable version of the TaskOutletAssetReference ORM SqlAlchemyModel.
+ * Task outlet reference serializer for assets.
  */
 export type TaskOutletAssetReference = {
   dag_id: string;