[ https://issues.apache.org/jira/browse/TOREE-380?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16049579#comment-16049579 ]
ASF GitHub Bot commented on TOREE-380: -------------------------------------- Github user rdblue commented on a diff in the pull request: https://github.com/apache/incubator-toree/pull/104#discussion_r122046211 --- Diff: kernel-api/src/main/scala/org/apache/toree/interpreter/broker/BrokerTransformer.scala --- @@ -43,7 +43,7 @@ class BrokerTransformer { import scala.concurrent.ExecutionContext.Implicits.global futureResult - .map(results => (Results.Success, Left(results))) + .map(results => (Results.Success, Left(Map("text/plain" -> results)))) --- End diff -- No, kernel-api doesn't depend on protocol so it isn't available. But I think that this code shouldn't be sending mime types in the first place. Sending text/plain here happens because we haven't updated the Python kernel to correctly inspect its objects. Eventually, the python interpreter should send back a result that is a py4j reference to the final value and the python representation (from _repr_ and _repr_html_) or a JVM object and None to indicate that the Jupyter JVM displayer should be called. So for now, I'd rather not change module dependencies. > Interpreters should be allowed to send results other than text/plain. > --------------------------------------------------------------------- > > Key: TOREE-380 > URL: https://issues.apache.org/jira/browse/TOREE-380 > Project: TOREE > Issue Type: Improvement > Reporter: Ryan Blue > Assignee: Ryan Blue > > Jupyter allows kernels to send results using different content types, but > this isn't allowed by Toree for its interpreters. This prevents custom > display logic. The basic problem is that {{ExecuteOutput}} is a {{String}} > and not a {{Map[String, String]}} like {{CellMagicOutput}}. -- This message was sent by Atlassian JIRA (v6.4.14#64029)