Skip to content
This repository was archived by the owner on Mar 20, 2026. It is now read-only.
This repository was archived by the owner on Mar 20, 2026. It is now read-only.

Choice fields break with non-ascii choices #23

@uhenninger

Description

@uhenninger

Choice fields throw a UnicodeDecodeError if one of the choices is non-ascii.

The reason appears to be in line 49 of semanticuiforms.py

Changing the line from
self.values["field"] = str(FIELDS.get(name, FIELDS.get(None))(self.field, self.attrs))
to
self.values["field"] = FIELDS.get(name, FIELDS.get(None))(self.field, self.attrs)
fixed the problem for me (note the removed str())

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