[Django] #20203: Impossible to have a descriptor named `objects` on an abstract model

5 views
Skip to first unread message

Django

unread,
Apr 4, 2013, 6:33:07 PM4/4/13
to django-...@googlegroups.com
#20203: Impossible to have a descriptor named `objects` on an abstract model
-------------------------------------+-------------------------------------
Reporter: Alex | Owner: nobody
Type: Bug | Status: new
Component: Database | Version: 1.5
layer (models, ORM) | Keywords:
Severity: Normal | Has patch: 0
Triage Stage: Accepted | Needs tests: 0
Needs documentation: 0 | Easy pickings: 0
Patch needs improvement: 0 |
UI/UX: 0 |
-------------------------------------+-------------------------------------
This is because of
https://github.com/django/django/blob/master/django/db/models/manager.py#L17
, in general the ORM supports having a different name for the default
manager, but this blows up with abstract models, which is sad.

--
Ticket URL: <https://code.djangoproject.com/ticket/20203>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
May 18, 2013, 3:19:10 PM5/18/13
to django-...@googlegroups.com
#20203: Impossible to have a descriptor named `objects` on an abstract model
-------------------------------------+-------------------------------------
Reporter: Alex | Owner:
Type: Bug | elektrrrus
Component: Database layer | Status: assigned
(models, ORM) | Version: 1.5
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by elektrrrus):

* owner: nobody => elektrrrus
* status: new => assigned


--
Ticket URL: <https://code.djangoproject.com/ticket/20203#comment:1>

Django

unread,
May 19, 2013, 8:04:34 AM5/19/13
to django-...@googlegroups.com
#20203: Impossible to have a descriptor named `objects` on an abstract model
-------------------------------------+-------------------------------------
Reporter: Alex | Owner:
Type: Bug | Status: new
Component: Database layer | Version: 1.5
(models, ORM) | Resolution:
Severity: Normal | Triage Stage: Accepted
Keywords: | Needs documentation: 0
Has patch: 0 | Patch needs improvement: 0
Needs tests: 0 | UI/UX: 0
Easy pickings: 0 |
-------------------------------------+-------------------------------------
Changes (by elektrrrus):

* status: assigned => new
* owner: elektrrrus =>


--
Ticket URL: <https://code.djangoproject.com/ticket/20203#comment:2>

Django

unread,
Jun 18, 2015, 6:32:09 AM6/18/15
to django-...@googlegroups.com
#20203: Impossible to have a descriptor named `objects` on an abstract model
-------------------------------------+-------------------------------------
Reporter: Alex | Owner: coldmind
Type: Bug | Status: assigned
Component: Database layer | Version: master
(models, ORM) |

Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by coldmind):

* owner: => coldmind
* cc: me@… (added)
* version: 1.5 => master


* status: new => assigned


Comment:

I'm working on this issue

--
Ticket URL: <https://code.djangoproject.com/ticket/20203#comment:3>

Django

unread,
Jun 18, 2015, 11:18:11 AM6/18/15
to django-...@googlegroups.com
#20203: Impossible to have a descriptor named `objects` on an abstract model
-------------------------------------+-------------------------------------
Reporter: Alex | Owner: coldmind
Type: Bug | Status: assigned
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by coldmind):

* has_patch: 0 => 1


Comment:

https://github.com/django/django/pull/4882

--
Ticket URL: <https://code.djangoproject.com/ticket/20203#comment:4>

Django

unread,
Jun 23, 2015, 9:31:49 AM6/23/15
to django-...@googlegroups.com
#20203: Impossible to have a descriptor named `objects` on an abstract model
-------------------------------------+-------------------------------------
Reporter: Alex | Owner: coldmind
Type: Bug | Status: assigned
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution:
Keywords: | Triage Stage: Ready for
| checkin

Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by timgraham):

* stage: Accepted => Ready for checkin


--
Ticket URL: <https://code.djangoproject.com/ticket/20203#comment:5>

Django

unread,
Jun 29, 2015, 9:27:24 PM6/29/15
to django-...@googlegroups.com
#20203: Impossible to have a descriptor named `objects` on an abstract model
-------------------------------------+-------------------------------------
Reporter: Alex | Owner: coldmind
Type: Bug | Status: assigned
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution:
Keywords: | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Tim Graham <timograham@…>):

In [changeset:"c31bf8cb54e591e244abc951896ef5e4a089f38d" c31bf8c]:
{{{
#!CommitTicketReference repository=""
revision="c31bf8cb54e591e244abc951896ef5e4a089f38d"
Refs #20203 -- Added tests to check inherited custom default manager
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/20203#comment:7>

Django

unread,
Jun 29, 2015, 9:27:24 PM6/29/15
to django-...@googlegroups.com
#20203: Impossible to have a descriptor named `objects` on an abstract model
-------------------------------------+-------------------------------------
Reporter: Alex | Owner: coldmind
Type: Bug | Status: assigned
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution:
Keywords: | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Tim Graham <timograham@…>):

In [changeset:"c0cf73a57d7f77af348aeb854e7b4f670dc3cee7" c0cf73a]:
{{{
#!CommitTicketReference repository=""
revision="c0cf73a57d7f77af348aeb854e7b4f670dc3cee7"
Refs #20203 -- Allowed adding custom default manager to the model state

If the only manager on the model is the default manager defined
by Django (`objects = models.Manager()`), this manager will not
be added to the model state. If it is custom, it needs to be
passed to the model state.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/20203#comment:6>

Django

unread,
Jun 29, 2015, 9:28:06 PM6/29/15
to django-...@googlegroups.com
#20203: Impossible to have a descriptor named `objects` on an abstract model
-------------------------------------+-------------------------------------
Reporter: Alex | Owner: coldmind
Type: Bug | Status: closed

Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution: fixed

Keywords: | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by timgraham):

* status: assigned => closed
* resolution: => fixed


--
Ticket URL: <https://code.djangoproject.com/ticket/20203#comment:8>

Reply all
Reply to author
Forward
0 new messages