FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

fix: add reason field to Details in GoogleJsonErrorObject by Neenu1995 · Pull Request #1831 · googleapis/google-api-java-client · GitHub

fix: add reason field to Details in GoogleJsonErrorObject - #1831

Merged
gcf-merge-on-green[bot] merged 3 commits into
masterfrom
fix-error-details
Jun 22, 2021
Merged

fix: add reason field to Details in GoogleJsonErrorObject#1831
gcf-merge-on-green[bot] merged 3 commits into
masterfrom
fix-error-details

Conversation

Neenu1995 commented Jun 18, 2021
edited
Loading

Copy link
Copy Markdown
Contributor

Fixes b/191502543

google-api-java-client id parsing error objects without reason field in details.
The actual error message:

{
  "error": {
    "code": 400,
    "message": "The subscription is in a state that is not valid for the requested operation",
    "status": "FAILED_PRECONDITION",
    "details": [
      {
        "@type": "type.googleapis.com/google.rpc.ErrorInfo",
        "reason": "ERROR_CODE_SUBSCRIPTION_BAD_STATE"
      }
    ]
  }
}

But when it get parsed through java api-client, it becomes:

{
  "code" : 400,
  "details" : [ {
    "@type" : "type.googleapis.com/google.rpc.ErrorInfo"
  } ],
  "message" : "The subscription is in a state that is not valid for the requested operation",
  "status" : "FAILED_PRECONDITION"
}

Neenu1995 requested a review from a team June 18, 2021 20:55
google-cla Bot added the cla: yes This human has signed the Contributor License Agreement. label Jun 18, 2021
Comment thread google-api-client-bom/pom.xml Outdated
Comment thread google-api-client/pom.xml Outdated
}

public void setReason(String reason) {
this.reason = reason;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

this is supposed to be nullable?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

yes.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Yes

Comment thread pom.xml Outdated
Neenu1995 requested a review from elharo June 22, 2021 16:52
Neenu1995 added the automerge Merge the pull request once unit tests and other checks pass. label Jun 22, 2021
gcf-merge-on-green Bot merged commit 5e92b4c into master Jun 22, 2021
gcf-merge-on-green Bot deleted the fix-error-details branch June 22, 2021 18:08
gcf-merge-on-green Bot removed the automerge Merge the pull request once unit tests and other checks pass. label Jun 22, 2021
gcf-merge-on-green Bot pushed a commit that referenced this pull request Jun 24, 2021
🤖 I have created a release \*beep\* \*boop\*
---
### [1.32.1](https://www.github.com/googleapis/google-api-java-client/compare/v1.32.0...v1.32.1) (2021-06-24)


### Features

* add `gcf-owl-bot[bot]` to `ignoreAuthors` ([#1813](https://www.github.com/googleapis/google-api-java-client/issues/1813)) ([56f5b8b](https://www.github.com/googleapis/google-api-java-client/commit/56f5b8be0a60cb1cf0b279743d85ef57d9aa46b6))


### Bug Fixes

* bring comment up to date with code ([#1838](https://www.github.com/googleapis/google-api-java-client/issues/1838)) ([f150c5a](https://www.github.com/googleapis/google-api-java-client/commit/f150c5aa6e2de0c6cbad7461f4b76be8e0027567))
* Update dependencies.sh to not break on mac ([#1830](https://www.github.com/googleapis/google-api-java-client/issues/1830)) ([97940b3](https://www.github.com/googleapis/google-api-java-client/commit/97940b3fd96e343df3985630398811f3c417afcc)) 
* add reason field to Details in GoogleJsonErrorObject ([#1831](https://www.github.com/googleapis/google-api-java-client/issues/1831)) ([5e92b4c](https://www.github.com/googleapis/google-api-java-client/commit/5e92b4c22e0d45686a58de58977d20c96593e901))



### Dependencies

* don't use sp versions in the regular release ([#1840](https://www.github.com/googleapis/google-api-java-client/issues/1840)) ([94cde71](https://www.github.com/googleapis/google-api-java-client/commit/94cde719e9ad845bcd186595e06279e2b7c19096))
---


This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL