You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This doesn't remove support for toml, it adds support for tomli. It's not forced, it is imported in the same "optional" way as toml:
try:
importtomliexceptImportError:
tomli=None
Currently the toml lib is the only way elpy can parse pyproject.toml files, which makes it required, but toml isn't always in the environment. I think it would make sense to provide other options. Pip itself uses tomli to parse pyproject.toml files, and tomllib (a derivative of tomli) was recently added to the python standard library in 3.11 (so ultimately it will be best to just use that).
This PR isn't ready (yet). I didn't have toml in one of my venvs so I ran into this issue, still figuring out the best way to resolve it generally.
Is anything blocking this? Would love to have this as I currently have to patch my blackutil manually any time I update elpy.
Btw tomli is a dependency of black so imo fine to make it the only option. If you're using black, you have it installed.
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
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.
PR Summary
PR checklist
Please make sure that the following things have been addressed (and check the relevant checkboxes):
For new features only: