Skip to content

Conversation

@K0Te
Copy link
Contributor

@K0Te K0Te commented Jan 26, 2019

No description provided.


from .query import QuerySet as QuerySet, RawQuerySet as RawQuerySet
from .query import (
Prefetch as Prefetch,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Both Prefetch and prefetch_related_objects are not yet defined in query.py. Please either add them there, or remove them from here, so that test suite would pass.

@mkurnikov
Copy link
Member

There is a related django tests folder prefetch_related, please uncomment
https://github.com/mkurnikov/django-stubs/blob/master/scripts/typecheck_tests.py#L220
and fix errors.

@K0Te
Copy link
Contributor Author

K0Te commented Jan 31, 2019

I've updated PR, 2 ignored test errors are caused by the fact that Prefetch can add new attributes to model, not sure if there is more clean solution for this.

@mkurnikov mkurnikov merged commit e409dbd into typeddjango:master Feb 3, 2019
@TonyRippy TonyRippy mentioned this pull request Dec 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants