Uh oh!
There was an error while loading. Please reload this page.
json.loads error with Python 3.4 in gcloud.storage.connection.Connection.api_request - #697
json.loads error with Python 3.4 in gcloud.storage.connection.Connection.api_request#697craigloftus wants to merge 3 commits into
Conversation
…nnection.api_request is decoded to a string before being passed to json.loads
craigloftus
commented
Mar 11, 2015
The tests that have failed because they mock the response and assume a Of course, I could update the PR to change the assumption in the tests, but somehow that feels like the wrong approach? |
tseaver
commented
Mar 11, 2015
Please do update the tests to make the mocked payloads bytes. |
craigloftus
commented
Mar 11, 2015
Darn. I didn't realise github would keep updating the PR - I am having to run the test suite with Travis (on my fork) as I couldn't get Tox to run locally. |
craigloftus
commented
Mar 11, 2015
Going to kill this PR and come back when I have something that works. |
dhermes
commented
Mar 11, 2015
@craigloftus I'm happy to help get |
craigloftus
commented
Mar 11, 2015
@dhermes Thanks. I have travis building against my fork, which has let me get somewhere. After a couple of attempts I changed the mocked This travis build of my fork shows the remaining issue, which is actually the root cause of Issue #653; that the exception handling code is expecting |
dhermes
commented
Mar 11, 2015
@craigloftus Can you send error output from your issues running As for the remaining errors, it looks like you aren't JSON parsing the errors. It can be addressed by changing one line ifisinstance(content, str):to ifisinstance(content, six.string_types):UPDATE: I just realized |
craigloftus
commented
Mar 12, 2015
@dhermes My issue is mainly that I have no idea how to use Yeah. I think I now have a commit (craigloftus@e7ffadc7) which is passing on all python versions. It will probably be tomorrow before I get a chance to figure out how to rebase and squash my changes into a neat PR. |
dhermes
commented
Mar 12, 2015
@craigloftus You can use tox just by running Googling for your [sudo] pip install --upgrade tox virtualenv(The |
Source-Link: googleapis/synthtool@bc07fd4 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:30470597773378105e239b59fce8eb27cc97375580d592699206d17d117143d0 Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Source-Link: googleapis/synthtool@bc07fd4 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:30470597773378105e239b59fce8eb27cc97375580d592699206d17d117143d0 Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
🤖 I have created a release \*beep\* \*boop\* --- ### [0.35.11](https://www.github.com/googleapis/gapic-generator-python/compare/v0.35.10...v0.35.11) (2020-11-12) ### Bug Fixes * add enums to types/__init__.py ([#695](https://www.github.com/googleapis/gapic-generator-python/issues/695)) ([e1d4a4a](https://www.github.com/googleapis/gapic-generator-python/commit/e1d4a4ae768a631f6e6dc28f2acfde8be8dc4a8f)) * update protobuf version [gapic-generator-python] ([#696](https://www.github.com/googleapis/gapic-generator-python/issues/696)) ([ea3e519](https://www.github.com/googleapis/gapic-generator-python/commit/ea3e5198862881f5b142638df6ea604654f81f82)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please).
* fix: add pyopenssl as extra dependency * update
* feat: support commit timestamp option Add support for columns with commit timestamps: https://cloud.google.com/spanner/docs/commit-timestampFixes: #695 * chore: use Singer in sample --------- Co-authored-by: Knut Olav Løite <koloite@gmail.com>
When using Python 3
httplib2returns request content asbytesbutjson.loadsrequiresstr.It might be desirable to examine the content-type header returned by
httplib2to decided which encoding to use, although it is likely to always beutf-8?