[Django] #35160: m2m_changed not trigerred when ManyToManyField in autocomplete list

6 views
Skip to first unread message

Django

unread,
Jan 31, 2024, 6:12:46 AM1/31/24
to django-...@googlegroups.com
#35160: m2m_changed not trigerred when ManyToManyField in autocomplete list
-------------------------------------+-------------------------------------
Reporter: pcnmanon | Owner: nobody
Type: Bug | Status: new
Component: Database | Version: 3.2
layer (models, ORM) | Keywords: m2m_changed
Severity: Normal | ManyToManyField autocomplete_fields
Triage Stage: | DEBUG
Unreviewed | Has patch: 0
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------+-------------------------------------
When a ManyToManyField in Django Admin is set in autocomplete_fields the
signal m2m_changed is not triggered if DEBUG=false in settings but if we
switch DEBUG to true the signal m2m_changed is triggered.
This is only reproductible if the ManyToManyField is present in
autocomplete_fields if it is not, m2m_changed work correctly.
--
Ticket URL: <https://code.djangoproject.com/ticket/35160>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Jan 31, 2024, 6:56:00 AM1/31/24
to django-...@googlegroups.com
#35160: m2m_changed not trigerred when ManyToManyField in autocomplete list
-------------------------------------+-------------------------------------
Reporter: pcnmanon | Owner: nobody
Type: Bug | Status: closed
Component: contrib.admin | Version: 3.2
Severity: Normal | Resolution: needsinfo
Keywords: m2m_changed | Triage Stage:
ManyToManyField | Unreviewed
autocomplete_fields DEBUG |

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

* status: new => closed
* resolution: => needsinfo
* component: Database layer (models, ORM) => contrib.admin

Comment:

I don't see any `DEBUG`-dependent behavior in the admin. Moreover, Django
3.2 in the extended support and no longer receives bugfixes (except
security patches), Can you reproduce the issue with Django 5.0? or with
the current Django's `main` branch? Please reopen the ticket if you can
debug your issue and provide a sample project that reproduce it with
Django 5.0+.
--
Ticket URL: <https://code.djangoproject.com/ticket/35160#comment:1>

Reply all
Reply to author
Forward
0 new messages