rupert / pyls-black

Black plugin for the Python Language Server
MIT License
72 stars 8 forks source link

Remove configuration parsing #9

Open rupert opened 5 years ago

rupert commented 5 years ago

At the moment we use the find_project_root, FileMode.from_configuration, and format_file_contents functions from the black package.

At the moment if a new configuration option is added to black, our call to FileMode.from_configuration will break as it will be missing an argument. It would be nice if black exposed a function to create a FileMode object from a pyproject.toml configuration file. Then we could pass the FileMode object to the format_file_contents function without worrying about the exact configuration options.

See --skip-numeric-underscore-normalization in #6