Django image upload failed when not enough disk space with unrelated exception

Bug #1854262 reported by Yang Youseok
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Dashboard (Horizon)
New
Undecided
Unassigned

Bug Description

Currently, when horizon use direct file upload for glance image upload and horizon server does not enough disk space for temporary file, horizon meets 'KeyError' for 'visibility'.

I think root cause of comment 31 in https://bugzilla.redhat.com/show_bug.cgi?id=1508725 is same as what I saw.

Master version of horizon allow empty params of 'visibility' so I guess master will have something different exception though, I think root problem is still valid in master too.

Root cause I assume is that

- When request.POST is accessed (openstack_dashboard/api/rest/utils.py post2data())
- Django multipartpaser start to parse
- It does not emit any exception when IOError(No disk space) occurred only with error hint which is emtpy POST dict.
- request.DATA is empty dict {} since request.POST is emtpy.
- [Bug here] Logic access request.DATA is all invalid since this dict is empty. (Actually from my environment, Ocata, 'visibility' key is first location that I find KeyError.)

Sugguestion

- Raise some exception when Django request.POST is empty when we assume it's filled with multipart data.

I'm not 100% sure since it's just result of only the phenomenon, so please correct me what i'm missing if there.

Thanks

Yang Youseok (ileixe)
description: updated
Yang Youseok (ileixe)
description: updated
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.