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
T=TypeVar('T')
classPaginated(GenericModel, Generic[T]):
current_page: int=1"""The currently viewed page."""total_pages: int=1"""The total number of pages."""results_count: int=0"""The total number of entries across all pages."""entries: List[T] = []
"""The entries in this page."""classCMPostArchive(Paginated[CMPost]):
"""Represents the CM Post Archive. The CM Post Archive is a collection of posts made in the forum by community managers. """start_date: datetime.date"""The start date of the displayed posts."""end_date: datetime.date"""The end date of the displayed posts."""
As we can see, in the Fields list, T is replaced by the actual type the class is defining, but when looking at the members list, it still shows T, unless I explicitly override the field in CMPostArchive and set the type there.
The text was updated successfully, but these errors were encountered:
thanks for reporting this bug. This is not intended, indeed.
At moment, I'm short on time and won't be able to provide a quick fix. However, I'm more than happy to help with code review and guidance if you want to provide a PR.
Given the following classes:
And in rst:
The following is rendered:
As we can see, in the Fields list,
T
is replaced by the actual type the class is defining, but when looking at the members list, it still showsT
, unless I explicitly override the field inCMPostArchive
and set the type there.The text was updated successfully, but these errors were encountered: