Skip to content
This repository has been archived by the owner on Jun 28, 2024. It is now read-only.

Fix pydantic ValidationError due to wrong default type #20

Merged
merged 5 commits into from
Dec 4, 2023

Conversation

ckaipf
Copy link
Contributor

@ckaipf ckaipf commented Nov 30, 2023

I am currently implementing the same in ekss, as it is testing the Vault config a type problem with the default None has occurred. Should we implement this as suggested in this PR or with Optional[str] and Optional[SecretStr] and default is None?

@coveralls
Copy link

coveralls commented Nov 30, 2023

Pull Request Test Coverage Report for Build 7084458044

  • 4 of 6 (66.67%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 81.871%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/fis/adapters/outbound/vault/client.py 4 6 66.67%
Totals Coverage Status
Change from base Build 7003274308: 0.0%
Covered Lines: 280
Relevant Lines: 342

💛 - Coveralls

@ckaipf ckaipf marked this pull request as draft November 30, 2023 16:33
@ckaipf ckaipf requested review from mephenor and Cito November 30, 2023 16:33
Copy link
Member

@Cito Cito left a comment

Choose a reason for hiding this comment

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

I'd rather leave None as default and change the type to Optional[...].

@ckaipf ckaipf changed the title Fix pydantic due to wrong default type Fix pydantic ValidationError due to wrong default type Dec 1, 2023
@ckaipf ckaipf force-pushed the fix-default-validation-error branch from b7e5ea5 to 5884d57 Compare December 1, 2023 10:19
@ckaipf ckaipf marked this pull request as ready for review December 1, 2023 14:38
@Cito
Copy link
Member

Cito commented Dec 1, 2023

Looks good now, but the openapi.yaml still needs to be updated.

Cito
Cito previously approved these changes Dec 1, 2023
@ckaipf ckaipf merged commit cf73c14 into main Dec 4, 2023
8 checks passed
@ckaipf ckaipf deleted the fix-default-validation-error branch December 4, 2023 15:00
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants