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

pydantic error on getting started example #5

Open
chris-aeviator opened this issue Mar 27, 2024 · 0 comments
Open

pydantic error on getting started example #5

chris-aeviator opened this issue Mar 27, 2024 · 0 comments

Comments

@chris-aeviator
Copy link

chris-aeviator commented Mar 27, 2024

p311

EDIT:

concerns the example at https://factryflow.github.io/factryengine/#documentation

    task1 = Task(id=1, duration=3, priority=2, resources=[[resource]])
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/korny/micromamba/envs/tofutime/lib/python3.11/site-packages/pydantic/main.py", line 171, in __init__
    self.__pydantic_validator__.validate_python(data, self_instance=self)
pydantic_core._pydantic_core.ValidationError: 1 validation error for Task
  Value error, Either assignments or constraints must be set [type=value_error, input_value={'id': 1, 'duration': 3, ...iciency_multiplier=1)]]}, input_type=dict]
    For further information visit https://errors.pydantic.dev/2.6/v/value_error
``
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

No branches or pull requests

1 participant