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

fix docs build and redo api-ref #670

Merged
merged 6 commits into from
Dec 12, 2023
Merged

fix docs build and redo api-ref #670

merged 6 commits into from
Dec 12, 2023

Conversation

zzstoatzz
Copy link
Collaborator

@zzstoatzz zzstoatzz commented Dec 6, 2023

the mkdocs.yml was referencing old doc files and was the build was generally broken, this PR:

  • removes old doc files breaking the build
  • restructures the API Reference section of the docs
  • starts adding docstrings to utils and settings
  • refactors temporary_settings to handle nested setting objects
  • adds setting tests
  • adds tests for parse_as

from types import FunctionType, GenericAlias
from typing import Annotated, Any, Callable, Optional, Union, cast, get_origin

from pydantic import BaseModel, TypeAdapter, create_model
from pydantic.v1 import validate_arguments
from pydantic.deprecated.decorator import validate_arguments
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

because we were using v1's validate_arguments, we were getting v1 BaseModel instances here as well.

probably not ideal to use this (being deprecated) and should switch to validate_call (although I couldn't figure out how to get the model back from that right away, may need TypeAdapter for this?)

@zzstoatzz zzstoatzz self-assigned this Dec 6, 2023
@zzstoatzz zzstoatzz merged commit d34ddc5 into main Dec 12, 2023
13 checks passed
@zzstoatzz zzstoatzz deleted the redo-api-ref branch December 12, 2023 02:18
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.

2 participants