An error has occurred: InvalidManifestError

See original GitHub issue

when i use pre-commit run --all-files i got this error

[INFO] Initializing environment for git@github.com:kobeTianSilk/py3-bundleb2b.git.
An error has occurred: InvalidManifestError: 
=====> /Users/kobetian/.cache/pre-commit/repogfm2l6s7/.pre-commit-hooks.yaml does not exist
Check the log at /Users/kobetian/.cache/pre-commit/pre-commit.log

here is my code

default_language_version:
    python: python3.7
default_stages: [commit, push]
repos:
-   repo: git@github.com:kobeTianSilk/py3-bundleb2b.git
    rev: 896b92dcdbf567c5c0197fc6575e0c8bf6d2b5b3
    hooks:
    -   id: python-pylint
    -   id: python-isort
    -   id: autopep8
    -   id: black
        language_version: python3.7

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:24 (14 by maintainers)

github_iconTop GitHub Comments

8reactions
jczaplewcommented, Apr 15, 2020

I was running into this issue, and rm -rf ~/.cache/pre-commit followed by a pre-commit install fixed it

3reactions
jgosmanncommented, Dec 26, 2020

I was running into this issue, and rm -rf ~/.cache/pre-commit followed by a pre-commit install fixed it

I had the same issue and could resolve it in the same way. I think it was caused because the path to my home directory changed and pre-commit was still referring to the old path for some reason:

An error has occurred: InvalidManifestError:
=====> /Volumes/Home/blubb/.cache/pre-commit/reportiehxn8/.pre-commit-hooks.yaml does not exist
Check the log at /Users/jgosmann/.cache/pre-commit/pre-commit.log

/Volumes/Home/blubb is the old path, /Users/jgosmann the new one.

Read more comments on GitHub >

github_iconTop Results From Across the Web

An error has occurred: InvalidManifestError - Have Fun Learning
Error running pre-commit: Type tag 'jupyter' is not recognized. Try upgrading identify and pre-commit? Fix the cache with:
Read more >
pre-commit InvalidConfigError - Stack Overflow
I missed adding "hooks" to the file, now it works: - repo: local hooks: # <- this was missing - id: pytest name:...
Read more >
No .pre-commit-hook.yaml file in any current release
pre-commit run An error has occurred: InvalidManifestError: =====> /home/{username}/.cache/pre-commit/repomp04lde_/.pre-commit-hooks.yaml ...
Read more >
pre-commit
The pre-commit config file describes what repositories and hooks are installed. .pre-commit-config.yaml - top level ¶. new in 1.0.0: The default configuration ...
Read more >
"Invalid manifest" error when uploading an update
Today I tried to upload new version with only description was changed (and ... The dashboard gives me the error: "An error occurred:...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found