Skip to content
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

pydantic-v2対応 #9

Open
wants to merge 1 commit into
base: feature/v1
Choose a base branch
from
Open

pydantic-v2対応 #9

wants to merge 1 commit into from

Conversation

jFujiya
Copy link

@jFujiya jFujiya commented Jul 11, 2024

エディタの設定のせいか、全部差分になってしまっているので、修正箇所にコメント入れておきました。
お手隙の際にご確認のほど、よろしくお願い致します。

@jFujiya jFujiya self-assigned this Jul 11, 2024
actual_instance: Union[IdentityProviderSaml]
else:
actual_instance: Any
one_of_schemas: List[str] = Field(TENANTIDENTITYPROVIDERPROPS_ONE_OF_SCHEMAS)
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

const=Trueがpydantic2系では許容されていないので、削除しました。

"tenant_id": obj.get("tenant_id"),
"tenant_name": obj.get("tenant_name"),
"email": obj.get("email"),
"attributes": obj.get("attributes") if isinstance(obj.get("attributes"), dict) else {},
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ユーザー属性が定義されていないとエラーになるので、未設定の時の対応を追記しました。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant