From acc05ca02f195a55c2ea0e0355cc628235eae918 Mon Sep 17 00:00:00 2001 From: Oneric Date: Sat, 23 Aug 2025 00:00:00 +0000 Subject: [PATCH] http: avoid failures connecting to HTTP2 servers supporting server push --- lib/pleroma/http/adapter_helper.ex | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/pleroma/http/adapter_helper.ex b/lib/pleroma/http/adapter_helper.ex index 6f5a39662..6663758d0 100644 --- a/lib/pleroma/http/adapter_helper.ex +++ b/lib/pleroma/http/adapter_helper.ex @@ -37,7 +37,11 @@ def options(opts \\ []) do conn_opts: [ # Do NOT add cacerts here as this will cause issues for plain HTTP connections! # (when we upgrade our deps to Mint >= 1.6.0 we can also explicitly enable "inet4: true") - transport_opts: [inet6: true] + transport_opts: [inet6: true], + # up to at least version 0.20.0, Finch leaves server_push enabled by default for HTTP2, + # but will actually raise an exception when receiving such a response. Tell servers we don't want it. + # see: https://github.com/sneako/finch/issues/325 + client_settings: [enable_push: false] ] ] }