This issue is suggested by Marcel Grossmann on GitHub PR #53.

Signed-off-by: IWASE Yusuke <[email protected]>
---
 ryu/app/wsgi.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/ryu/app/wsgi.py b/ryu/app/wsgi.py
index 3c8bc93..fbfa0e7 100644
--- a/ryu/app/wsgi.py
+++ b/ryu/app/wsgi.py
@@ -17,6 +17,7 @@
 import inspect
 from types import MethodType
 
+import six
 from tinyrpc.server import RPCServer
 from tinyrpc.dispatch import RPCDispatcher
 from tinyrpc.dispatch import public as rpc_public
@@ -139,7 +140,7 @@ class WebSocketServerTransport(ServerTransport):
         return (context, message)
 
     def send_reply(self, context, reply):
-        self.ws.send(unicode(reply))
+        self.ws.send(six.text_type(reply))
 
 
 class WebSocketRPCServer(RPCServer):
@@ -169,7 +170,7 @@ class WebSocketClientTransport(ClientTransport):
         self.queue = queue
 
     def send_message(self, message, expect_reply=True):
-        self.ws.send(unicode(message))
+        self.ws.send(six.text_type(message))
 
         if expect_reply:
             return self.queue.get()
-- 
2.7.4


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to