Start a new streaming operation.
(self)
| 108 | # ==================== STREAMING OPERATIONS ==================== |
| 109 | |
| 110 | async def start_streaming(self) -> None: |
| 111 | """Start a new streaming operation.""" |
| 112 | if self.streaming_state and self.streaming_state.is_active: |
| 113 | logger.warning("Streaming already active, stopping previous stream") |
| 114 | await self.stop_streaming(interrupted=True) |
| 115 | |
| 116 | self.streaming_state = StreamingState() |
| 117 | self._refresh_active = True |
| 118 | await self._start_refresh_loop() |
| 119 | |
| 120 | logger.debug("Started streaming display") |
| 121 | |
| 122 | async def add_chunk(self, raw_chunk: dict) -> None: |
| 123 | """Process and display a new chunk. |