+- **Context:** PR #1020 switched the Thrift backend to `TBinaryProtocolAccelerated` so replies decode in C. Two things came up. First, that class falls back to pure Python without any error when `thrift.protocol.fastbinary` isn't built, and it only takes the C path when the transport is a `CReadableTransport`, so a plain round-trip test passes without ever running the C decoder. The fix was a test, skipped when fastbinary is absent, that wraps `protocol._fast_decode` with `Mock(wraps=...)` and asserts it was called. Second, the accelerated protocol also changes request *encoding*, and the C encoder rejects structs nested deeper than about 64 levels (for example native array parameters 62+ deep). So the client was built as `TCLIService.Client(accelerated_input, pure_python_output)`, with a test checking that both encoders produce byte-identical requests.
0 commit comments