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

Bump pydantic to 2.7.4 #15

Merged
merged 1 commit into from
Oct 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[run]
omit =
tests/*
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,5 @@ share/python-wheels/
.installed.cfg
*.egg
MANIFEST
.venv
.venv
.coverage
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
pydantic>=2.0.0
pydantic>=2.7.4
jsonschema==4.17.1
setuptools~=65.5.1
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

setup(
install_requires=[
"pydantic>=2.0.0",
"pydantic>=2.7.4",
"jsonschema==4.17.1",
"setuptools~=65.5.1",
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def _get_default_model_size(cls, name) -> float:
for name, size in constants.MODEL_NAME_SIZE_MAPPING.items():
if name in name_info:
return size
return cls.__fields__["default_memory_size"].default
return cls.model_fields["default_memory_size"].default

def to_dict(self):
"""Function returns a dict of the model properties without the default values.
Expand Down
10 changes: 8 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,22 @@ envlist = py38
whitelist_externals =
python
deps =
coverage
pytest
commands =
pytest {posargs}
coverage run --source={toxinidir} -m pytest -W error {posargs}
coverage html
coverage report --fail-under=95


[testenv:gh-workflows]
basepython = {env:TOXPYTHON:python3.8}
deps =
pytest
coverage
-r{toxinidir}/requirements.txt
setenv =
PYTHONPATH={toxinidir}
commands =
pytest {posargs}
coverage run --source={toxinidir} -m pytest -W error {posargs}
coverage report --fail-under=95
Loading