-
Notifications
You must be signed in to change notification settings - Fork 32
⬆️♻️ Updates pydantic repo-wide to the same version and fixes new issues in all services #6882
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
Merged
pcrespov
merged 61 commits into
ITISFoundation:master
from
pcrespov:mai/pydantic-upgrade-repo-wide
Dec 5, 2024
Merged
Changes from all commits
Commits
Show all changes
61 commits
Select commit
Hold shift + click to select a range
64807a1
constraint
pcrespov 26d634c
upgrades to 2.10.2
pcrespov 5da357a
fixes web-server mypy
pcrespov 3b1b0b3
fixes log-level default everywhere
pcrespov d85161d
rm old models
pcrespov 6258409
annotated
pcrespov d7bd68c
mypy
pcrespov db06488
@GitHK please review directorv2 changes
pcrespov ecb5eb2
upgrades faststream everywhere
pcrespov 136db2e
defaults?
pcrespov bb66bb8
api-server
pcrespov 60a743a
annotations
pcrespov 7ead8ec
fixes rut
pcrespov e29f65a
fixes sil
pcrespov 0b5e311
cleanup
pcrespov a2ae61b
settings-library
pcrespov fade298
basic types
pcrespov 3a4491c
api-server
pcrespov 0058325
rm json_serializer option
pcrespov f143ca5
fixes tests
pcrespov bd36009
corrects required
pcrespov 4b61054
api-servier
pcrespov 41b6512
cleanup
pcrespov 4982ae5
Merge branch 'master' into mai/pydantic-upgrade-repo-wide
pcrespov 0bc3eb0
uses AnyHttpUrl
pcrespov e6a8f18
@GitHK review: split tests and adds xfail
pcrespov 7ca6bce
reverts httpurl after tests
pcrespov 081b74b
update oas
pcrespov 02190a7
update
pcrespov be7262a
@sanderegg review: auto-generator and urls
pcrespov e39a580
@GitHK review: checks
pcrespov 7e218eb
@GitHK review: example assert
pcrespov fc5cabc
Merge branch 'master' into mai/pydantic-upgrade-repo-wide
pcrespov 68fac91
spaces
pcrespov 72a7da1
missing after merge
pcrespov 0b83488
fixes director
pcrespov 927b67e
@sanderegg, @GitHK review: import unset constant
pcrespov 0791acd
update
pcrespov 0d55f35
update
pcrespov 36827b1
Merge branch 'master' into mai/pydantic-upgrade-repo-wide
pcrespov 7c0291b
update
pcrespov f1642f1
@GitHK review: wrong fixture
pcrespov 23f54cd
upgrade
pcrespov ba91703
pyaments
pcrespov b16d094
Merge branch 'master' into mai/pydantic-upgrade-repo-wide
pcrespov 2667696
Merge branch 'master' into mai/pydantic-upgrade-repo-wide
pcrespov 9bf15c0
undo
pcrespov cc89dcb
fixes dv2
pcrespov 01b33a5
cleanup
pcrespov 57dcc32
fixes payments
pcrespov b5b684e
fixs webserver
pcrespov 7f76279
fixes warnings
pcrespov 1be53d5
bad imports and oas
pcrespov f6c7e5d
Merge branch 'master' into mai/pydantic-upgrade-repo-wide
pcrespov c2d3389
cleanup
pcrespov a0e817f
Merge branch 'master' into mai/pydantic-upgrade-repo-wide
pcrespov 4555dfb
Merge branch 'master' into mai/pydantic-upgrade-repo-wide
pcrespov 77f2adf
Merge branch 'master' into mai/pydantic-upgrade-repo-wide
pcrespov e449f63
@GitHK review: rename unset
pcrespov 8fcd5b1
@GitHK review: annotations
pcrespov 7148313
Merge branch 'master' into mai/pydantic-upgrade-repo-wide
pcrespov File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
40 changes: 25 additions & 15 deletions
40
packages/models-library/src/models_library/app_diagnostics.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,28 +1,38 @@ | ||
| from typing import Any | ||
| from typing import Annotated, Any | ||
|
|
||
| from common_library.basic_types import DEFAULT_FACTORY | ||
| from pydantic import AnyUrl, BaseModel, Field | ||
|
|
||
|
|
||
| class AppStatusCheck(BaseModel): | ||
| app_name: str = Field(..., description="Application name") | ||
| version: str = Field(..., description="Application's version") | ||
| services: dict[str, Any] = Field( | ||
| default_factory=dict, | ||
| description="Other backend services connected from this service", | ||
| json_schema_extra={"default": {}}, | ||
| ) | ||
| services: Annotated[ | ||
| dict[str, Any], | ||
| Field( | ||
| default_factory=dict, | ||
| description="Other backend services connected from this service", | ||
| json_schema_extra={"default": {}}, | ||
| ), | ||
| ] = DEFAULT_FACTORY | ||
|
|
||
| sessions: dict[str, Any] | None = Field( | ||
| default_factory=dict, | ||
| description="Client sessions info. If single session per app, then is denoted as main", | ||
| json_schema_extra={"default": {}}, | ||
| ) | ||
| sessions: Annotated[ | ||
| dict[str, Any] | None, | ||
| Field( | ||
| default_factory=dict, | ||
| description="Client sessions info. If single session per app, then is denoted as main", | ||
| json_schema_extra={"default": {}}, | ||
| ), | ||
| ] = DEFAULT_FACTORY | ||
|
|
||
| url: AnyUrl | None = Field( | ||
| default=None, | ||
| description="Link to current resource", | ||
| ) | ||
| diagnostics_url: AnyUrl | None = Field( | ||
| default=None, | ||
| description="Link to diagnostics report sub-resource. This MIGHT take some time to compute", | ||
| ) | ||
|
|
||
| diagnostics_url: Annotated[ | ||
| AnyUrl | None, | ||
| Field( | ||
| description="Link to diagnostics report sub-resource. This MIGHT take some time to compute", | ||
| ), | ||
| ] = None |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.