##// END OF EJS Templates
Don't use io.rprint in jupyter_client.session...
Min RK -
Show More
@@ -49,7 +49,6 b' from zmq.eventloop.zmqstream import ZMQStream'
49 49
50 50 from IPython.core.release import kernel_protocol_version
51 51 from IPython.config.configurable import Configurable, LoggingConfigurable
52 from IPython.utils import io
53 52 from IPython.utils.importstring import import_item
54 53 from jupyter_client.jsonutil import extract_dates, squash_dates, date_default
55 54 from IPython.utils.py3compat import (str_to_bytes, str_to_unicode, unicode_type,
@@ -59,6 +58,8 b' from IPython.utils.traitlets import (CBytes, Unicode, Bool, Any, Instance, Set,'
59 58 TraitError,
60 59 )
61 60 from jupyter_client.adapter import adapt
61 from traitlets.log import get_logger
62
62 63
63 64 #-----------------------------------------------------------------------------
64 65 # utility functions
@@ -653,8 +654,9 b' class Session(Configurable):'
653 654 msg = self.msg(msg_or_type, content=content, parent=parent,
654 655 header=header, metadata=metadata)
655 656 if not os.getpid() == self.pid:
656 io.rprint("WARNING: attempted to send message from fork")
657 io.rprint(msg)
657 get_logger().warn("WARNING: attempted to send message from fork\n%s",
658 msg
659 )
658 660 return
659 661 buffers = [] if buffers is None else buffers
660 662 if self.adapt_version:
General Comments 0
You need to be logged in to leave comments. Login now