Skip to content

Specify UTF-8 as encoding for open-related methods #744

@m09

Description

@m09

ATM we often don't specify the encoding in open calls. We should instead specify utf-8 everywhere because the default is platform dependent:

encoding is the name of the encoding used to decode or encode the file. This should only be used in text mode. The default encoding is platform dependent (whatever locale.getpreferredencoding() returns), but any text encoding supported by Python can be used. See the codecs module for the list of supported encodings.

That means all our open, pathlib.Path.read_text and related calls should specify encoding="utf-8".

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingformatIssues related to format analyzermediumMedium sizetypos

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions