You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello,
When I write an invalid command in Click REPL - e.g. "nonsensicalcmd" the moment I press space after the command I get this:
Unhandled exception in event loop:
File "/home/abc/proj/.venv/lib/python3.11/site-packages/prompt_toolkit/buffer.py", line 1919, in new_coroutine
await coroutine(*a, **kw)
File "/home/abc/proj/.venv/lib/python3.11/site-packages/prompt_toolkit/buffer.py", line 1743, in async_completer
async for completion in async_generator:
File "/home/abc/proj/.venv/lib/python3.11/site-packages/prompt_toolkit/completion/base.py", line 323, in get_completions_async
async for completion in completer.get_completions_async(
File "/home/abc/proj/.venv/lib/python3.11/site-packages/prompt_toolkit/completion/base.py", line 199, in get_completions_async
for item in self.get_completions(document, complete_event):
File "/home/abc/proj/.venv/lib/python3.11/site-packages/click_repl/_completer.py", line 257, in get_completions
self.parsed_ctx = _resolve_context(args, self.ctx)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/abc/proj/.venv/lib/python3.11/site-packages/click_repl/utils.py", line 46, in _resolve_context
name, cmd, args = command.resolve_command(ctx, args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/abc/proj/.venv/lib/python3.11/site-packages/click/core.py", line 1746, in resolve_command
ctx.fail(_("No such command {name!r}.").format(name=original_cmd_name))
File "/home/abc/proj/.venv/lib/python3.11/site-packages/click/core.py", line 684, in fail
raise UsageError(message, self)
Exception No such command 'nonsensicalcmd'.
Press ENTER to continue...
I would expect that it would write nothing up until the point when I press enter, then I'd expect something like Error: No such command 'nonsensicalcmd'. (Click without REPL writes this). It is definitely odd that there's an unhandled exception.
Used versions:
click 8.1.7
click_repl 0.3.0
Python 3.11.6
The text was updated successfully, but these errors were encountered:
Hello,
When I write an invalid command in Click REPL - e.g. "nonsensicalcmd" the moment I press space after the command I get this:
I would expect that it would write nothing up until the point when I press enter, then I'd expect something like
Error: No such command 'nonsensicalcmd'.
(Click without REPL writes this). It is definitely odd that there's an unhandled exception.Used versions:
click 8.1.7
click_repl 0.3.0
Python 3.11.6
The text was updated successfully, but these errors were encountered: