We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Models using DictNestedField fields are wrongly inited and can't be used for writing:
DictNestedField
Example (from XXX):
class Score(pykorm.models.Nested): exterior: int = pykorm.fields.DataField('exterior') delicious: int = pykorm.fields.DataField('delicious', 10) @pykorm.k8s_custom_object('pykorm.infomaniak.com', 'v1', 'peaches') class Peach(pykorm.NamespacedModel): variety: str = pykorm.fields.Spec('variety', default='default-variety') price: str = pykorm.fields.Spec('price', default=1) colours: list = pykorm.fields.Spec('colours', default=[]) score: Score = pykorm.fields.DictNestedField(Score, path=['spec', 'score'])
Results in the following error when writing to p.score.delicious:
p.score.delicious
> p.score.exterior = 42 E AttributeError: 'NoneType' object has no attribute 'exterior'
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Models using
DictNestedField
fields are wrongly inited and can't be used for writing:Example (from XXX):
Results in the following error when writing to
p.score.delicious
:The text was updated successfully, but these errors were encountered: