You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The documentation about using and creating Custom Resources isn't that great. The documentation about loading Generic Resources is lacking in description and/or example of how to get from loading a generic resource from the cluster/yaml/crdspec to actually getting or creating an object of that resource. Also some of the example don't appear to work anymore, for example this is no longer valid
Plus the resources loaded from this method a lacking the type hinting for anything except the common fields like metadata and status. But often the spec field is the field you work with the most often and that lacks any hinting which is supposed to be a big part of Lightkube and throws errors in type checkers unless you use dict methods to access them. This may be ok for small things but it really sucks if you are say writing an operator.
Looking through the code and finding #54 in the issues list it is kind of possible to deduce how to create full proper models similar to the ones in the lightkube-models package but it would be nice if there were proper documentation on how to create full models
This appears to be a weakness of all the Python libraries for Kubernetes but I think Lightkube may be closest to being able to at least work with a project's models. Perhaps even document how to use your generator to generate models from an existing spec?
The text was updated successfully, but these errors were encountered:
The documentation about using and creating Custom Resources isn't that great. The documentation about loading Generic Resources is lacking in description and/or example of how to get from loading a generic resource from the cluster/yaml/crdspec to actually getting or creating an object of that resource. Also some of the example don't appear to work anymore, for example this is no longer valid
Plus the resources loaded from this method a lacking the type hinting for anything except the common fields like metadata and status. But often the spec field is the field you work with the most often and that lacks any hinting which is supposed to be a big part of Lightkube and throws errors in type checkers unless you use dict methods to access them. This may be ok for small things but it really sucks if you are say writing an operator.
Looking through the code and finding #54 in the issues list it is kind of possible to deduce how to create full proper models similar to the ones in the
lightkube-models
package but it would be nice if there were proper documentation on how to create full modelsThis appears to be a weakness of all the Python libraries for Kubernetes but I think Lightkube may be closest to being able to at least work with a project's models. Perhaps even document how to use your generator to generate models from an existing spec?
The text was updated successfully, but these errors were encountered: