pierrejeambrun commented on code in PR #55702:
URL: https://github.com/apache/airflow/pull/55702#discussion_r2355883197


##########
airflow-core/src/airflow/api_fastapi/core_api/datamodels/assets.py:
##########
@@ -160,6 +160,20 @@ class QueuedEventCollectionResponse(BaseModel):
     total_entries: int
 
 
+class CreateAssetBody(StrictBaseModel):
+    """Create asset request."""
+
+    name: str = Field(..., min_length=1, max_length=1500)
+    uri: str = Field(..., min_length=1, max_length=1500)
+    group: str = Field(default="", max_length=1500)

Review Comment:
   You don't need to do that. 
   
   The DB will refuse such wrong input (if strings are too long),  then the AIP 
& UI should gracefully handle and display this error.
   
   Can you update and confirm please?
   
   ```suggestion
       name: str
       uri: str
       group: str
   ```



-- 
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