Skip to content

Commit d23a5f8

Browse files
committed
Update binder link #26
1 parent 1e5e797 commit d23a5f8

File tree

3 files changed

+128
-109
lines changed

3 files changed

+128
-109
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# jupyterlab-notifications
22

33
![Github Actions Status](https://github.com/mwakaba2/jupyterlab-notifications/workflows/Build/badge.svg)
4-
[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/mwakaba2/jupyterlab-notifications/main?urlpath=/lab/tree/demo.ipynb)
4+
[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/mwakaba2/jupyterlab-notifications/main?urlpath=lab/tree/tutorial/py3_demo.ipynb)
55
[![PyPI](https://img.shields.io/pypi/v/jupyterlab-notifications.svg)](https://pypi.org/project/jupyterlab-notifications)
66
[![npm](https://img.shields.io/npm/v/jupyterlab-notifications.svg)](https://www.npmjs.com/package/jupyterlab-notifications)
77

binder/environment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@ name: jupyterlab-notifications
22
channels:
33
- conda-forge
44
dependencies:
5-
- jupyterlab=3
5+
- jupyterlab>=3.1
66
- pip:
77
- jupyterlab-notifications==0.3.0

tutorial/py3_demo.ipynb

Lines changed: 126 additions & 107 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,29 @@
11
{
22
"cells": [
3+
{
4+
"cell_type": "markdown",
5+
"source": [
6+
"## Jupyterlab Notification Python Demo\n",
7+
"For this demo, make sure to update `minimum_cell_execution_time` to 1 second in Settings > Advanced Settings Editor > Notifications."
8+
],
9+
"metadata": {}
10+
},
311
{
412
"cell_type": "code",
513
"execution_count": 143,
14+
"source": [
15+
"!sleep 11\n",
16+
"print(\"hello world!\")"
17+
],
18+
"outputs": [
19+
{
20+
"output_type": "stream",
21+
"name": "stdout",
22+
"text": [
23+
"hello world!\n"
24+
]
25+
}
26+
],
627
"metadata": {
728
"execution": {
829
"iopub.execute_input": "2021-07-26T02:25:15.792618Z",
@@ -13,24 +34,24 @@
1334
},
1435
"status": "ok",
1536
"tags": []
16-
},
37+
}
38+
},
39+
{
40+
"cell_type": "code",
41+
"execution_count": 142,
42+
"source": [
43+
"!sleep 1\n",
44+
"print(\"hello world!\")"
45+
],
1746
"outputs": [
1847
{
19-
"name": "stdout",
2048
"output_type": "stream",
49+
"name": "stdout",
2150
"text": [
2251
"hello world!\n"
2352
]
2453
}
2554
],
26-
"source": [
27-
"!sleep 11\n",
28-
"print(\"hello world!\")"
29-
]
30-
},
31-
{
32-
"cell_type": "code",
33-
"execution_count": 142,
3455
"metadata": {
3556
"execution": {
3657
"iopub.execute_input": "2021-07-26T02:23:54.629936Z",
@@ -41,24 +62,24 @@
4162
},
4263
"status": "ok",
4364
"tags": []
44-
},
65+
}
66+
},
67+
{
68+
"cell_type": "code",
69+
"execution_count": 62,
70+
"source": [
71+
"!sleep 2\n",
72+
"print(\"hello world again!\")"
73+
],
4574
"outputs": [
4675
{
47-
"name": "stdout",
4876
"output_type": "stream",
77+
"name": "stdout",
4978
"text": [
50-
"hello world!\n"
79+
"hello world again!\n"
5180
]
5281
}
5382
],
54-
"source": [
55-
"!sleep 1\n",
56-
"print(\"hello world!\")"
57-
]
58-
},
59-
{
60-
"cell_type": "code",
61-
"execution_count": 62,
6283
"metadata": {
6384
"execution": {
6485
"iopub.execute_input": "2021-07-18T19:49:34.088207Z",
@@ -68,24 +89,24 @@
6889
"shell.execute_reply.started": "2021-07-18T19:49:34.088134Z"
6990
},
7091
"tags": []
71-
},
92+
}
93+
},
94+
{
95+
"cell_type": "code",
96+
"execution_count": 63,
97+
"source": [
98+
"!sleep 5\n",
99+
"print(\"bye world!\")"
100+
],
72101
"outputs": [
73102
{
74-
"name": "stdout",
75103
"output_type": "stream",
104+
"name": "stdout",
76105
"text": [
77-
"hello world again!\n"
106+
"bye world!\n"
78107
]
79108
}
80109
],
81-
"source": [
82-
"!sleep 2\n",
83-
"print(\"hello world again!\")"
84-
]
85-
},
86-
{
87-
"cell_type": "code",
88-
"execution_count": 63,
89110
"metadata": {
90111
"execution": {
91112
"iopub.execute_input": "2021-07-18T19:49:36.221581Z",
@@ -95,39 +116,20 @@
95116
"shell.execute_reply.started": "2021-07-18T19:49:36.221557Z"
96117
},
97118
"tags": []
98-
},
99-
"outputs": [
100-
{
101-
"name": "stdout",
102-
"output_type": "stream",
103-
"text": [
104-
"bye world!\n"
105-
]
106-
}
107-
],
108-
"source": [
109-
"!sleep 5\n",
110-
"print(\"bye world!\")"
111-
]
119+
}
112120
},
113121
{
114122
"cell_type": "code",
115123
"execution_count": 40,
116-
"metadata": {
117-
"execution": {
118-
"iopub.execute_input": "2021-07-18T19:41:58.007998Z",
119-
"iopub.status.busy": "2021-07-18T19:41:58.007728Z",
120-
"iopub.status.idle": "2021-07-18T19:42:01.145486Z",
121-
"shell.execute_reply": "2021-07-18T19:42:01.144436Z",
122-
"shell.execute_reply.started": "2021-07-18T19:41:58.007971Z"
123-
},
124-
"tags": []
125-
},
124+
"source": [
125+
"!sleep 3\n",
126+
"raise Exception('hello world!')"
127+
],
126128
"outputs": [
127129
{
130+
"output_type": "error",
128131
"ename": "Exception",
129132
"evalue": "hello world!",
130-
"output_type": "error",
131133
"traceback": [
132134
"\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
133135
"\u001b[0;31mException\u001b[0m Traceback (most recent call last)",
@@ -136,14 +138,44 @@
136138
]
137139
}
138140
],
141+
"metadata": {
142+
"execution": {
143+
"iopub.execute_input": "2021-07-18T19:41:58.007998Z",
144+
"iopub.status.busy": "2021-07-18T19:41:58.007728Z",
145+
"iopub.status.idle": "2021-07-18T19:42:01.145486Z",
146+
"shell.execute_reply": "2021-07-18T19:42:01.144436Z",
147+
"shell.execute_reply.started": "2021-07-18T19:41:58.007971Z"
148+
},
149+
"tags": []
150+
}
151+
},
152+
{
153+
"cell_type": "markdown",
139154
"source": [
140-
"!sleep 3\n",
141-
"raise Exception('hello world!')"
142-
]
155+
"## Last Cell Execution Notification Only\n",
156+
"For this demo, make sure to update `last_cell_only` to true in Settings > Advanced Settings Editor > Notifications.\n",
157+
"Please select the following three cells and run them at the same time.\n",
158+
"\n",
159+
"How to select Multiple Cells Shift + J or Shift + Down selects the next sell in a downwards direction."
160+
],
161+
"metadata": {}
143162
},
144163
{
145164
"cell_type": "code",
146165
"execution_count": 138,
166+
"source": [
167+
"!sleep 4\n",
168+
"print(\"hola!\")"
169+
],
170+
"outputs": [
171+
{
172+
"output_type": "stream",
173+
"name": "stdout",
174+
"text": [
175+
"hola!\n"
176+
]
177+
}
178+
],
147179
"metadata": {
148180
"execution": {
149181
"iopub.execute_input": "2021-07-26T02:15:24.129175Z",
@@ -153,24 +185,24 @@
153185
"shell.execute_reply.started": "2021-07-26T02:15:24.129139Z"
154186
},
155187
"tags": []
156-
},
188+
}
189+
},
190+
{
191+
"cell_type": "code",
192+
"execution_count": 139,
193+
"source": [
194+
"!sleep 2\n",
195+
"print(\"bonjour!\")"
196+
],
157197
"outputs": [
158198
{
159-
"name": "stdout",
160199
"output_type": "stream",
200+
"name": "stdout",
161201
"text": [
162-
"hola!\n"
202+
"bonjour!\n"
163203
]
164204
}
165205
],
166-
"source": [
167-
"!sleep 4\n",
168-
"print(\"hola!\")"
169-
]
170-
},
171-
{
172-
"cell_type": "code",
173-
"execution_count": 139,
174206
"metadata": {
175207
"execution": {
176208
"iopub.execute_input": "2021-07-26T02:15:28.258778Z",
@@ -180,24 +212,24 @@
180212
"shell.execute_reply.started": "2021-07-26T02:15:28.258744Z"
181213
},
182214
"tags": []
183-
},
215+
}
216+
},
217+
{
218+
"cell_type": "code",
219+
"execution_count": 140,
220+
"source": [
221+
"!sleep 3\n",
222+
"print(\"yo!\")"
223+
],
184224
"outputs": [
185225
{
186-
"name": "stdout",
187226
"output_type": "stream",
227+
"name": "stdout",
188228
"text": [
189-
"bonjour!\n"
229+
"yo!\n"
190230
]
191231
}
192232
],
193-
"source": [
194-
"!sleep 2\n",
195-
"print(\"bonjour!\")"
196-
]
197-
},
198-
{
199-
"cell_type": "code",
200-
"execution_count": 140,
201233
"metadata": {
202234
"execution": {
203235
"iopub.execute_input": "2021-07-26T02:15:30.391586Z",
@@ -207,32 +239,22 @@
207239
"shell.execute_reply.started": "2021-07-26T02:15:30.391542Z"
208240
},
209241
"tags": []
210-
},
211-
"outputs": [
212-
{
213-
"name": "stdout",
214-
"output_type": "stream",
215-
"text": [
216-
"yo!\n"
217-
]
218-
}
219-
],
220-
"source": [
221-
"!sleep 3\n",
222-
"print(\"yo!\")"
223-
]
242+
}
224243
},
225244
{
226245
"cell_type": "markdown",
227-
"metadata": {
228-
"tags": []
229-
},
230246
"source": [
231247
"## Hello World"
232-
]
248+
],
249+
"metadata": {
250+
"tags": []
251+
}
233252
},
234253
{
235254
"cell_type": "raw",
255+
"source": [
256+
"Hello World"
257+
],
236258
"metadata": {
237259
"execution": {
238260
"iopub.execute_input": "2021-03-27T02:29:48.597351Z",
@@ -241,17 +263,14 @@
241263
"shell.execute_reply": "2021-03-27T02:29:48.600860Z",
242264
"shell.execute_reply.started": "2021-03-27T02:29:48.597324Z"
243265
}
244-
},
245-
"source": [
246-
"Hello World"
247-
]
266+
}
248267
},
249268
{
250269
"cell_type": "code",
251270
"execution_count": null,
252-
"metadata": {},
271+
"source": [],
253272
"outputs": [],
254-
"source": []
273+
"metadata": {}
255274
}
256275
],
257276
"metadata": {
@@ -275,4 +294,4 @@
275294
},
276295
"nbformat": 4,
277296
"nbformat_minor": 4
278-
}
297+
}

0 commit comments

Comments
 (0)