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

change to next method as synchronously #526

Merged
merged 2 commits into from
Jun 7, 2023

Conversation

easylogic
Copy link
Contributor

@easylogic easylogic commented Jun 5, 2023

What this PR does / why we need it?

Replace all of the eventStreamObserver.next() functions with synchronous forms.

  • Prevents incorrect data updates when eventers run asynchronously.
  • Clarify when async events are fired when using them.

Any background context you want to provide?

What are the relevant tickets?

Fixes #525

Checklist

  • Added relevant tests or not required
  • Didn't break anything

@easylogic easylogic requested review from hackerwins and chacha912 and removed request for hackerwins June 5, 2023 05:33
@codecov
Copy link

codecov bot commented Jun 5, 2023

Codecov Report

Merging #526 (ae66828) into main (5f508e1) will decrease coverage by 2.05%.
The diff coverage is 50.00%.

@@            Coverage Diff             @@
##             main     #526      +/-   ##
==========================================
- Coverage   90.21%   88.17%   -2.05%     
==========================================
  Files          70       77       +7     
  Lines        6153     7397    +1244     
  Branches      578      714     +136     
==========================================
+ Hits         5551     6522     +971     
- Misses        387      603     +216     
- Partials      215      272      +57     
Impacted Files Coverage Δ
src/util/observable.ts 36.36% <41.66%> (-7.06%) ⬇️
src/document/document.ts 73.41% <100.00%> (+1.26%) ⬆️

... and 25 files with indirect coverage changes

Copy link
Contributor

@chacha912 chacha912 left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution. It looks good :)

@hackerwins hackerwins self-requested a review June 7, 2023 02:21
Copy link
Member

@hackerwins hackerwins left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution.

@hackerwins hackerwins merged commit d38c853 into main Jun 7, 2023
2 checks passed
@hackerwins hackerwins deleted the modify/next-as-synchronously branch June 7, 2023 02:29
hunkim98 pushed a commit to hunkim98/yorkie-js-sdk that referenced this pull request Jul 12, 2023
Co-authored-by: Youngteac Hong <susukang98@gmail.com>
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.

Change to entire event system as synchronous
3 participants