MCPcopy
hub / github.com/pallets/click / StreamMixer

Class StreamMixer

src/click/testing.py:138–153  ·  view source on GitHub ↗

Mixes ` ` and ` ` streams. The result is available in the ``output`` attribute. .. versionadded:: 8.2

Source from the content-addressed store, hash-verified

136
137
138class StreamMixer:
139 """Mixes `<stdout>` and `<stderr>` streams.
140
141 The result is available in the ``output`` attribute.
142
143 .. versionadded:: 8.2
144 """
145
146 output: io.BytesIO
147 stdout: BytesIOCopy
148 stderr: BytesIOCopy
149
150 def __init__(self) -> None:
151 self.output = io.BytesIO()
152 self.stdout = BytesIOCopy(copy_to=self.output)
153 self.stderr = BytesIOCopy(copy_to=self.output)
154
155
156class _NamedTextIOWrapper(io.TextIOWrapper):

Callers 2

isolationMethod · 0.85

Calls

no outgoing calls

Tested by 2

isolationMethod · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…