-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Issue
Running
ado context an-invalid-context
Works no matter what if the context exists, because no checks are performed whether the context is actually valid or not.
Upon running any other kind of command, however, if the context isn't valid, Pydantic will raise ValidationErrors which will prevent the user from running anything else, even switching context.
Example
(ado-core) alessandropomponio@MacBook-Pro-di-Alessandro ~/D/G/p/ado ((8684a72e))> ado context ap-testing
warnings.warn(
Success! Now using context ap-testing
(ado-core) alessandropomponio@MacBook-Pro-di-Alessandro ~/D/G/p/ado ((8684a72e))> ado upgrade stores
warnings.warn(
ERROR: The provided project context was not valid:
2 validation errors for ProjectContext
metadataStore.mysql.active
Extra inputs are not permitted
For further information visit https://errors.pydantic.dev/2.12/v/extra_forbidden
sslVerify
Extra inputs are not permitted
For further information visit https://errors.pydantic.dev/2.12/v/extra_forbidden
(ado-core) alessandropomponio@MacBook-Pro-di-Alessandro ~/D/G/p/ado ((8684a72e)) [1]> ado context ft-prod
warnings.warn(
ERROR: The provided project context was not valid:
2 validation errors for ProjectContext
metadataStore.mysql.active
Extra inputs are not permitted
For further information visit https://errors.pydantic.dev/2.12/v/extra_forbidden
sslVerify
Extra inputs are not permitted
For further information visit https://errors.pydantic.dev/2.12/v/extra_forbidden
(ado-core) alessandropomponio@MacBook-Pro-di-Alessandro ~/D/G/p/ado ((8684a72e)) [1]> ado context local
warnings.warn(
ERROR: The provided project context was not valid:
2 validation errors for ProjectContext
metadataStore.mysql.active
Extra inputs are not permitted
For further information visit https://errors.pydantic.dev/2.12/v/extra_forbidden
sslVerify
Extra inputs are not permitted
For further information visit https://errors.pydantic.dev/2.12/v/extra_forbidden
(ado-core) alessandropomponio@MacBook-Pro-di-Alessandro ~/D/G/p/ado ((8684a72e)) [1]> ado template context --local-context
warnings.warn(
ERROR: The provided project context was not valid:
2 validation errors for ProjectContext
metadataStore.mysql.active
Extra inputs are not permitted
For further information visit https://errors.pydantic.dev/2.12/v/extra_forbidden
sslVerify
Extra inputs are not permitted
For further information visit https://errors.pydantic.dev/2.12/v/extra_forbidden
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working