Open stefangweichinger opened 1 year ago
Have you tried with the latest versions?
I'm having the same issue (kind of intermittent depending on the commit). I am using commitizen image 3.21.3. Any news on that? Tks!
What were you running?
Not sure I got your question, but will try to give more details. I am running it inside a bamboo agent using the docker image 3.21.3
docker run --rm --volume "$(pwd):/app" --user "$(id -u):$(id -g)" commitizen/commitizen:3.21.3 bump --dry-run
I got the error twice (in different moments). It seems intermitent because If I rerun the pipeline over the same commit it works.
I'm getting this same error with v3.25.0. I have the commit hooks installed as directed here, and when running git commit
I get the following error trace:
Traceback (most recent call last):
File "/Users/btsomogyi/.asdf/installs/python/3.11.5/lib/python3.11/asyncio/selector_events.py", line 265, in _add_reader
key = self._selector.get_key(fd)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/btsomogyi/.asdf/installs/python/3.11.5/lib/python3.11/selectors.py", line 192, in get_key
raise KeyError("{!r} is not registered".format(fileobj)) from None
KeyError: '0 is not registered'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/btsomogyi/Library/Caches/pypoetry/virtualenvs/commitizen-demo--3a4COU6-py3.11/bin/cz", line 8, in <module>
sys.exit(main())
^^^^^^
File "/Users/btsomogyi/Library/Caches/pypoetry/virtualenvs/commitizen-demo--3a4COU6-py3.11/lib/python3.11/site-packages/commitizen/cli.py", line 607, in main
args.func(conf, arguments)()
File "/Users/btsomogyi/Library/Caches/pypoetry/virtualenvs/commitizen-demo--3a4COU6-py3.11/lib/python3.11/site-packages/commitizen/commands/commit.py", line 103, in __call__
m = self.prompt_commit_questions()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/btsomogyi/Library/Caches/pypoetry/virtualenvs/commitizen-demo--3a4COU6-py3.11/lib/python3.11/site-packages/commitizen/commands/commit.py", line 56, in prompt_commit_questions
answers = questionary.prompt(questions, style=cz.style)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/btsomogyi/Library/Caches/pypoetry/virtualenvs/commitizen-demo--3a4COU6-py3.11/lib/python3.11/site-packages/questionary/prompt.py", line 78, in prompt
return unsafe_prompt(questions, answers, patch_stdout, true_color, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/btsomogyi/Library/Caches/pypoetry/virtualenvs/commitizen-demo--3a4COU6-py3.11/lib/python3.11/site-packages/questionary/prompt.py", line 223, in unsafe_prompt
answer = question.unsafe_ask(patch_stdout)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/btsomogyi/Library/Caches/pypoetry/virtualenvs/commitizen-demo--3a4COU6-py3.11/lib/python3.11/site-packages/questionary/question.py", line 89, in unsafe_ask
return self.application.run()
^^^^^^^^^^^^^^^^^^^^^^
File "/Users/btsomogyi/Library/Caches/pypoetry/virtualenvs/commitizen-demo--3a4COU6-py3.11/lib/python3.11/site-packages/prompt_toolkit/application/application.py", line 978, in run
return loop.run_until_complete(
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/btsomogyi/.asdf/installs/python/3.11.5/lib/python3.11/asyncio/base_events.py", line 653, in run_until_complete
return future.result()
^^^^^^^^^^^^^^^
File "/Users/btsomogyi/Library/Caches/pypoetry/virtualenvs/commitizen-demo--3a4COU6-py3.11/lib/python3.11/site-packages/prompt_toolkit/application/application.py", line 885, in run_async
return await _run_async(f)
^^^^^^^^^^^^^^^^^^^
File "/Users/btsomogyi/Library/Caches/pypoetry/virtualenvs/commitizen-demo--3a4COU6-py3.11/lib/python3.11/site-packages/prompt_toolkit/application/application.py", line 737, in _run_async
with self.input.raw_mode(), self.input.attach(
File "/Users/btsomogyi/.asdf/installs/python/3.11.5/lib/python3.11/contextlib.py", line 137, in __enter__
return next(self.gen)
^^^^^^^^^^^^^^
File "/Users/btsomogyi/Library/Caches/pypoetry/virtualenvs/commitizen-demo--3a4COU6-py3.11/lib/python3.11/site-packages/prompt_toolkit/input/vt100.py", line 176, in _attached_input
loop.add_reader(fd, callback_wrapper)
File "/Users/btsomogyi/.asdf/installs/python/3.11.5/lib/python3.11/asyncio/selector_events.py", line 340, in add_reader
self._add_reader(fd, callback, *args)
File "/Users/btsomogyi/.asdf/installs/python/3.11.5/lib/python3.11/asyncio/selector_events.py", line 267, in _add_reader
self._selector.register(fd, selectors.EVENT_READ,
File "/Users/btsomogyi/.asdf/installs/python/3.11.5/lib/python3.11/selectors.py", line 522, in register
self._selector.control([kev], 0, 0)
OSError: [Errno 22] Invalid argument
@btsomogyi Have you found a solution for this?
I do my first steps with
commitizen
and decided to use the docker-image.In one of my repos I hit errors, now I created a fresh git repo with only one file in it.
I get stuff like:
context:
This is on a Fedora 37 workstation, if that matters.
I randomly tried that with an older tags of the image, same issues.
Do I have some mistakes in my approach, what can I do? Thanks.