From 72807fcd3526f31f4dc2b5fd2df96119c8c48e4c Mon Sep 17 00:00:00 2001 From: Jean Boussier Date: Fri, 11 Feb 2022 15:58:08 +0100 Subject: [PATCH] Ensure `close` is called on the response body no matter what Another fallout from https://github.com/puma/puma/pull/2809 is that in some cases the `res_body.close` wasn't called because some previous code raised. For Rails apps it means CurrentAttributes and a few other important states aren't reset properly. This is being improved on the Rails side too, but I believe it would be good to harden this on the puma side as well.