Pull ``data.supported`` off a -32022 error, or ``None`` if not actionable.
(data: Any)
| 31 | |
| 32 | |
| 33 | def _parse_supported(data: Any) -> list[str] | None: |
| 34 | """Pull ``data.supported`` off a -32022 error, or ``None`` if not actionable.""" |
| 35 | try: |
| 36 | return types.UnsupportedProtocolVersionErrorData.model_validate(data).supported |
| 37 | except ValidationError: |
| 38 | return None |
| 39 | |
| 40 | |
| 41 | async def negotiate_auto(session: ClientSession) -> None: |