You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by gs...@apache.org on 2015/08/19 20:57:20 UTC
[2/2] qpid-proton git commit: NO-JIRA: ensure message content is
based on strings rather than binary values, even for python 2.x
NO-JIRA: ensure message content is based on strings rather than binary values, even for python 2.x
Project: http://git-wip-us.apache.org/repos/asf/qpid-proton/repo
Commit: http://git-wip-us.apache.org/repos/asf/qpid-proton/commit/4e878602
Tree: http://git-wip-us.apache.org/repos/asf/qpid-proton/tree/4e878602
Diff: http://git-wip-us.apache.org/repos/asf/qpid-proton/diff/4e878602
Branch: refs/heads/master
Commit: 4e878602da4f0059ea21361559523da1694d80d7
Parents: 14956b0
Author: Gordon Sim <gs...@redhat.com>
Authored: Wed Aug 19 19:58:57 2015 +0100
Committer: Gordon Sim <gs...@redhat.com>
Committed: Wed Aug 19 19:58:57 2015 +0100
----------------------------------------------------------------------
examples/python/client.py | 2 +-
examples/python/db_send.py | 2 +-
examples/python/direct_send.py | 2 +-
examples/python/helloworld.py | 2 +-
examples/python/helloworld_direct.py | 2 +-
examples/python/simple_send.py | 2 +-
examples/python/test_examples.py | 6 +++---
examples/python/tx_send.py | 2 +-
8 files changed, 10 insertions(+), 10 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/4e878602/examples/python/client.py
----------------------------------------------------------------------
diff --git a/examples/python/client.py b/examples/python/client.py
index 18dc81a..86f2c76 100755
--- a/examples/python/client.py
+++ b/examples/python/client.py
@@ -18,7 +18,7 @@
# under the License.
#
-from __future__ import print_function
+from __future__ import print_function, unicode_literals
import optparse
from proton import Message
from proton.handlers import MessagingHandler
http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/4e878602/examples/python/db_send.py
----------------------------------------------------------------------
diff --git a/examples/python/db_send.py b/examples/python/db_send.py
index dc85df9..c07dcc0 100755
--- a/examples/python/db_send.py
+++ b/examples/python/db_send.py
@@ -18,7 +18,7 @@
# under the License.
#
-from __future__ import print_function
+from __future__ import print_function, unicode_literals
import optparse
import time
try:
http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/4e878602/examples/python/direct_send.py
----------------------------------------------------------------------
diff --git a/examples/python/direct_send.py b/examples/python/direct_send.py
index f551e1e..35bd2f5 100755
--- a/examples/python/direct_send.py
+++ b/examples/python/direct_send.py
@@ -18,7 +18,7 @@
# under the License.
#
-from __future__ import print_function
+from __future__ import print_function, unicode_literals
import optparse
from proton import Message
from proton.handlers import MessagingHandler
http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/4e878602/examples/python/helloworld.py
----------------------------------------------------------------------
diff --git a/examples/python/helloworld.py b/examples/python/helloworld.py
index 9fcd6f1..7a91aa4 100755
--- a/examples/python/helloworld.py
+++ b/examples/python/helloworld.py
@@ -18,7 +18,7 @@
# under the License.
#
-from __future__ import print_function
+from __future__ import print_function, unicode_literals
from proton import Message
from proton.handlers import MessagingHandler
from proton.reactor import Container
http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/4e878602/examples/python/helloworld_direct.py
----------------------------------------------------------------------
diff --git a/examples/python/helloworld_direct.py b/examples/python/helloworld_direct.py
index 264e5b8..0292abe 100755
--- a/examples/python/helloworld_direct.py
+++ b/examples/python/helloworld_direct.py
@@ -18,7 +18,7 @@
# under the License.
#
-from __future__ import print_function
+from __future__ import print_function, unicode_literals
from proton import Message
from proton.handlers import MessagingHandler
from proton.reactor import Container
http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/4e878602/examples/python/simple_send.py
----------------------------------------------------------------------
diff --git a/examples/python/simple_send.py b/examples/python/simple_send.py
index 75ab550..7717a16 100755
--- a/examples/python/simple_send.py
+++ b/examples/python/simple_send.py
@@ -18,7 +18,7 @@
# under the License.
#
-from __future__ import print_function
+from __future__ import print_function, unicode_literals
import optparse
from proton import Message
from proton.handlers import MessagingHandler
http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/4e878602/examples/python/test_examples.py
----------------------------------------------------------------------
diff --git a/examples/python/test_examples.py b/examples/python/test_examples.py
index 7f87616..3d97b97 100644
--- a/examples/python/test_examples.py
+++ b/examples/python/test_examples.py
@@ -56,7 +56,7 @@ class ExamplesTest(unittest.TestCase):
s.wait()
r.wait()
actual = [l.strip() for l in r.stdout]
- expected = ["{'sequence': %i}" % (i+1) for i in range(100)]
+ expected = ["{%s'sequence': %i}" % (_unicode_prefix, (i+1)) for i in range(100)]
self.assertEqual(actual, expected)
def test_client_server(self, client=['client.py'], server=['server.py'], sleep=0):
@@ -135,7 +135,7 @@ class ExamplesTest(unittest.TestCase):
s.wait()
r.wait()
actual = [l.strip() for l in r.stdout]
- expected = ["{'sequence': %i}" % (i+1) for i in range(100)]
+ expected = ["{%s'sequence': %i}" % (_unicode_prefix, (i+1)) for i in range(100)]
self.assertEqual(actual, expected)
def test_direct_send_simple_recv(self):
@@ -147,5 +147,5 @@ class ExamplesTest(unittest.TestCase):
r.wait()
s.wait()
actual = [l.strip() for l in r.stdout]
- expected = ["{'sequence': %i}" % (i+1) for i in range(100)]
+ expected = ["{%s'sequence': %i}" % (_unicode_prefix, (i+1)) for i in range(100)]
self.assertEqual(actual, expected)
http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/4e878602/examples/python/tx_send.py
----------------------------------------------------------------------
diff --git a/examples/python/tx_send.py b/examples/python/tx_send.py
index 5e30174..bda6780 100755
--- a/examples/python/tx_send.py
+++ b/examples/python/tx_send.py
@@ -18,7 +18,7 @@
# under the License.
#
-from __future__ import print_function
+from __future__ import print_function, unicode_literals
import optparse
from proton import Message, Url
from proton.reactor import Container
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org