mirror of
https://github.com/anthropics/claude-code-sdk-python.git
synced 2025-12-23 09:19:52 +00:00
Simplify is_ready and end_input
This commit is contained in:
parent
68f0d7aa7d
commit
16f6713b37
1 changed files with 1 additions and 10 deletions
|
|
@ -273,9 +273,6 @@ class SubprocessCLITransport(Transport):
|
|||
with suppress(Exception):
|
||||
await self._stdin_stream.aclose()
|
||||
self._stdin_stream = None
|
||||
if self._process and self._process.stdin:
|
||||
with suppress(Exception):
|
||||
await self._process.stdin.aclose()
|
||||
|
||||
def read_messages(self) -> AsyncIterator[dict[str, Any]]:
|
||||
"""Read and parse messages from the transport."""
|
||||
|
|
@ -372,10 +369,4 @@ class SubprocessCLITransport(Transport):
|
|||
|
||||
def is_ready(self) -> bool:
|
||||
"""Check if transport is ready for communication."""
|
||||
return (
|
||||
self._ready
|
||||
and self._process is not None
|
||||
and self._process.returncode is None
|
||||
)
|
||||
|
||||
# Remove interrupt and control request methods - these now belong in Query class
|
||||
return self._ready
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue