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

DjangoOptimizerExtension can't hand order_with_respect_to tuples with using OrderedModel #536

Open
Eraldo opened this issue May 30, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@Eraldo
Copy link
Contributor

Eraldo commented May 30, 2024

Describe the Bug

When a Django model has the order_with_respect_to property set to a tuple of fields, the DjangoOptimizerExtension throws the following error:

"message": "maximum recursion depth exceeded in comparison",

Update:
Only happens if the model inherits from: OrderedModel: https://github.com/django-ordered-model/django-ordered-model

Reproduction: https://github.com/Eraldo/strawberry-django-optimizer-infinite-recursion-mre

System Information

  • Operating system: OSX 14.5 (23F79)
  • Strawberry version (if applicable):
strawberry-graphql-django = "^0.41.1"
strawberry-graphql = "^0.232.2"

Upvote & Fund

  • We're using Polar.sh so you can upvote and help fund this issue.
  • We receive the funding once the issue is completed & confirmed by you.
  • Thank you in advance for helping prioritize & fund our backlog.
Fund with Polar
@Eraldo Eraldo added the bug Something isn't working label May 30, 2024
@Eraldo Eraldo changed the title DjangoOptimizerExtension can't hand order_with_respect_to tuples DjangoOptimizerExtension can't hand order_with_respect_to tuples with using OrderedModel May 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant