From c6ccfc8e217fcdfb5d0617d2023197882eb109fe Mon Sep 17 00:00:00 2001 From: Akshay Mankar Date: Tue, 12 Dec 2023 15:55:34 +0100 Subject: [PATCH 1/2] Use fork of warp which closes connections gracefully Upstream PR: https://github.com/yesodweb/wai/pull/958 --- nix/haskell-pins.nix | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/nix/haskell-pins.nix b/nix/haskell-pins.nix index 3328105e2a8..c4290b5253e 100644 --- a/nix/haskell-pins.nix +++ b/nix/haskell-pins.nix @@ -264,6 +264,17 @@ let sha256 = "sha256-xcGZ11ocdlB8ks20QAhtPZ+4ggmV4Om4CPHH/M6NjXk="; }; }; + # PR: https://github.com/yesodweb/wai/pull/958 + warp = { + src = fetchgit { + url = "https://github.com/wireapp/wai"; + rev = "bedd6a835f6d98128880465c30e8115fa986e3f6"; + sha256 = "sha256-0r/d9YwcKZIZd10EhL2TP+W14Wjk0/S8Q4pVvZuZLaY="; + }; + packages = { + "warp" = "warp"; + }; + }; }; hackagePins = { # Major re-write upstream, we should get rid of this dependency rather than @@ -292,10 +303,6 @@ let version = "1.4.0"; sha256 = "sha256-zPT/FMxAiR94NReqNIDa/RS7dtiNWCRe3SZi8P11GDk="; }; - warp = { - version = "3.3.30"; - sha256 = "sha256-VrK27a2wFtezh9qabcXGe2tw9EwBmI8mKwmpCtXq9rc="; - }; warp-tls = { version = "3.4.3"; sha256 = "sha256-6MjlCKGC8v+7OiSuMFGwO8sgcA3gp0OfOnneI2wSpWI="; From 27c170d60c5f1e92fc59b7813334148c516eb433 Mon Sep 17 00:00:00 2001 From: Akshay Mankar Date: Tue, 12 Dec 2023 16:01:33 +0100 Subject: [PATCH 2/2] changelog --- changelog.d/3-bug-fixes/warp-connection-close | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 changelog.d/3-bug-fixes/warp-connection-close diff --git a/changelog.d/3-bug-fixes/warp-connection-close b/changelog.d/3-bug-fixes/warp-connection-close new file mode 100644 index 00000000000..cd7542f057d --- /dev/null +++ b/changelog.d/3-bug-fixes/warp-connection-close @@ -0,0 +1,3 @@ +Ensure that HTTP 1.1 connections are grafully closed + +To fix this warp had to be patched to fix the bug upstream: https://github.com/yesodweb/wai/pull/958 \ No newline at end of file