Skip to content

Use status_pb2.Status to parse error messages from Datastore - #1618

Merged
dhermes merged 1 commit into
googleapis:datastore-v1beta3from
pcostell:datastore-v1beta3
Mar 18, 2016
Merged

Use status_pb2.Status to parse error messages from Datastore#1618
dhermes merged 1 commit into
googleapis:datastore-v1beta3from
pcostell:datastore-v1beta3

Conversation

@pcostell

Copy link
Copy Markdown
Contributor

Addresses #1617

Note that status has other information too that likely should get exposed. This is just an example of what the expected response is.

@googlebotgooglebot added the cla: yes This human has signed the Contributor License Agreement. label Mar 15, 2016
@dhermes

Copy link
Copy Markdown
Contributor

@pcostell Why not merge? Other than adding status_pb2 unnecessarily (since it is in googleapis-common-protos) this looks fine.

@pcostellpcostell changed the title DONOTSUBMIT: Example using StatusUse status_pb2.Status to parse error messages from DatastoreMar 16, 2016
@pcostell

Copy link
Copy Markdown
ContributorAuthor

@dhermes - Sure I can submit it (I wasn't sure if we wanted to do more with the error than just grab the message, but I added a todo).

PTAL.

@tseaver

Copy link
Copy Markdown
Contributor

The pylint failure looks like it should be addressed by merging the change from #1583 into the datastore-v1beta3 branch.

Comment threadgcloud/datastore/connection.py Outdated
if status != '200':
raise make_exception(headers, content, use_json=False)
# TODO(pcostell): There is more information in the error besides
# the message that should be passed on.

This comment was marked as spam.

@dhermes

Copy link
Copy Markdown
Contributor

@pcostell Too much to ask to squash the 4 commits down to 1?

@pcostell

Copy link
Copy Markdown
ContributorAuthor

No more TODO and squashed.

@dhermes

Copy link
Copy Markdown
Contributor

Great. In order to pass the lint environment, the easiest way will be to update scripts/pylintrc_default as in #1583:

 # DEFAULT: ignored-modules=
+# RATIONALE: six aliases stuff for compatibility.+# google.protobuf fixes up namespace package "late".+ignored-modules = six, google.protobuf

@dhermes

Copy link
Copy Markdown
Contributor

@pcostell, rebase now and we can get this merged?

@googlebot

Copy link
Copy Markdown

We found a Contributor License Agreement for you (the sender of this pull request) and all commit authors, but as best as we can tell these commits were authored by someone else. If that's the case, please add them to this pull request and have them confirm that they're okay with these commits being contributed to Google. If we're mistaken and you did author these commits, just reply here to confirm.

@googlebotgooglebot added cla: no This human has *not* signed the Contributor License Agreement. and removed cla: yes This human has signed the Contributor License Agreement. labels Mar 18, 2016
@googlebot

Copy link
Copy Markdown

CLAs look good, thanks!

@googlebotgooglebot added cla: yes This human has signed the Contributor License Agreement. and removed cla: no This human has *not* signed the Contributor License Agreement. labels Mar 18, 2016
@pcostell

Copy link
Copy Markdown
ContributorAuthor

Rebased and ready for merge.

@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 100.0% when pulling 3b44173 on pcostell:datastore-v1beta3 into f9e4efc on GoogleCloudPlatform:datastore-v1beta3.

@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 100.0% when pulling 3b44173 on pcostell:datastore-v1beta3 into f9e4efc on GoogleCloudPlatform:datastore-v1beta3.

dhermes added a commit that referenced this pull request Mar 18, 2016
Use status_pb2.Status to parse error messages from Datastore
@dhermes
dhermes merged commit 50824dd into googleapis:datastore-v1beta3Mar 18, 2016
parthea pushed a commit that referenced this pull request Nov 24, 2025
* fix: ignore_unknown_fields parsing service config
* oops capital True
* reformat args
Co-authored-by: Alexander Fenster <fenster@google.com>
---------
Co-authored-by: Alexander Fenster <fenster@google.com>
parthea added a commit that referenced this pull request Nov 26, 2025
* chore: update templated files
* 🦉 Updates from OwlBot post-processor
See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md
---------
Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
parthea pushed a commit that referenced this pull request Mar 6, 2026
Source-Link: googleapis/synthtool@eaef28e
Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:f8ca7655fa8a449cadcabcbce4054f593dcbae7aeeab34aa3fcc8b5cf7a93c9e
Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
parthea pushed a commit that referenced this pull request Mar 9, 2026
feat(zb-experimental): implement open in writer
---------
Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
parthea pushed a commit that referenced this pull request Apr 1, 2026
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla: yesThis human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants

@pcostell@dhermes@tseaver@googlebot@coveralls