-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
COMPAT: Add Google BigQuery support for python 3 #11094 #11110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Python 3.5 unit tests are failing, waiting on #11097 |
@parthea yes, 3.5 are ok |
Some gbq unit tests are failing on Python 3.4 I think I need to remove the
|
c1b2390
to
ef949b1
Compare
@parthea gr8. let me know when ready for review. |
whatsnew note as well. |
add a whatsnew entry (in the gbq sub-section that you did before). |
Can I wait for #11121 to be merged? |
49ec34e
to
8602e1d
Compare
ok, rebase this, ping when green. |
@aaront You are welcome to work on this if you have time, but don't feel obligated. I plan to commit a new version tomorrow evening. |
Travis is green |
@@ -353,10 +357,15 @@ def _parse_data(schema, rows): | |||
|
|||
fields = schema['fields'] | |||
col_types = [field['type'] for field in fields] | |||
col_names = [field['name'].encode('ascii', 'ignore') for field in fields] | |||
if compat.PY2: | |||
col_names = [field['name'].encode('ascii', 'ignore') for field in fields] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm, does BigQuery
require ascii column names? e.g. doesn't support say utf-8
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
utf-8
is ok. I think the conversion to ascii was a workaround for an unrelated issue numpy/numpy#2407
For python 3 compatability, we can just use str( )
. I've committed a new version.
can you certify that all tests are passing on py2 and py3? (as we skip the actual tests on travis). |
1f180ee
to
107b21f
Compare
Ready for review. All tests pass locally. Python 2.7 test results
Python 3.4 test results
|
COMPAT: Add Google BigQuery support for python 3 #11094
closes #11094
Adds gbq support for python 3.4