chibisafe/chibisafe

[BUG] Unicode Support

SleepingPanda opened this issue · 9 comments

Is your feature request related to a problem? Please describe.
Original Name with different encoding appear garbled

Describe the solution you'd like
I would like the addition of unicode support for use in Original Name

Additional context
firefox_SbmnHq9Y79

Pitu commented

@SleepingPanda thank you for your report. Could you by any chance share the original filename here?

@Pitu sure, the original file name is 本好きの下剋上.jpg

I have found the problem. It is caused by character set problem. Chibisafe use https://github.com/chibisafe/uploader as its multipart form uploader, which replies on busboy. The default character set for multipart forms is latin1 in Busboy
I have sent the pr chibisafe/uploader#11 for repo uploader to manually set charset to utf8 for multipart form.
After fixing it locally, I get the correct utf8 filename presentation.

Snipaste_2024-02-08_21-09-36

Wow! Thank you for both finding a solution and fixing the problem.

Pitu commented

After fixing it locally, I get the correct utf8 filename presentation.

You legend, I'll take a look today and make a new release after testing it

Pitu commented

Released 🎉

7zx commented

Just want to inform that this issue has come back after the recent updates to Chibisafe.

I can confirm the issue has returned. I'm running chibisafe v5.6.10 . Thanks for bringing this back to light @7zx . @Pitu can you confirm?

Pitu commented

Fixed in latest deployment d4aff91