Skip to content

fix select_related and prefetch_related set in resolver getting lost #166

New issue

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

Closed

Conversation

jsurloppe
Copy link

Despite prefetching relation in resolve_ method, the relations are lost and filter redo n+1 queries.

This patch may introduce a reverse bug where relations prefetched in the default_queryset are lost, i haven't tested but i think this is way less problematic.

@coveralls
Copy link

coveralls commented May 2, 2017

Coverage Status

Coverage remained the same at 93.801% when pulling ebc872c on jsurloppe:fix-related-filter into 1e34dfb on graphql-python:master.

5 similar comments
@coveralls
Copy link

Coverage Status

Coverage remained the same at 93.801% when pulling ebc872c on jsurloppe:fix-related-filter into 1e34dfb on graphql-python:master.

@coveralls
Copy link

Coverage Status

Coverage remained the same at 93.801% when pulling ebc872c on jsurloppe:fix-related-filter into 1e34dfb on graphql-python:master.

@coveralls
Copy link

Coverage Status

Coverage remained the same at 93.801% when pulling ebc872c on jsurloppe:fix-related-filter into 1e34dfb on graphql-python:master.

@coveralls
Copy link

Coverage Status

Coverage remained the same at 93.801% when pulling ebc872c on jsurloppe:fix-related-filter into 1e34dfb on graphql-python:master.

@coveralls
Copy link

Coverage Status

Coverage remained the same at 93.801% when pulling ebc872c on jsurloppe:fix-related-filter into 1e34dfb on graphql-python:master.

@jsurloppe jsurloppe force-pushed the fix-related-filter branch from ebc872c to 0cabdb3 Compare May 2, 2017 16:02
@coveralls
Copy link

Coverage Status

Coverage remained the same at 93.801% when pulling 0cabdb3 on jsurloppe:fix-related-filter into 1e34dfb on graphql-python:master.

1 similar comment
@coveralls
Copy link

coveralls commented May 2, 2017

Coverage Status

Coverage remained the same at 93.801% when pulling 0cabdb3 on jsurloppe:fix-related-filter into 1e34dfb on graphql-python:master.

@jsurloppe jsurloppe force-pushed the fix-related-filter branch from 0cabdb3 to 5536fc9 Compare May 2, 2017 16:08
@coveralls
Copy link

coveralls commented May 2, 2017

Coverage Status

Coverage remained the same at 93.801% when pulling 5536fc9 on jsurloppe:fix-related-filter into 1e34dfb on graphql-python:master.

@jsurloppe jsurloppe closed this May 2, 2017
@jsurloppe jsurloppe reopened this May 2, 2017
@coveralls
Copy link

coveralls commented May 2, 2017

Coverage Status

Coverage remained the same at 93.801% when pulling 5536fc9 on jsurloppe:fix-related-filter into 1e34dfb on graphql-python:master.

@syrusakbary
Copy link
Member

Hey @jsurloppe, could you add some tests that showcases the issue so we assure that there is no regression in the future?

@BossGrand
Copy link
Member

I think this might be causing the bug in #173

@syrusakbary
Copy link
Member

Closing this PR in favor of #315

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants