Opened 9 years ago

Closed 8 years ago

#2885 closed defect (duplicate)

get_cached_row and hence select_related dead loop on circular ForeignKeys

Reported by: bangcok_dangerus ( at ] hotmail.com Owned by: adrian
Component: Database layer (models, ORM) Version: master
Severity: normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

select_related fails if there's a loop in ForeignKey relationships. fill_table_cache, which recursively follows ForeignKeys to generate the SQL query, was mentioned as a candidate for this in #2549 . This should now be fixed by the patch in #2874. get_cached_row, which recursively populates objects from the result of the query, suffers from the same problem.

I'll try get a patch up for this at some point.

-Basil

Change History (1)

comment:1 Changed 8 years ago by mir@…

  • Resolution set to duplicate
  • Status changed from new to closed

duplicate of #3288

Note: See TracTickets for help on using tickets.
Back to Top