Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Re-evaluate usage of encoding throughout the package #103

Open
bskinn opened this issue Oct 15, 2019 · 1 comment
Open

Re-evaluate usage of encoding throughout the package #103

bskinn opened this issue Oct 15, 2019 · 1 comment
Labels
area: api 🤖 issue: planned ⌚ Assigned to a specific version's milestone topic: encodings ↔️ type: question ❔ Something to investigate
Milestone

Comments

@bskinn
Copy link
Owner

bskinn commented Oct 15, 2019

Right now many things internally are coerced to using UTF-8. This may be fine! Occurrences of encoding collisions may be infrequent enough that it might as well be a YAGNI to do this.

But, it would be a good opportunity to strengthen understanding of when to handle encodings in which way(s).

@bskinn
Copy link
Owner Author

bskinn commented May 14, 2020

Sphinx specifically encodes the compressed objects.invs using Python's default encoding of UTF-8. Thus, import of compressed inventories should always work with UTF-8, and the code does not need to be changed on the compressed inventory side.


The big question is then the encoding used for read/write of decompressed inventories.

Currently, looks like the code is based around read/write of UTF-8 encoded plaintext (see here and here). The big change would be to add arguments allowing the user to specify whatever desired encoding for read/write, including adding an option to the CLI.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: api 🤖 issue: planned ⌚ Assigned to a specific version's milestone topic: encodings ↔️ type: question ❔ Something to investigate
Projects
None yet
Development

No branches or pull requests

1 participant