80% of the time, my app works fine. However, sometimes when I need to redeploy or npm run start
again, something breaks and I receive these errors when opening up the app:
GET http://localhost:8097/ net::ERR_CONNECTION_REFUSED
react-redux.min.js:9 Uncaught TypeError: Cannot read property 'unstable_batchedUpdates' of undefined at react-redux.min.js:9
Io {message: "There was an error during the transport or process…this request. Error code = 10, Path = /wardeninit", name: "TransportError", stack: "TransportError: There was an error during the tran…/js/2633236535-warden_bin_i18n_warden.js:195:263)"}
The function to open the modal runs successfully, but then these errors occur and only a blank modal page is shown.
The strange thing is that usually some combination of re-deploying, emptying the cache, signing out of my Google account and back in, will fix this issue. However, not all of these work as the solution 100% of the time. It's so weird. Sometimes I try all of them and nothing has worked, but when I try again later it does work. Then the next time I re-deploy the issue comes up again.
I'm so curious what this issue might be related to.
I am using redux, and the 2nd error points to an error with redux. However, I think it's more likely that somehow the app is just not loading correctly when I run the deploy script and that is what is causing the redux error. When I look at the code in the script editor, it looks normal.
I'll also add that this error doesn't happen EVERY time I re-deploy. Sometimes I can go from local development, deploy, and then the error will happen when I run npm start
. Then sometimes I'm stuck with this error in the deployed version and when I run npm run start
it will actually fix the issue. It's SO WEIRD.
Has anyone else encountered anything like this? Not expecting anyone to know the answer but if you have any ideas on anything I should test or investigate please let me know. I don't even know where to start.