StreamingResponse raise UnicodeEncodeError when filename contains special characters #2283
Answered
by
alex-oleshkevich
HueyBai
asked this question in
Potential Issue
-
|
When returning a StreamingResponse to return a file stream, if filename in the header contains special characters (tested Chinese, Korean, Japanese, Arabic and Russian), a Here is a full example to reproduce: error: Dependencies: How can I return a file stream with special characters in the filename? |
Beta Was this translation helpful? Give feedback.
Answered by
alex-oleshkevich
Sep 19, 2023
Replies: 1 comment
-
|
Quote it. See https://stackoverflow.com/questions/1361604/how-to-encode-utf8-filename-for-http-headers-python-django |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
Kludex
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Quote it. See https://stackoverflow.com/questions/1361604/how-to-encode-utf8-filename-for-http-headers-python-django