-
Notifications
You must be signed in to change notification settings - Fork 17
Closed
Description
This is because pydantic v1 API is not supported on Python 3.14 and is not going to be supported as per the maintainer. See pydantic/pydantic#11613 (comment).
Traceback
./dvc/tests/func/artifacts/test_artifacts.py:246: in make_artifact
tmp_dir.dvc.artifacts.add(name, artifact, dvcfile=os.fspath(dvcfile))
./dvc/repo/artifacts.py:115: in add
check_name_format(name)
./dvc/repo/artifacts.py:30: in check_name_format
from gto.constants import assert_name_is_valid
.venv/lib/python3.14/site-packages/gto/__init__.py:1: in <module>
import gto.log # noqa
^^^^^^^^^^^^^^
.venv/lib/python3.14/site-packages/gto/log.py:7: in <module>
from gto.config import CONFIG
.venv/lib/python3.14/site-packages/gto/config.py:8: in <module>
from gto.constants import assert_name_is_valid
.venv/lib/python3.14/site-packages/gto/constants.py:88: in <module>
class Shortcut(BaseModel):
.venv/lib/python3.14/site-packages/pydantic/v1/main.py:221: in __new__
inferred = ModelField.infer(
.venv/lib/python3.14/site-packages/pydantic/v1/fields.py:504: in infer
return cls(
.venv/lib/python3.14/site-packages/pydantic/v1/fields.py:434: in __init__
self.prepare()
.venv/lib/python3.14/site-packages/pydantic/v1/fields.py:544: in prepare
self._set_default_and_type()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = ModelField(name='stage', type=UndefinedType, required=False, default=None)
def _set_default_and_type(self) -> None:
"""
Set the default value, infer the type if needed and check if `None` value is valid.
"""
if self.default_factory is not None:
if self.type_ is Undefined:
raise errors_.ConfigError(
f'you need to set the type of field {self.name!r} when using `default_factory`'
)
return
default_value = self.get_default()
if default_value is not None and self.type_ is Undefined:
self.type_ = default_value.__class__
self.outer_type_ = self.type_
self.annotation = self.type_
if self.type_ is Undefined:
> raise errors_.ConfigError(f'unable to infer type for attribute "{self.name}"')
E pydantic.v1.errors.ConfigError: unable to infer type for attribute "stage"Metadata
Metadata
Assignees
Labels
No labels