When Yaak moved compression, redirect, and multipart handling out of
reqwest, it started explicitly adding Content-Length as an HTTP header.
Over HTTP/2, hyper also sets content-length internally via DATA frame
sizing, causing a duplicate that HTTP/2 servers (like Node.js) reject
with PROTOCOL_ERROR.
Instead of setting Content-Length as an explicit header, carry the
content length through SendableBody::Stream and use http_body::Body's
size_hint() to let hyper handle it automatically for both HTTP/1.1
and HTTP/2.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Skip disabled headers, metadata, URL parameters, and form body
entries in the render phase for HTTP, gRPC, and WebSocket requests.
Previously, disabled entries were still template-rendered even though
they were filtered out later at the use site.
The skip_cache flag in services() called reflect(), but reflect() had its
own cache check that returned early. Simplified by removing skip_cache and
always invalidating the pool in cmd_grpc_reflect, since that command is
only called when fresh schema is needed.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add new_xplatform_command() helper in yaak-common that creates a
tokio::process::Command with CREATE_NO_WINDOW flag set on Windows.
Also converts git commands to async for consistency.
Previously, when a gRPC streaming message failed to deserialize (e.g., wrong
type like int instead of string), the error was silently logged and the message
was dropped. Now errors are surfaced to the UI as GrpcEventType::Error events.
Changed the streaming/client_streaming methods to accept an on_message callback
that handles both success (logs ClientMessage) and error (logs Error) cases,
rather than logging the client message prematurely before deserialization.
The gRPC streaming code was using tokio::runtime::Handle::current().block_on()
inside filter_map closures, which caused a panic ('Cannot start a runtime from
within a runtime') when called from an async context.
Fixed by replacing the pattern with .then(async move { ... }).filter_map(|x| x)
which properly handles async operations in stream pipelines.
This fixes the gRPC Ping/Pong freeze issue and restores request cancellation.