##// END OF EJS Templates
msgspec: stream.data -> stream.text
MinRK -
Show More
@@ -57,7 +57,7 b' class APITest(NotebookTestBase):'
57
57
58 nb.cells.append(new_heading_cell(u'Created by test ³'))
58 nb.cells.append(new_heading_cell(u'Created by test ³'))
59 cc1 = new_code_cell(source=u'print(2*6)')
59 cc1 = new_code_cell(source=u'print(2*6)')
60 cc1.outputs.append(new_output(output_type="stream", data=u'12'))
60 cc1.outputs.append(new_output(output_type="stream", text=u'12'))
61 cc1.outputs.append(new_output(output_type="execute_result",
61 cc1.outputs.append(new_output(output_type="execute_result",
62 mime_bundle={'image/png' : png_green_pixel},
62 mime_bundle={'image/png' : png_green_pixel},
63 execution_count=1,
63 execution_count=1,
@@ -453,7 +453,7 b' define(['
453
453
454
454
455 OutputArea.prototype.append_stream = function (json) {
455 OutputArea.prototype.append_stream = function (json) {
456 var text = json.data;
456 var text = json.text;
457 var subclass = "output_"+json.name;
457 var subclass = "output_"+json.name;
458 if (this.outputs.length > 0){
458 if (this.outputs.length > 0){
459 // have at least one output to consider
459 // have at least one output to consider
@@ -462,9 +462,9 b' define(['
462 // latest output was in the same stream,
462 // latest output was in the same stream,
463 // so append directly into its pre tag
463 // so append directly into its pre tag
464 // escape ANSI & HTML specials:
464 // escape ANSI & HTML specials:
465 last.data = utils.fixCarriageReturn(last.data + json.data);
465 last.text = utils.fixCarriageReturn(last.text + json.text);
466 var pre = this.element.find('div.'+subclass).last().find('pre');
466 var pre = this.element.find('div.'+subclass).last().find('pre');
467 var html = utils.fixConsole(last.data);
467 var html = utils.fixConsole(last.text);
468 // The only user content injected with this HTML call is
468 // The only user content injected with this HTML call is
469 // escaped by the fixConsole() method.
469 // escaped by the fixConsole() method.
470 pre.html(html);
470 pre.html(html);
@@ -80,7 +80,7 b' def output_from_msg(msg):'
80 elif msg_type == 'stream':
80 elif msg_type == 'stream':
81 return new_output(output_type=msg_type,
81 return new_output(output_type=msg_type,
82 name=content['name'],
82 name=content['name'],
83 data=content['data'],
83 text=content['text'],
84 )
84 )
85 elif msg_type == 'display_data':
85 elif msg_type == 'display_data':
86 return new_output(output_type=msg_type,
86 return new_output(output_type=msg_type,
General Comments 0
You need to be logged in to leave comments. Login now