Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
gitpython-3.1.20 (imported via Kapitan 0.30.0rc0) triggers a regression in Python 3.9.7, with errors like ``` simon@wyvern:~/work/syn/commodore $ poetry run commodore component new test Adding component test... Traceback (most recent call last): File "<string>", line 1, in <module> File "/home/simon/work/syn/commodore/commodore/cli.py", line 327, in main commodore.main(prog_name="commodore", auto_envvar_prefix="COMMODORE") File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/click/core.py", line 1053, in main rv = self.invoke(ctx) File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/click/core.py", line 1659, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/click/core.py", line 1659, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/click/core.py", line 1395, in invoke return ctx.invoke(self.callback, **ctx.params) File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/click/core.py", line 754, in invoke return __callback(*args, **kwargs) File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/click/decorators.py", line 84, in new_func return ctx.invoke(f, obj, *args, **kwargs) File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/click/core.py", line 754, in invoke return __callback(*args, **kwargs) File "/home/simon/work/syn/commodore/commodore/cli.py", line 264, in component_new f.create() File "/home/simon/work/syn/commodore/commodore/component/template.py", line 100, in create git.commit(repo, "Initial commit", self.config) File "/home/simon/work/syn/commodore/commodore/git.py", line 230, in commit repo.index.commit(commit_message, author=author, committer=author) File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/git/index/base.py", line 1000, in commit tree = self.write_tree() File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/git/index/base.py", line 574, in write_tree root_tree = Tree(self.repo, binsha, path='') File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/git/objects/tree.py", line 215, in __init__ super(Tree, self).__init__(repo, binsha, mode, path) File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/git/objects/base.py", line 168, in __init__ super(IndexObject, self).__init__(repo, binsha) File "/home/simon/.cache/pypoetry/virtualenvs/syn-commodore-mfZDsTMQ-py3.9/lib/python3.9/site-packages/git/objects/base.py", line 56, in __init__ super(Object, self).__init__() File "/usr/lib/python3.9/typing.py", line 1083, in _no_init raise TypeError('Protocols cannot be instantiated') TypeError: Protocols cannot be instantiated ``` This issue has been reported in gitpython-developers/GitPython#1332 and should be fixed with a workaround in the next release of gitpython. Additionally, the regression should be fixed in the next Python 3.9 patch release, cf. https://bugs.python.org/issue45121
- Loading branch information