10 if (offlineReason) return // known-down cluster: reads behave as "not found" rather than hanging 14 const resp = await withKubeRetry(() => objectApi.read(resource), cluster_name) 16 // console.log('readResource', resource.metadata.name, resp.response.statusCode) 17 // if (resp.response.statusCode == 200) return resp.body 18 } catch(err: unknown) { 19 const e = err as {body?: string} 20 if (!e.body) throw err 21 if (e.body.trim() == '404 page not found') return 22 const {reason} = json1Parse(e.body) as { reason?: string } 23 if (reason == 'NotFound') return 24 throw new PtErr('!read2Resource', {err, reason})