Skip to content

UnicodeDecodeError with non-ASCII filenames for field type 'FILE' on Python 2 #188

Open
@petrikoz

Description

@petrikoz

Hello

I use your module of version 0.12.3 on Python 2 and MySQL as database.
And I have problem with fields with type 'FILE'.

When I upload files with non-ASCII characters in them names I have UnicodeDecodeError in MySQL save method.
This method try use value of field as bytes string.

It happen because your code convert value of field with type FILE is instance to future.types.newstr.newstr. And it doesn't convert to Python 2 unicode type as other values from form.

Can you help me solve this problem? Or maybe you show me where I must dig in my search?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions