-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Closed
Description
Hi! I'm trying to run prompt-toolkit (the main prompt engine for xonsh shell) and facing with exception.
# rustpython v0.4.0 (https://github.com/RustPython/RustPython#92acf339)
rustpython -m pip install prompt-toolkit # 3.0.52ptk.py:
from prompt_toolkit import prompt
text = prompt("Say something: ")
print("You said:", text)Run:
~/.cargo/bin/rustpython ptk.pyTraceback (most recent call last):
File "ptk.py", line 3, in <module>
text = prompt("Say something: ")
File "/Users/pc/.local/lib/rustpython3.13/site-packages/prompt_toolkit/shortcuts/prompt.py", line 1494, in prompt
inputhook=inputhook,
File "/Users/pc/.local/lib/rustpython3.13/site-packages/prompt_toolkit/shortcuts/prompt.py", line 1059, in prompt
inputhook=inputhook,
File "/Users/pc/.local/lib/rustpython3.13/site-packages/prompt_toolkit/application/application.py", line 1002, in run
return asyncio.run(coro)
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/asyncio/runners.py", line 193, in run
with Runner(debug=debug, loop_factory=loop_factory) as runner:
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/asyncio/runners.py", line 194, in run
return runner.run(main)
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/asyncio/runners.py", line 129, in run
signal.signal(signal.SIGINT, signal.default_int_handler)
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/asyncio/runners.py", line 124, in run
raise # CancelledError
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/asyncio/runners.py", line 118, in run
return self._loop.run_until_complete(task)
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/asyncio/base_events.py", line 687, in run_until_complete
return future.result()
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/asyncio/futures.py", line 203, in result
raise self._exception.with_traceback(self._exception_tb)
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/asyncio/tasks.py", line 314, in __step_run_and_handle_result
result = coro.send(None)
File "/Users/pc/.local/lib/rustpython3.13/site-packages/prompt_toolkit/application/application.py", line 865, in run_async
with ExitStack() as stack:
File "/Users/pc/.local/lib/rustpython3.13/site-packages/prompt_toolkit/application/application.py", line 877, in run_async
stack.enter_context(set_handle_sigint(loop))
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/contextlib.py", line 530, in enter_context
result = _enter(cm)
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/contextlib.py", line 143, in __enter__
raise RuntimeError("generator didn't yield") from None
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/contextlib.py", line 141, in __enter__
return next(self.gen)
File "/Users/pc/.local/lib/rustpython3.13/site-packages/prompt_toolkit/application/application.py", line 810, in set_handle_sigint
with _restore_sigint_from_ctypes():
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/contextlib.py", line 143, in __enter__
raise RuntimeError("generator didn't yield") from None
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/contextlib.py", line 141, in __enter__
return next(self.gen)
File "/Users/pc/.local/lib/rustpython3.13/site-packages/prompt_toolkit/application/application.py", line 1610, in _restore_sigint_from_ctypes
pythonapi.PyOS_getsig.restype = c_void_p
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/ctypes/__init__.py", line 412, in __getattr__
func = self.__getitem__(name)
File "/Users/pc/.cargo/git/checkouts/rustpython-63090cdce5e18442/92acf33/crates/pylib/Lib/ctypes/__init__.py", line 417, in __getitem__
func = self._FuncPtr((name_or_ordinal, self))
AttributeError: dlsym failedMetadata
Metadata
Assignees
Labels
No labels