当前位置:网站首页>Solution: jupyter notebook does not pop up the default browser
Solution: jupyter notebook does not pop up the default browser
2022-07-03 10:59:00 【33-Hope】
Write to yourself
1. First , Make sure your problem is :Jupyter-notebook It works , But do not pop up the default browser , Such as below ( Only the following figure , The browser is dead !):

Solution :
- There are multiple browsers on the computer , And no default browser is set , Please select a browser set as the default .( Method by https://zhuanlan.zhihu.com/p/33266087 The author provides , But it doesn't work for me )
- modify Jupyter-notebook Configuration file for
First, the location of the file is :C:\Users\ user name .jupyter ( Be careful , The user name is set by yourself , such as Zhang , This depends on your c The specific name of the disk ), Open mode selection Notepad Just fine , Of course, other applications are optional

Search for
#c.NotebookApp.browser = '', The following situation will pop up (Ctrl + H Search for )
Next, modify , After the sentence searched above , add to :
import webbrowser
webbrowser.register(
"Firefox", # Custom name , Please delete this comment when copying
None,
webbrowser.GenericBrowser(u"D:\\Program Files\\Firefox\\firefox.exe"))
c.NotebookApp.browser = "Firefox"
( Code from : Adding a link description must be successful !!!Jupyter-notebook Modify the default browser and default opening location )
- The results are as follows :

Here are some things to pay attention to :
webbrowser.GenericBrowser(u"D:\\Program Files\\Firefox\\firefox.exe"))# Specify the location of the program
The location of the program in this code , Write according to the location of your own program , Don't copy my . If you don't know the browser is installed inside , Icons can be found on the desktop , Right click , attribute :
- Notice after checking , Modify according to the code given above , namely \ It needs to be changed into two “\”
webbrowser.GenericBrowser(u"E:\\Software\\Firefox\\firefox.exe")) - Any browser can , I use Firefox . But ask for : The installation directory of the browser should not have Chinese ,( My Google has Chinese , All Firefox's ) As for how to solve Chinese , Please Baidu I'm tired , Don't want Baidu .
边栏推荐
猜你喜欢

Take you into the cloud native database industry, Amazon Aurora

MySQL checks for automatic updates at 0:00 every day

QT:QSS自定义 QTreeView实例

Comment réaliser des tests automatisés pour les tests logiciels embarqués?

现在零基础转行软件测试还OK吗?

QT: QSS custom qtabwidget and qtabbar instances

I, a tester from a large factory, went to a state-owned enterprise with a 50% pay cut. I regret it

What kind of living condition is a tester with a monthly salary of more than 10000?

After 8 years of industry thinking, the test director has a deeper understanding of test thinking

What happened to those who focused on automated testing?
随机推荐
《通信软件开发与应用》
C language project: student achievement system
Flink chain conditional source code analysis
Programming examples of stm32f1 and stm32subeide -tm1637 drives 4-bit 7-segment nixie tubes
sqlmap基本使用方法
Promoted, colleagues become subordinates and don't cooperate with work
QT: QSS custom qtabwidget and qtabbar instances
Game test related tests a hero's skills (spring moves are asked more questions)
Bidding website architecture project progress -- Network Security
QT:QSS自定义 QSplitter实例
Qt:qss custom qstatusbar instance
月薪过万的测试员,是一种什么样的生活状态?
Test what the leader should do
QT:QSS自定义QListView实例
Exclusive analysis | truth about resume and interview
15 software testing Trends Worthy of attention
软件测试必学基本理论知识——APP测试
我,大厂测试员,降薪50%去国企,后悔了...
Do you really need automated testing?
Flink < --> Introduction to JDBC +with parameter