macisamuele / language-formatters-pre-commit-hooks

Collection of custom pre-commit hooks.
Apache License 2.0
116 stars 58 forks source link

Ensure toml-sort to version 0.22+ and have explicit sort configuration #137

Closed stewartHutchins closed 1 year ago

stewartHutchins commented 1 year ago

See, PR #136 for context first.

This PR builds on the PR #136, by updating to the latest toml-sort version (0.22.1), however the previous PR should be sufficient to prevent get the pre-commit hook working.

macisamuele commented 1 year ago

@stewartHutchins thanks for your contributions. I've leveraged your changes to:

codecov[bot] commented 1 year ago

Codecov Report

Merging #137 (f8ca75c) into master (69e3714) will not change coverage. The diff coverage is 100.00%.

@@            Coverage Diff            @@
##            master      #137   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            9        10    +1     
  Lines          304       309    +5     
=========================================
+ Hits           304       309    +5     
Impacted Files Coverage Δ
..._formatters_pre_commit_hooks/pretty_format_toml.py 100.00% <100.00%> (ø)
language_formatters_pre_commit_hooks/__init__.py 100.00% <0.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

stewartHutchins commented 1 year ago

Super, glad I could help. :smile:

Unless the work is already underway, might I suggest more restrictive versioning for all dependencies in setup.cfg? This may prevent a similar breaks in the future (where a 3rd party library's API changes).

For example, I'd like to emphasise that this project now has the dependency toml-sort>=0.22.0 and also relies on the imports: