django-rest-framework-proxy icon indicating copy to clipboard operation
django-rest-framework-proxy copied to clipboard

MultiPart, file, got error "TypeError: sequence item 0: expected a bytes-like object, str found"

Open VDShark opened this issue 7 years ago • 2 comments

Hi there. Are you testing file proxying?

I'm faced with this error. I'm little diving in the problem, and found this place: rest_framework_proxy/utils.py:61

return b'\r\n'.join(output)

Maybe I don't understand something, but output contains strings => we got this error.

P.S. Also, there is something strange with package releases. In pypi actual version 1.6, but in this repo I see 1.4 as latest.

VDShark avatar Apr 17 '18 16:04 VDShark

Hi, I can confirm this error happening on Python 3.7 and DRF proxy 1.6 as you are trying to join string mode list with bytes. Should be encoded like in #26.

mirekys avatar Nov 20 '18 15:11 mirekys

there's no release for that fix! please fix this it's critical issue

Shehab-Muhammad avatar Apr 16 '19 15:04 Shehab-Muhammad