Skip to content
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

fix issue #409 #410

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from
Open

fix issue #409 #410

wants to merge 1 commit into from

Conversation

mShan0
Copy link
Contributor

@mShan0 mShan0 commented Aug 29, 2024

Fixes a bug when using the .explain() function, see #409

Co-Authored-By: evan54 <[email protected]>
@@ -361,7 +361,7 @@ def as_sql(self, with_limits=True, with_col_aliases=False):
params.extend(h_params)

explain = self.query.explain_info if django.VERSION >= (4, 0) else self.query.explain_query
if explain:
if explain and hasattr(self.query, 'explain_format'):

Choose a reason for hiding this comment

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

Hey, so from what I understand after Django 4.0 query.explain_format and query.explain_options are replaced by query.explain_info.format and query.explain_info.options respectively.

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.

2 participants