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

Silence warning during build.py #409

Conversation

hosackm
Copy link
Contributor

@hosackm hosackm commented Nov 28, 2024

When running build.py, the following warning is issued by pydantic:

$ python build.py
.venv/lib/python3.13/site-packages/pydust/config.py:94: UserWarning: A custom validator is returning a value other than `self`.
Returning anything other than `self` from a top level model validator isn't supported when validating via `__init__`.
See the `model_validator` docs (https://docs.pydantic.dev/latest/concepts/validators/#model-validators) for more details.
  return ToolPydust(**pyproject["tool"].get("pydust", {}))

This warning is issued because there is a missing return statement in pydust/config.py which is interpretted as return None by pydantic. Returning self fixes the issue.

@CLAassistant
Copy link

CLAassistant commented Nov 28, 2024

CLA assistant check
All committers have signed the CLA.

@hosackm hosackm marked this pull request as ready for review November 28, 2024 18:45
@robert3005 robert3005 merged commit bfbff15 into spiraldb:develop Nov 28, 2024
2 checks passed
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.

3 participants