black icon indicating copy to clipboard operation
black copied to clipboard

fix(pre-commit): raise minimum_pre_commit_version (#4065)

Open davidculley opened this issue 2 years ago • 3 comments

Description

The changes made in Pull Request #3940 require version 3.2.0 of pre-commit (or newer). See https://github.com/psf/black/pull/3940#issuecomment-1820908057

We should also raise minimum_pre_commit_version if we want to go from the proposal made in #4041

stages: [commit, merge-commit, push, manual]

to

stages: [pre-commit, pre-merge-commit, pre-push, manual]

Checklist - did you ...

  • [x] Add an entry in CHANGES.md if necessary?
  • [ ] Add / update tests if necessary?
  • [ ] Add new / update outdated documentation?

davidculley avatar Nov 21 '23 15:11 davidculley

This would fix https://github.com/psf/black/issues/4065

martin-thoma avatar Nov 21 '23 16:11 martin-thoma

#4041 is the better solution, no?

AlexWaygood avatar Nov 21 '23 19:11 AlexWaygood

#4041 is the better solution, no?

It's definitely a solution that requires no work on the side of the user (except for updating black, of course), whereas the more future-proof solution proposed in this very PR (#4067) might force some users to update their installation of pre-commit.

However, probably sometime around mid-to-late 2024, with the release of pre-commit version 4.x.x, the solution proposed in #4041 will stop working and there will be no way around #4067 anymore if one wants to use version 4.x.x of pre-commit (see here).

davidculley avatar Nov 22 '23 12:11 davidculley