I guess this started happening on Python 2.7 after #24727 was fixed
(5c412dd).
Related ticket: #13327
--
Ticket URL: <https://code.djangoproject.com/ticket/25410>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* Attachment "traceback.txt" added.
* status: new => assigned
* severity: Normal => Release blocker
* needs_better_patch: => 0
* component: Uncategorized => Forms
* needs_tests: => 0
* owner: nobody => timgraham
* needs_docs: => 0
* stage: Unreviewed => Accepted
Old description:
> Having an empty file field raises ValueError whenever the
> ClearableFileInput widget is rendered in the admin or in a custom form.
> It prevents the rendering of the form in change mode (works in creation
> mode).
>
> I guess this started happening on Python 2.7 after #24727 was fixed
> (5c412dd).
>
> Related ticket: #13327
New description:
Having an empty file field raises ValueError whenever the
ClearableFileInput widget is rendered in the admin or in a custom form. It
prevents the rendering of the form in change mode (works in creation
mode).
I guess this started happening on Python 2.7 after #24727 was fixed
[5c412dd].
Related ticket: #13327
--
Comment:
Confirmed as a regression in 1.9. I'll revert the patch that caused the
regression, reopen that ticket for more investigation, and add a test for
this issue.
--
Ticket URL: <https://code.djangoproject.com/ticket/25410#comment:1>
* has_patch: 0 => 1
Comment:
[https://github.com/django/django/pull/5344 PR]
--
Ticket URL: <https://code.djangoproject.com/ticket/25410#comment:2>
Old description:
> Having an empty file field raises ValueError whenever the
> ClearableFileInput widget is rendered in the admin or in a custom form.
> It prevents the rendering of the form in change mode (works in creation
> mode).
>
> I guess this started happening on Python 2.7 after #24727 was fixed
> [5c412dd].
>
> Related ticket: #13327
New description:
Having an empty file field raises ValueError whenever the
ClearableFileInput widget is rendered in the admin or in a custom form. It
prevents the rendering of the form in change mode (works in creation
mode).
I guess this started happening on Python 2.7 after #24727 was fixed in
5c412dd8a724b263489c1bd7a2fea381460665d7.
Related ticket: #13327
--
--
Ticket URL: <https://code.djangoproject.com/ticket/25410#comment:3>
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"7cb3a488436e8e7d0249280e95ba2ee945c96c87" 7cb3a488]:
{{{
#!CommitTicketReference repository=""
revision="7cb3a488436e8e7d0249280e95ba2ee945c96c87"
Fixed #25410 -- Fixed empty ClearableFileInput crash on Python 2.
Reverted "Fixes #24727 -- Prevented ClearableFileInput from masking
exceptions on Python 2" and added a regression test.
This reverts commit 5c412dd8a724b263489c1bd7a2fea381460665d7.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/25410#comment:4>