You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beam.apache.org by bh...@apache.org on 2020/06/17 22:04:53 UTC

[beam] branch beam-10273-1 created (now 89aa454)

This is an automated email from the ASF dual-hosted git repository.

bhulette pushed a change to branch beam-10273-1
in repository https://gitbox.apache.org/repos/asf/beam.git.


      at 89aa454  str -> unicode to fix python 2 failure

This branch includes the following new commits:

     new 89aa454  str -> unicode to fix python 2 failure

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[beam] 01/01: str -> unicode to fix python 2 failure

Posted by bh...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

bhulette pushed a commit to branch beam-10273-1
in repository https://gitbox.apache.org/repos/asf/beam.git

commit 89aa454469155e1a47c9411b605d539d36da64a1
Author: Brian Hulette <bh...@google.com>
AuthorDate: Wed Jun 17 15:04:24 2020 -0700

    str -> unicode to fix python 2 failure
---
 sdks/python/apache_beam/transforms/sql_test.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sdks/python/apache_beam/transforms/sql_test.py b/sdks/python/apache_beam/transforms/sql_test.py
index 8c9e1d5..8c2dae3 100644
--- a/sdks/python/apache_beam/transforms/sql_test.py
+++ b/sdks/python/apache_beam/transforms/sql_test.py
@@ -143,7 +143,7 @@ class SqlTransformTest(unittest.TestCase):
       out = (
           p
           | beam.Create([1, 2, 10])
-          | beam.Map(lambda x: beam.Row(a=x, b=str(x)))
+          | beam.Map(lambda x: beam.Row(a=x, b=unicode(x)))
           | SqlTransform("SELECT a*a as s, LENGTH(b) AS c FROM PCOLLECTION"))
       assert_that(out, equal_to([(1, 1), (4, 1), (100, 2)]))