Opened 4 years ago

Closed 11 months ago

#18207 closed Bug (duplicate)

concrete inheritence, mysql defer bug

Reported by: leftmoose Owned by: nobody
Component: Database layer (models, ORM) Version: 1.3
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


Using concrete inheritence, mysql and defer, values returned aren't properly converted to objects


    def test_concrete_ineritance_defer(self):
            name="Guido's House of Pasta",
            address='944 W. Fullerton',
        value_with_defer = Restaurant.objects.defer('name').get().serves_pizza
        self.assertIs(value_with_defer, False)

fails when using a mysql database

value_with_defer comes back as 0, not False

Change History (3)

comment:1 Changed 4 years ago by akaariai

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Accepted

Confirmed for Oracle, too.

comment:2 Changed 3 years ago by akaariai

  • Type changed from Uncategorized to Bug

comment:3 Changed 11 months ago by timgraham

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

Fixed by #21203

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