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

Actions from actionQueue are sometimes dispatched multiple times #344

Closed
juspeeh opened this issue Dec 28, 2021 · 4 comments
Closed

Actions from actionQueue are sometimes dispatched multiple times #344

juspeeh opened this issue Dec 28, 2021 · 4 comments
Labels

Comments

@juspeeh
Copy link

juspeeh commented Dec 28, 2021

Current Behavior

  • What code are you running and what is happening?

Actions from actionQueue are sometimes dispatched multiple times

Expected Behavior

  • What do you expect should be happening?

Every action from actionQueue should be dispatched only once

How to reproduce

When "@@network-connectivity/CONNECTION_CHANGE" action queue to be flushed is created. If action inside that queue dispatches "@@network-connectivity/CHANGE_QUEUE_SEMAPHORE", payload "GREEN"( as the readME recommends if you want to wait an action to complete before the next action). Due to the action being intercepted by the library a secondary queue will be created and those both are ran simultaneously. Nothing is done to check if certain action is already removed from the actual state or queue is already being flushed. This causes X amount of actions to be dispatched multiple times depending on the queue size.

@stale
Copy link

stale bot commented Mar 2, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Mar 2, 2022
@superyarik
Copy link

superyarik commented Apr 8, 2022

facing same issue

queueReleaseThrottle was 2000, looks like using default 50 is solve problem, but there is still principal problem with waiting this throttle time in middleware.

@stale stale bot removed the wontfix label Apr 8, 2022
@stale
Copy link

stale bot commented Jun 13, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Jun 13, 2022
@stale
Copy link

stale bot commented Aug 13, 2022

Closing this issue after a prolonged period of inactivity. If this is still present in the latest release, please feel free to create a new issue with up-to-date information.

@stale stale bot closed this as completed Aug 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants