I am using ubuntu 22.04 and the python version is 3.10.4. I have installed a Django project with the cookie-cutter. and now I have got an error when I want to commit my changes.
here is the error:
(blog) ➜ blog git:(main) ✗ pre-commit run
[INFO] Installing environment for https://github.com/pre-commit/pre-commit-hooks.
[INFO] Once installed this environment will be reused.
[INFO] This may take a few minutes...
An unexpected error has occurred: AssertionError: BUG: expected environment for python to be healthy() immediately after install, please open an issue describing your environment
Check the log at /home/mahdi/.cache/pre-commit/pre-commit.log
Content of pre-commit.log:
### version information
```
pre-commit version: 2.18.1
git --version: git version 2.34.1
sys.version:
3.10.4 (main, Apr 2 2022, 09:04:19) [GCC 11.2.0]
sys.executable: /home/mahdi/.local/share/virtualenvs/blog-qatotdDy/bin/python
os.name: posix
sys.platform: linux
```
### error information
```
An unexpected error has occurred: AssertionError: BUG: expected environment for python to be healthy() immediately after install, please open an issue describing your environment
```
```
Traceback (most recent call last):
File "/home/mahdi/.local/share/virtualenvs/blog-qatotdDy/lib/python3.10/site-packages/pre_commit/error_handler.py", line 73, in error_handler
yield
File "/home/mahdi/.local/share/virtualenvs/blog-qatotdDy/lib/python3.10/site-packages/pre_commit/main.py", line 371, in main
return run(args.config, store, args)
File "/home/mahdi/.local/share/virtualenvs/blog-qatotdDy/lib/python3.10/site-packages/pre_commit/commands/run.py", line 414, in run
install_hook_envs(to_install, store)
File "/home/mahdi/.local/share/virtualenvs/blog-qatotdDy/lib/python3.10/site-packages/pre_commit/repository.py", line 221, in install_hook_envs
_hook_install(hook)
File "/home/mahdi/.local/share/virtualenvs/blog-qatotdDy/lib/python3.10/site-packages/pre_commit/repository.py", line 83, in _hook_install
raise AssertionError(
AssertionError: BUG: expected environment for python to be healthy() immediately after install, please open an issue describing your environment
```
I have search on google, but couldn't find any solution.