-
-
Notifications
You must be signed in to change notification settings - Fork 16
Open
Description
The cent.dto.Publication model is currently defined as:
class Publication(CentResult):
data: Any
offset: int = 0
tags: Optional[Dict[str, str]] = None
However, when I call client.history methiod, the response also includes an info field, like:
info = {'user': '123', 'client': '57e86faf-565d-48fc-8a82-58bf54deb2b6'}
As a result, accessing publication.info in my code causes linters to raise an error, since the field is not part of the model definition.
One simple fix would be to add the field to the model:
The solution can be just to add this field to model definition:
info: Optional[Dict[str, Any]] = None
I could subclass Publication and add the field myself, but that feels a bit awkward given that info is consistently returned by the API
Metadata
Metadata
Assignees
Labels
No labels