$ pixee explain
Reading results from `results.codetf.json`
No changes applied
Traceback (most recent call last):
File "/opt/homebrew/bin/pixee", line 8, in <module>
sys.exit(main())
^^^^^^
File "/opt/homebrew/Cellar/pixee/0.5.5/libexec/lib/python3.11/site-packages/click/core.py", line 1157, in __call__
return self.main(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/Cellar/pixee/0.5.5/libexec/lib/python3.11/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
^^^^^^^^^^^^^^^^
File "/opt/homebrew/Cellar/pixee/0.5.5/libexec/lib/python3.11/site-packages/click/core.py", line 1688, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/Cellar/pixee/0.5.5/libexec/lib/python3.11/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, **ctx.params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/Cellar/pixee/0.5.5/libexec/lib/python3.11/site-packages/click/core.py", line 783, in invoke
return __callback(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/Cellar/pixee/0.5.5/libexec/lib/python3.11/site-packages/pixee/cli.py", line 388, in explain
codemod := select(
^^^^^^^
File "/opt/homebrew/Cellar/pixee/0.5.5/libexec/lib/python3.11/site-packages/questionary/prompts/select.py", line 133, in select
raise ValueError("A list of choices needs to be provided.")
ValueError: A list of choices needs to be provided.
When running
pixee explainon an empty result set, the following exception occurs:There are probably two changes we should make for this fix:
pixee explainexits cleanly without an exception in the case of an empty CodeTF filepixee fixdoes not generate any fixes. This would help ensure that the last actual fix results remain available forpixee explainwhere applicable.