I honestly don’t remember the last time this was an issue where I live (other than stores not taking cards at all). That said I do carry a couple hundreds bucks worth of local currency just in case. Also, let’s fuckin finally switch our electronic payments to Taler which can fallback to working offline (but with less scam protection for vendors).
GNU Taler - Taxable Anonymous Libre Electronic Resources

A payment system that makes privacy-friendly online transactions fast and easy.

Happened in Canada when Rogers (one of the Big Three mobile carriers here) shit the bed in 2022, card machines weren’t working in some restaurants and shops, debit ATMs stopped working too. Cash was king for a couple days.