bug: webui not loading in firefox with cookies and localStorage disabled

未关闭
#2,190 13 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

  • #2192 来自 @whizzzkid —— 已关闭,未合并

评估

难度
4/5
预计耗时
3-5 天
新手友好度
25/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
停滞
技术栈
javascript
领域
frontend

调研方向

在禁用 cookies 和 localStorage 的 Firefox 隐私模式下重现该故障,然后检查 i18nextLocalStorageBackend.js 和 money-clip.m.js 中显示的存储路径。确定这两个存储错误如何影响启动,并验证在报告的设置下 Web UI 能够成功加载且不会出现这些 DOMExceptions。

由索引模型根据 Issue 内容生成。

描述

effort/days exp/expert help wanted kind/enhancement kind/support need/analysis P3 status/deferred topic/infra

Describe the bug
I try to open webui and browser show me nothing.

My browser Firefox in private mod. All cookies disabled in settings. It is block access to local storage.

In console i see errors:

First error:

17:08:30.946 Uncaught DOMException: The operation is insecure.
    value i18nextLocalStorageBackend.js:50
    e i18nextLocalStorageBackend.js:60
    value i18nextChainedBackend.js:19
    value i18nextChainedBackend.js:49
    n i18next.js:1925
    value i18next.js:2361
    61455 i18n.js:19
    Webpack 4
        __webpack_require__
        <anonymous>
        <anonymous>
        <anonymous>
main.20056d59.js:2
    value i18nextLocalStorageBackend.js:50
    e i18nextLocalStorageBackend.js:60
    value i18nextChainedBackend.js:19
    forEach self-hosted:203
    value i18nextChainedBackend.js:49
    n i18next.js:1925
    value i18next.js:2361
    61455 i18n.js:19
    Webpack 4
        __webpack_require__
        <анонимный>
        <анонимный>
        <анонимный>

Error happen here in code (i18nextLocalStorageBackend.js:50):

function getDefaults() {
  return {
    prefix: 'i18next_res_',
    expirationTime: 7 * 24 * 60 * 60 * 1000,
    defaultVersion: undefined,
    versions: {},
    store: typeof window !== 'undefined' ? window.localStorage : null /* error on this line */
  };
}

Second error:

17:08:30.988 Uncaught (in promise) DOMException: The operation is insecure.
    n money-clip.m.js:32
2 main.20056d59.js:2

Error happen here in code (money-clip.m.js:32):

function createStore(dbName, storeName) {
    const dbp = idbReady().then(() => {
        const request = indexedDB.open(dbName); /* error on this line */
        request.onupgradeneeded = () => request.result.createObjectStore(storeName);
        return promisifyRequest(request);
    });
    return (txMode, callback) => dbp.then((db) => callback(db.transaction(storeName, txMode).objectStore(storeName)));
}

To Reproduce
Steps to reproduce the behavior:

  1. Disable all cookies in Firefox
  2. Open webui in private mod

Expected behavior
Web UI is shown

Desktop (please complete the following information):

  • OS: Windows 7
  • Browser Firefox
  • Version 115.5.0esr (64-разрядный)
主要语言
JavaScript
星标
1.6k
派生
539
PR 合并指标
30 天内没有已合并 PR

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

ipfs/ipfs-webui 的其他 Issue

查看 ipfs/ipfs-webui 的全部 Issue

相似的 Issue

更多 JavaScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。