Skip to content

Commit 3140085

Browse files
authored
Merge pull request jupyter#2549 from mscuthbert/nbval-exception-passing
allow raises-exception to continue
2 parents 9f578dc + 4cfa7f6 commit 3140085

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

notebook/static/notebook/js/codecell.js

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,16 @@ define([
310310
}
311311

312312
if (stop_on_error === undefined) {
313-
stop_on_error = true;
313+
if (this.metadata !== undefined &&
314+
this.metadata.tags !== undefined) {
315+
if (this.metadata.tags.indexOf('raises-exception') !== -1) {
316+
stop_on_error = false;
317+
} else {
318+
stop_on_error = true;
319+
}
320+
} else {
321+
stop_on_error = true;
322+
}
314323
}
315324

316325
this.clear_output(false, true);

0 commit comments

Comments
 (0)