def retry.pick
import cswap-bend-cli@0.1.0.0/usage.bend as Usageimport Base
import cswap-bend-cli@0.1.0.0/usage/gate.bend as UGate
95# After a 401 and a refresh: failures keep their identity only when the
96# reference does (dead lineage, rejected client, consume-busy), else
97# `refresh-failed`.
98def retry.pick(g: UGate.Gated, +cred: String, +now: U32, +off: U32, upd: Maybe<&2, String>) -> IO(Fetched):
99 match g:
100 case UGate.Gated{c, e, consumed, acct}:
101 retry.got(c, e, consumed, cred, now, off, upd)