[Django] #36340: TypeError on readonly fields

9 views
Skip to first unread message

Django

unread,
Apr 20, 2025, 6:53:23 AM4/20/25
to django-...@googlegroups.com
#36340: TypeError on readonly fields
-------------------------------------+-------------------------------------
Reporter: Rami | Owner: Rami Boutassghount
Boutassghount |
Type: Bug | Status: assigned
Component: | Version: 5.2
contrib.admin | Keywords: admin, contrib,
Severity: Normal | helpers
Triage Stage: | Has patch: 0
Unreviewed |
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------+-------------------------------------
There is a small bug in the method `AdminReadonlyField.contents` of the
module `django.contrib.admin.helpers`. This method raises a `TypeError`
because the calling of the `display_for_field` has not been updated. It
has a new argument: `avoid_link`.


https://github.com/django/django/blob/main/django/contrib/admin/helpers.py#L296


```python
result_repr = display_for_field(value, f, self.empty_value_display)
```
--
Ticket URL: <https://code.djangoproject.com/ticket/36340>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Apr 20, 2025, 7:11:18 AM4/20/25
to django-...@googlegroups.com
#36340: TypeError on readonly fields
-------------------------------------+-------------------------------------
Reporter: Rami Boutassghount | Owner: Rami
| Boutassghount
Type: Bug | Status: closed
Component: contrib.admin | Version: 5.2
Severity: Normal | Resolution: fixed
Keywords: admin, contrib, | Triage Stage:
helpers | Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Rami Boutassghount):

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

Comment:

I just find out that it fixed
--
Ticket URL: <https://code.djangoproject.com/ticket/36340#comment:1>

Django

unread,
Apr 20, 2025, 7:30:42 AM4/20/25
to django-...@googlegroups.com
#36340: TypeError on readonly fields
-------------------------------------+-------------------------------------
Reporter: Rami Boutassghount | Owner: Rami
| Boutassghount
Type: Bug | Status: closed
Component: contrib.admin | Version: 5.2
Severity: Normal | Resolution: invalid
Keywords: admin, contrib, | Triage Stage:
helpers | Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Simon Charette):

* resolution: fixed => invalid

--
Ticket URL: <https://code.djangoproject.com/ticket/36340#comment:2>
Reply all
Reply to author
Forward
0 new messages