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

Regenerate resources sdk 🔁 #10

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Regenerate resources sdk 🔁 #10

wants to merge 2 commits into from

Conversation

otomator
Copy link
Contributor

@otomator otomator commented Oct 25, 2024

Disabled the testing on python 3.9 because of a python reflection issue in the pydantic typeadapter, where forward compatibility of `|` union types seems to break:
```
../api/tasks_batch_operations_api_test.py:120: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
../types/batch_task_spec_stub.py:76: in create_instance
    return BatchTaskSpecAdapter.validate_python(
../../3.9-types/lib/python3.9/site-packages/pydantic/type_adapter.py:135: in wrapped
    return func(self, *args, **kwargs)
../../3.9-types/lib/python3.9/site-packages/pydantic/type_adapter.py:366: in validate_python
    return self.validator.validate_python(object, strict=strict, from_attributes=from_attributes, context=context)
../../3.9-types/lib/python3.9/site-packages/waylay/sdk/api/_models.py:81: in _model_validator
    return handler(value)
../../3.9-types/lib/python3.9/site-packages/waylay/sdk/api/_models.py:135: in _field_validator
    field_type = get_type_hints(cls).get(info.field_name, Any)
/opt/homebrew/Caskroom/miniconda/base/envs/waylay-sdk-3.9/lib/python3.9/typing.py:1459: in get_type_hints
    value = _eval_type(value, base_globals, localns)
/opt/homebrew/Caskroom/miniconda/base/envs/waylay-sdk-3.9/lib/python3.9/typing.py:292: in _eval_type
    return t._evaluate(globalns, localns, recursive_guard)
/opt/homebrew/Caskroom/miniconda/base/envs/waylay-sdk-3.9/lib/python3.9/typing.py:554: in _evaluate
    eval(self.__forward_code__, globalns, localns),
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

>   ???
E   TypeError: unsupported operand type(s) for |: 'ModelMetaclass' and 'NoneType'
```
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