sphobjinv
sphobjinv copied to clipboard
Revise anything with a text file interaction to accept an encoding, with default to locale-default
trafficstars
Otherwise there could be users who have to jump through hoops to make things work.
Ideally, the default would be UTF-8; but, in order to retain backward compatibility, the default for a v2 will need to match the encoding=None, which is locale.getpreferredencoding().
A switch to UTF-8 as default, while likely breaking very little code, would be a breaking change and need a major version bump.
Per comment(s) #103, this may only actually be needed for interactions with decompressed inventories, and with JSON-formatted content, as compressed inventories always use the Python UTF-8 default encoding.