Skip to content

Add stub for django.db.models.expressions.Expression.identity #2685

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

Merged
merged 1 commit into from
Jun 7, 2025

Conversation

cjwatson
Copy link
Contributor

I don't think we need to be very specific about the contents of the returned tuple; it's just used for comparison and hashing methods.

Copy link
Member

@sobolevn sobolevn left a comment

Choose a reason for hiding this comment

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

Thanks!

@cjwatson cjwatson force-pushed the expression-identity branch 3 times, most recently from 32bd96a to 5f742de Compare May 23, 2025 12:21
@cjwatson
Copy link
Contributor Author

Sorry I'm taking so many tries at this - I haven't managed to get the stub tests working locally so the iteration time is kind of long! Hopefully this time should be closer.

@cjwatson cjwatson force-pushed the expression-identity branch from 5f742de to 967786c Compare June 6, 2025 12:43
@cjwatson
Copy link
Contributor Author

cjwatson commented Jun 6, 2025

I eventually found python/mypy#18959 that explains the errors I was running into. I've added allowlist.txt entries for now; I assume you'll remove those in bulk later when upgrading mypy.

@sobolevn
Copy link
Member

sobolevn commented Jun 6, 2025

We don't need this anymore, since mypy1.16 solved this problem :)

I don't think we need to be very specific about the contents of the
returned tuple; it's just used for comparison and hashing methods.
@cjwatson cjwatson force-pushed the expression-identity branch from 967786c to aef7fb9 Compare June 6, 2025 14:59
@cjwatson
Copy link
Contributor Author

cjwatson commented Jun 6, 2025

Indeed! Rebased to get rid of that.

Copy link
Member

@sobolevn sobolevn left a comment

Choose a reason for hiding this comment

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

Thanks!

@sobolevn sobolevn merged commit 7a7bc1d into typeddjango:master Jun 7, 2025
37 checks passed
jose-reveni pushed a commit to jose-reveni/django-stubs that referenced this pull request Jun 9, 2025

Verified

This commit was signed with the committer’s verified signature. The key has expired.
jose-reveni Jose Enrique Narvaez
…ddjango#2685)

I don't think we need to be very specific about the contents of the
returned tuple; it's just used for comparison and hashing methods.
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.

None yet

2 participants