bugraoz93 commented on code in PR #43102:
URL: https://github.com/apache/airflow/pull/43102#discussion_r1815559254


##########
airflow/api_fastapi/core_api/serializers/connections.py:
##########
@@ -24,19 +24,24 @@
 from airflow.utils.log.secrets_masker import redact
 
 
-class ConnectionResponse(BaseModel):
+class ConnectionBase(BaseModel):
     """Connection serializer for responses."""
 
-    connection_id: str = Field(serialization_alias="connection_id", 
validation_alias="conn_id")
     conn_type: str
-    description: str | None
-    host: str | None
-    login: str | None
-    schema_: str | None = Field(alias="schema")
-    port: int | None
-    extra: str | None
-
-    @field_validator("extra", mode="before")
+    description: str | None = Field(default=None)
+    host: str | None = Field(default=None)
+    login: str | None = Field(default=None)
+    schema_: str | None = Field(None, alias="schema")
+    port: int | None = Field(default=None)
+    extra: str | None = Field(default=None)
+
+
+class ConnectionResponse(ConnectionBase):

Review Comment:
   I have adjusted the code accordingly and included the `significant` 
fragment. Please check again when you have time :)



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to