-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Fixes #18150 : change replaced dict by model_dump #18108
base: main
Are you sure you want to change the base?
Conversation
Hi there 👋 Thanks for your contribution! The OpenMetadata team will review the PR shortly! Once it has been labeled as Let us know if you need any help! |
The Python checkstyle failed. Please run You can install the pre-commit hooks with |
Quality Gate passed for 'open-metadata-airflow-apis'Issues Measures |
@@ -166,7 +166,7 @@ def get_columns(self, connection, table_name, schema=None, **kw): | |||
if col_type in {"array", "struct", "map"}: | |||
col_name = f"`{col_name}`" if "." in col_name else col_name | |||
try: | |||
rows = dict( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kuma0128 I don't think we need to replace these once. this is python native dict
and not pydantic dict
. The pydantic dict
would be something like PydanticModel.dict()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kuma0128 we just need to replace the dict method of a Pydantic model not the python native dict
Describe your changes:
Fixes #18150
The
dict
method is deprecated; usemodel_dump
instead. Deprecated in Pydantic V2.0 to be removed in V3.0Type of change:
Checklist:
Fixes <issue-number>: <short explanation>