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

Fixed #35407 -- Cached model's Options.swapped. #18104

Merged
merged 1 commit into from May 7, 2024

Conversation

adamchainz
Copy link
Sponsor Member

Trac ticket number

ticket-35407

Branch description

Optimization per ticket.

Checklist

  • This PR targets the main branch.
  • The commit message is written in past tense, mentions the ticket number, and ends with a period.
  • I have checked the "Has patch" ticket flag in the Trac system.
  • I have added or updated relevant tests.
  • I have added or updated relevant docs, including release notes if applicable.
  • I have attached screenshots in both light and dark modes for any UI changes.

@nessita
Copy link
Contributor

nessita commented Apr 26, 2024

Thank you @adamchainz! Could you please add a test to ensure the new approach works properly? Thank you!

django/db/models/options.py Show resolved Hide resolved
@adamchainz
Copy link
Sponsor Member Author

Thank you @adamchainz! Could you please add a test to ensure the new approach works properly? Thank you!

Done. The existing tests covered most or all cases already, implicitly, but I added explicit tests in the model_meta module.

Copy link
Contributor

@sarahboyce sarahboyce left a comment

Choose a reason for hiding this comment

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

Thank you!

@sarahboyce sarahboyce merged commit 7abe511 into django:main May 7, 2024
33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants