You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Windows(Anaconda)环境下Jupyter Themes(jt)无法生效:onedork主题缺失,界面无变化

Windows(Anaconda)环境下Jupyter Themes(jt)无法生效:onedork主题缺失,界面无变化

在Windows上全新安装Anaconda后,我通过conda-forge安装了jupyterthemes,并尝试用jt -t onedork命令设置onedork主题。虽然命令在%APPDATA%\.jupyter\custom\目录下生成了custom.css文件,但Jupyter Notebook的界面完全没有变化,而且onedork主题也没有出现在Jupyter Notebook的设置下拉菜单里。就算清理了浏览器和Jupyter的缓存、重启内核,问题还是存在。

安装日志

(base) PS C:\Users\RehanPlayz> conda install -c conda-forge jupyterthemes
Channels:
 - conda-forge
 - defaults
Platform: win-64
Collecting package metadata (repodata.json): done
Solving environment: done

## Package Plan ##

  environment location: D:\anaconda3

  added / updated specs:
    - jupyterthemes


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    certifi-2024.12.14         |     pyhd8ed1ab_0         158 KB  conda-forge
    conda-25.1.0               |  py312h2e8e312_0         1.1 MB  conda-forge
    jupyterthemes-0.20.0       |     pyhd8ed1ab_2         4.7 MB  conda-forge
    lesscpy-0.15.1             |     pyhd8ed1ab_1          41 KB  conda-forge
    libexpat-2.6.3             |       he0c23c2_0         136 KB  conda-forge
    libsqlite-3.48.0           |       h67fdade_1         876 KB  conda-forge
    libzlib-1.2.13             |       h2466b09_6          55 KB  conda-forge
    openssl-3.4.0              |       ha4e3fda_1         8.1 MB  conda-forge
    python-3.12.3              |h2628c8c_0_cpython        15.4 MB  conda-forge
    python_abi-3.12            |          5_cp312           7 KB  conda-forge
    ucrt-10.0.22621.0          |       h57928b3_1         547 KB  conda-forge
    vc14_runtime-14.42.34433   |      h6356254_24         736 KB  conda-forge
    vs2015_runtime-14.42.34433 |      hfef2bbc_24          17 KB  conda-forge
    zlib-1.2.13                |       h2466b09_6         105 KB  conda-forge
    ------------------------------------------------------------
                                           Total:        31.9 MB

The following NEW packages will be INSTALLED:

  jupyterthemes      conda-forge/noarch::jupyterthemes-0.20.0-pyhd8ed1ab_2
  lesscpy            conda-forge/noarch::lesscpy-0.15.1-pyhd8ed1ab_1
  libexpat           conda-forge/win-64::libexpat-2.6.3-he0c23c2_0
  libsqlite          conda-forge/win-64::libsqlite-3.48.0-h67fdade_1
  libzlib            conda-forge/win-64::libzlib-1.2.13-h2466b09_6
  python_abi         conda-forge/win-64::python_abi-3.12-5_cp312
  ucrt               conda-forge/win-64::ucrt-10.0.22621.0-h57928b3_1
  vc14_runtime       conda-forge/win-64::vc14_runtime-14.42.34433-h6356254_24

The following packages will be UPDATED:

  conda              pkgs/main::conda-24.11.3-py312haa9553~ --> conda-forge::conda-25.1.0-py312h2e8e312_0
  zlib                    pkgs/main::zlib-1.2.13-h8cc25b3_1 --> conda-forge::zlib-1.2.13-h2466b09_6

The following packages will be SUPERSEDED by a higher-priority channel:

  certifi            pkgs/main/win-64::certifi-2024.12.14-~ --> conda-forge/noarch::certifi-2024.12.14-pyhd8ed1ab_0
  python                pkgs/main::python-3.12.7-h14ffc60_0 --> conda-forge::python-3.12.3-h2628c8c_0_cpython


Proceed ([y]/n)? y


Downloading and Extracting Packages:

Preparing transaction: done
Verifying transaction: done
Executing transaction: done
(base) PS C:\Users\RehanPlayz> jt -l
Available Themes:
   chesterish
   grade3
   gruvboxd
   gruvboxl
   monokai
   oceans16
   onedork
   solarizedd
   solarizedl
(base) PS C:\Users\RehanPlayz> jt -t onedork
(base) PS C:\Users\RehanPlayz> jupyter notebook
[I 2025-01-24 18:27:01.952 ServerApp] Extension package jupyter_lsp took 0.4627s to import
[W 2025-01-24 18:27:01.953 ServerApp] A `_jupyter_server_extension_points` function was not found in jupyter_lsp. Instead, a `_jupyter_server_extension_paths` function was found and will be used for now. This function name will be deprecated in future releases of Jupyter Server.
[I 2025-01-24 18:27:02.320 ServerApp] Extension package jupyter_server_terminals took 0.3666s to import
[W 2025-01-24 18:27:03.703 ServerApp] A `_jupyter_server_extension_points` function was not found in notebook_shim. Instead, a `_jupyter_server_extension_paths` function was found and will be used for now. This function name will be deprecated in future releases of Jupyter Server.
[I 2025-01-24 18:27:12.043 ServerApp] Extension package panel.io.jupyter_server_extension took 8.3205s to import
[I 2025-01-24 18:27:12.044 ServerApp] jupyter_lsp | extension was successfully linked.
[I 2025-01-24 18:27:12.053 ServerApp] jupyter_server_terminals | extension was successfully linked.
[I 2025-01-24 18:27:12.066 ServerApp] jupyterlab | extension was successfully linked.
[I 2025-01-24 18:27:12.079 ServerApp] notebook | extension was successfully linked.
[I 2025-01-24 18:27:14.372 ServerApp] notebook_shim | extension was successfully linked.
[I 2025-01-24 18:27:14.373 ServerApp] panel.io.jupyter_server_extension | extension was successfully linked.
[I 2025-01-24 18:27:14.492 ServerApp] notebook_shim | extension was successfully loaded.
[I 2025-01-24 18:27:14.495 ServerApp] jupyter_lsp | extension was successfully loaded.
[I 2025-01-24 18:27:14.496 ServerApp] jupyter_server_terminals | extension was successfully loaded.
[I 2025-01-24 18:27:14.519 LabApp] JupyterLab extension loaded from D:\anaconda3\Lib\site-packages\jupyterlab
[I 2025-01-24 18:27:14.520 LabApp] JupyterLab application directory is D:\anaconda3\share\jupyter\lab
[I 2025-01-24 18:27:14.521 LabApp] Extension Manager is 'pypi'.
[I 2025-01-24 18:27:14.859 ServerApp] jupyterlab | extension was successfully loaded.
[I 2025-01-24 18:27:14.868 ServerApp] notebook | extension was successfully loaded.
[I 2025-01-24 18:27:14.869 ServerApp] panel.io.jupyter_server_extension | extension was successfully loaded.
[I 2025-01-24 18:27:14.872 ServerApp] Serving notebooks from local directory: C:\Users\RehanPlayz
[I 2025-01-24 18:27:14.873 ServerApp] Jupyter Server 2.14.1 is running at:
[I 2025-01-24 18:27:14.873 ServerApp] http://localhost:8888/tree?token=e48606499e8e2fb7722fbd8b393432e50e825086116a19d8
[I 2025-01-24 18:27:14.873 ServerApp]     http://127.0.0.1:8888/tree?token=e48606499e8e2fb7722fbd8b393432e50e825086116a19d8
[I 2025-01-24 18:27:14.873 ServerApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
[C 2025-01-24 18:27:14.991 ServerApp]

    To access the server, open this file in a browser:
        file:///C:/Users/RehanPlayz/AppData/Roaming/jupyter/runtime/jpserver-13384-open.html
    Or copy and paste one of these URLs:
        http://localhost:8888/tree?token=e48606499e8e2fb7722fbd8b393432e50e825086116a19d8
        http://127.0.0.1:8888/tree?token=e48606499e8e2fb7722fbd8b393432e50e825086116a19d8
[W 2025-01-24 18:27:15.115 ServerApp] Could not determine npm prefix: [WinError 2] The system cannot find the file specified
[I 2025-01-24 18:27:15.307 ServerApp] Skipped non-installed server(s): bash-language-server, dockerfile-language-server-nodejs, javascript-typescript-langserver, jedi-language-server, julia-language-server, pyright, python-language-server, r-languageserver, sql-language-server, texlab, typescript-language-server, unified-language-server, vscode-css-languageserver-bin, vscode-html-languageserver-bin, vscode-json-languageserver-bin, yaml-language-server
0.00s - Debugger warning: It seems that frozen modules are being used, which may
0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off
0.00s - to python to disable frozen modules.
0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation

我尝试过的解决方法

  • 通过conda install -c conda-forge jupyterthemes重新安装了jupyterthemes
  • 执行jt -t onedork命令设置主题
  • 重启Jupyter Notebook并执行浏览器强制刷新(Ctrl + Shift + R)
  • 确认custom.css文件存在于%APPDATA%\.jupyter\custom\目录中
  • 重新安装Anaconda后重复上述所有步骤

预期行为

成功将onedork主题应用到Jupyter Notebook界面

实际结果

界面完全没有主题变化,而且onedork主题根本没有出现在主题设置下拉菜单中:
Actual Results

备注:内容来源于stack exchange,提问作者user29392144

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.04.14 15:35:28