jupyter NoteBook 网页空白各种解决方法(实在不行用pyCharm替代Chrome)

先说下我这边的原因,jupyter notebook版本太高了,js报错找不到text/plain,回退版本可以解决问题。

 

总结一下尝试了的方法:

 

方法1(无效): 把谷歌浏览器设置成默认打开方式

https://blog.csdn.net/xavier_muse/article/details/83830394

 

方法2(无效):升级谷歌浏览器

https://blog.csdn.net/u012724887/article/details/81667193

 

方法3(无效):清除cache

https://github.com/jupyter/notebook/issues/1627

 

方法4(无效):用火狐浏览器

 

方法5(无效):关闭防火墙,

或允许ipython.exe,pythonw.exe,jupyter-notebook.exe, jupyter.exe通过Windows防火墙通信

https://blog.csdn.net/xc555/article/details/81944979

https://blog.csdn.net/weixin_41813895/article/details/81739502

 

方法6(有效,重点尝试):回退jupyter版本(5.7.6版本更新导致的问题)

参考:https://blog.csdn.net/qq_35531549/article/details/88594422

pip uninstall jupyter notebook

pip install jupyter notebook==5.7.4

不行的话可以退得更老一点

方法7(有效):修改源码

参考:https://github.com/jupyter/notebook/pull/4468/files

路径:Anaconda\env\你的环境\Lib\site-packages\notebook\notebookapp.py

修改def init_mime_overrides(self):

    def init_mime_overrides(self):
        # On some Windows machines, an application has registered an incorrect
        # mimetype for CSS in the registry. Tornado uses this when serving
        # .css files, causing browsers to reject the stylesheet. We know the
        # mimetype always needs to be text/css, so we override it here.
        # mimetype for CSS and JavaScript in the registry.
        # Tornado uses this when serving .css and .js files, causing browsers to
        # reject these files. We know the mimetype always needs to be text/css for css
        # and application/javascript for JS, so we override it here.
        mimetypes.add_type('text/css', '.css')
        mimetypes.add_type('application/javascript', '.js')

终极杀招:用PyCharm替代chrome

谁用谁爽

 

原因分析

参考:http://blog.sina.com.cn/s/blog_17deaab6e0102ykin.html

按下F12,错误如下MIME type ('text/plain') is not executable

解决办法参考https://www.dropboxforum.com/t5/API-Support-Feedback/MIME-type-text-plain-is-not-executable/td-p/271231

也就是需要用application/javascript替换

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

朱铭德

五毛也是爱٩(●´৺`●)૭

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值