FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
vscode-python/pythonFiles/datascience/getServerInfo.py at master · dawnsummit/vscode-python · GitHub
dawnsummit
/
vscode-python
Public
forked from
microsoft/vscode-python
Notifications
You must be signed in to change notification settings
Fork
0
Star
0
Code
Pull requests
0
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
vscode-python
/
pythonFiles
/
datascience
/
getServerInfo.py
Copy path
More file actions
More file actions
Latest commit
History
History
History
24 lines (19 loc) · 797 Bytes
Breadcrumbs
vscode-python
/
pythonFiles
/
datascience
/
getServerInfo.py
Copy path
File metadata and controls
24 lines (19 loc) · 797 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
from
notebook
.
notebookapp
import
list_running_servers
import
json
server_list
=
list_running_servers
()
server_info_list
=
[]
for
si
in
server_list
:
server_info_object
=
{}
server_info_object
[
"base_url"
]
=
si
[
'base_url'
]
server_info_object
[
"notebook_dir"
]
=
si
[
'notebook_dir'
]
server_info_object
[
"hostname"
]
=
si
[
'hostname'
]
server_info_object
[
"password"
]
=
si
[
'password'
]
server_info_object
[
"pid"
]
=
si
[
'pid'
]
server_info_object
[
"port"
]
=
si
[
'port'
]
server_info_object
[
"secure"
]
=
si
[
'secure'
]
server_info_object
[
"token"
]
=
si
[
'token'
]
server_info_object
[
"url"
]
=
si
[
'url'
]
server_info_list
.
append
(
server_info_object
)
print
(
json
.
dumps
(
server_info_list
))
Back
|
FazBrowse Home
|
New Git URL