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

move error_accumulator into internal pkg (#304) #335

Conversation

vvatanabe
Copy link
Collaborator

@vvatanabe vvatanabe commented May 31, 2023

Moving error_accumulator to the internal package causes circular import. To avoid this, the following commit removes the ErrorResponse dependency from error_accumulator.
2c9d003

Next, the following commit moved error_accumulator to the internal package.
15653fd

And add a test for ErrTooManyEmptyStreamMessages in stream_reader. (Just increased test coverage.)
444c808

@codecov
Copy link

codecov bot commented May 31, 2023

Codecov Report

Merging #335 (444c808) into master (61ba5f3) will increase coverage by 0.51%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #335      +/-   ##
==========================================
+ Coverage   92.45%   92.97%   +0.51%     
==========================================
  Files          18       17       -1     
  Lines         636      626      -10     
==========================================
- Hits          588      582       -6     
+ Misses         35       32       -3     
+ Partials       13       12       -1     
Impacted Files Coverage Δ
chat_stream.go 89.28% <100.00%> (ø)
stream.go 90.62% <100.00%> (ø)
stream_reader.go 100.00% <100.00%> (+10.81%) ⬆️

@vvatanabe vvatanabe marked this pull request as draft May 31, 2023 21:46
@vvatanabe vvatanabe changed the title [WIP] move error_accumulator into internal pkg (#304) move error_accumulator into internal pkg (#304) Jun 1, 2023
@vvatanabe vvatanabe marked this pull request as ready for review June 1, 2023 00:55
@vvatanabe
Copy link
Collaborator Author

@sashabaranov I moved error_accumulator into internal pkg. Please check this PR.

}

respErr = stream.unmarshalError()
if respErr != nil {
Copy link
Owner

Choose a reason for hiding this comment

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

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@sashabaranov I see! I'll send you a PR to refactor the test in the near future.

Copy link
Owner

@sashabaranov sashabaranov left a comment

Choose a reason for hiding this comment

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

Great PR, thank you so much!

@sashabaranov sashabaranov merged commit 1394329 into sashabaranov:master Jun 5, 2023
@vvatanabe vvatanabe deleted the move-error_accumulator-into-internal-pkg-304 branch June 5, 2023 21:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants