-
Notifications
You must be signed in to change notification settings - Fork 120
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
update-reducers fix #122
base: master
Are you sure you want to change the base?
update-reducers fix #122
Conversation
…hen reducers are updated
lgtm |
I'm not close enough to the project at this point to understand all of the impact this change may have. This will require a major version bump to be safe, no? @ernestomancebo @bufke |
😴😴😴 |
Any news about when/if this PR will be completed? |
I'm having a tough time producing the bug. Do you have a sample project that demonstrates it? I attempted to reproduce it by logging in to an app. Reload. Manually dispatching (via redux devtools) a login action that would set a new auth token. Then navigating to a lazy loaded route. I see a update action as you mention. I did not see any old state reappear. I see a couple people have interest in this bug. I don't feel comfortable merging without understanding the problem fully. I don't know the historical reason for checking the UPDATE_ACTION either. I did try this patch with some of my apps including some with lazy loading and didn't notice any regressions. The unit test is helpful but it's a very controlled test and I'd like to understand how this bug effects a real project. |
I just tested the one-line fix (removing the check for action.type === UPDATE_ACTION), and it fixes the issue in our application. Anxiously awaiting this to be merged in! It actually uncovered a few other bugs in our application that had a strange dependency on the wrongly-rehydrated state! |
@BillyBlaze no one owes you their time. If you'd like to pay a contractor to support your open source software you are welcome to do so. If you think you can maintain the project better you are welcome to ask to join or fork it. |
I'm hesitant to merge this in as the For those that need this fix, there is a workaround #120 (comment) |
fix issue overwriting values with old values from rehydrated state, when reducers are updated.
Not sure if the test is needed, because update action is deleted.