Deprecate encodings other than UTF-8 when serializing#566
Merged
Conversation
Wuestengecko
force-pushed
the
exs-encoding
branch
from
July 21, 2025 16:59
2640010 to
d91e27b
Compare
So far, there has been a slight difference in features between the pure-Python and the Rust version of the XML serializer, in that the pure-Python one accepted arbitrary encodings. However, this feature is not exposed through the `save()` methods on MelodyLoader and MelodyModel. Capella also uses UTF-8 for all its file read/write operations, which makes supporting different encodings unnecessary. Therefore this commit deprecates passing encodings into `exs` altogether. Note that explicitly passing in "utf-8" is also included in this deprecation, meaning that the `encoding` and `errors` arguments will eventually be dropped completely.
Wuestengecko
force-pushed
the
exs-encoding
branch
from
July 21, 2025 17:22
d91e27b to
5e1ae7d
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
So far, there has been a slight difference in features between the pure-Python and the Rust version of the XML serializer, in that the pure-Python one accepted arbitrary encodings. However, this feature is not exposed through the
save()methods on MelodyLoader and MelodyModel. Capella also uses UTF-8 for all its file read/write operations, which makes supporting different encodings unnecessary. Therefore this commit deprecates passing encodings intoexsaltogether. Note that explicitly passing in "utf-8" is also included in this deprecation, meaning that theencodinganderrorsarguments will eventually be dropped completely.