Skip to content
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

fix(microservice): grpc-client serialize error #10110

Merged

Conversation

gilre
Copy link
Contributor

@gilre gilre commented Aug 13, 2022

closes #10104

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Other... Please describe:

What is the current behavior?

Issue Number: #10104

What is the new behavior?

this.serializeError(error) is called before returning an error in client-grpc.ts,
this matches the behavior to the the rest of ClientProxy implementations

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

I didn't find any test cases for error handling, please refer me to any if i missed it.
Added a basic test to make sure old behavior is not affected when serializeError is not overridden

@coveralls
Copy link

Pull Request Test Coverage Report for Build 110f631b-896a-4508-b96c-91951c043909

  • 1 of 3 (33.33%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 93.826%

Changes Missing Coverage Covered Lines Changed/Added Lines %
packages/microservices/client/client-grpc.ts 1 3 33.33%
Totals Coverage Status
Change from base Build 7429007a-3efb-492d-a2a1-84f706a41b5f: 0.0%
Covered Lines: 6094
Relevant Lines: 6495

💛 - Coveralls

@kamilmysliwiec
Copy link
Member

LGTM

@kamilmysliwiec kamilmysliwiec merged commit c84ea3e into nestjs:master Aug 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ClientGrpcProxy - serializeError is not called before returning error
3 participants