Skip to content
This repository has been archived by the owner on Jan 12, 2022. It is now read-only.

fix: avoid trying to cancel already cancelled stream #329

Merged
merged 2 commits into from
Oct 8, 2021

Conversation

Alex-Werner
Copy link
Contributor

@Alex-Werner Alex-Werner commented Oct 7, 2021

Issue being fixed or feature implemented

This PR fixes an issue with TransactionStreamWorker when trying to close an already closed stream which would then throw a
Uncaught TypeError: Cannot read properties of null (reading ‘cancel’)

What was done?

  • fix: avoid trying to cancel an already cancelled stream

How Has This Been Tested?

  • Using test-suite (display RUN)

Breaking Changes

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated relevant unit/integration/functional/e2e tests
  • I have made corresponding changes to the documentation

For repository code-owners and collaborators only

  • I have assigned this pull request to a milestone

@Alex-Werner Alex-Werner marked this pull request as ready for review October 7, 2021 18:21
@Alex-Werner Alex-Werner added this to the v0.21.0 milestone Oct 7, 2021
@Alex-Werner Alex-Werner force-pushed the fix/abort-cancelling-cancelled-stream branch from ed5b65e to 069718c Compare October 7, 2021 18:24
Copy link
Member

@shumkov shumkov left a comment

Choose a reason for hiding this comment

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

LGTM! 👍

@Alex-Werner Alex-Werner merged commit 8acd608 into v0.21-dev Oct 8, 2021
shuplenkov pushed a commit that referenced this pull request Oct 25, 2021
* fix: avoid trying to cancel already cancelled stream

* refactor: remove unnecessary `cancel` method check

Co-authored-by: Ivan Shumkov <ivan@shumkov.ru>
@shumkov shumkov deleted the fix/abort-cancelling-cancelled-stream branch October 26, 2021 11:37
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants