Uberspace / lab

The Uberlab provides various tutorials - written by you! - on how to run software and tools on Uberspace 7.
https://lab.uberspace.de
Other
315 stars 414 forks source link

Use version 3.5.* of pre-commit to avoid InvalidManifestError #1737

Closed MetroMarv closed 5 months ago

MetroMarv commented 6 months ago

Upgrade pre-commit from version 2.13. to 3.5. to avoid the following error:

An error has occurred: InvalidManifestError: ==> File /Users//.cache/pre-commit/repoyg3plrqf/.pre-commit-hooks.yaml ==> At Hook(id='black') ==> At key: stages ==> At index 0 =====> Expected one of commit, commit-msg, manual, merge-commit, post-checkout, post-commit, post-merge, prepare-commit-msg, push but got: 'pre-commit'

Fixes #1733

MetroMarv commented 6 months ago

I also tried to use the latest version of pre-commit (which is 3.6.*) but then the initialization of the Netlify checks fails.

FriedrichFroebel commented 6 months ago

The failure is rather easy to explain. In the logs we have

7:05:49 PM: Python version set to 3.8

while https://github.com/pre-commit/pre-commit/blob/main/CHANGELOG.md#360---2023-12-09 states that 3.6.0 dropped support for Python 3.8 before the actual EOL.

MetroMarv commented 6 months ago

That makes sense. Thanks for the clarification.

nichtmax commented 5 months ago

Thank you!