MCPcopy
hub / github.com/Textualize/textual / set_pre_await_callback

Method set_pre_await_callback

src/textual/await_complete.py:38–47  ·  view source on GitHub ↗

Set a callback to run prior to awaiting. This is used by Textual, mainly to check for possible deadlocks. You are unlikely to need to call this method in an app. Args: pre_await: A callback.

(self, pre_await: CallbackType | None)

Source from the content-addressed store, hash-verified

36 yield "caller", self._caller, None
37
38 def set_pre_await_callback(self, pre_await: CallbackType | None) -> None:
39 """Set a callback to run prior to awaiting.
40
41 This is used by Textual, mainly to check for possible deadlocks.
42 You are unlikely to need to call this method in an app.
43
44 Args:
45 pre_await: A callback.
46 """
47 self._pre_await = pre_await
48
49 def call_next(self, node: MessagePump) -> Self:
50 """Await after the next message.

Callers 1

dismissMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected