Open josecarlosns opened 5 years ago
Have you found a solution for this, I'm experiencing the same problems?
@gusoskar I just stopped using remote-redux-devtools
altogether, I couldn't even setup the chrome extension properly! What I wanted was to use these tools to watch redux actions/reducers while setting up JS breakpoints on vscode for remote debugging a React-Native app I'm building. But this is just too much of a hassle to setup, and even so I found so many issues (this one wasn't the only one BY FAR) and spent so many hours trying that I just eventually gave up.
But I was able to setup react-native-debugger
and with it everything worked, EXCEPT setting up vscode breakpoints. So my choices where:
react-native-debugger
alone for debugging redux and JS code.Or...
I chose the latter.
I got a similar but different error: Socket closed without status code
Would appreciate any insights here
If you're having this issue with an expo app, make sure "packagerPort": 19001 is on the same port with "devToolsPort": 19001 on your packager-info.json in .expo folder.
@wemmyo , Thank you! this fixed the socket issue. The redux remote dev tools still won't populate with data, however :/
Edit: never mind, it didn't work. The ports keep getting overwritten each time I run expo start
@rgomezp You might need to change the ports to match each other after running expo start
, save changes then open devtools. Also if you're using remote-redux-devtools
I'd suggest you use redux-devtools-extension
with react-native-debugger
instead. https://github.com/zalmoxisus/redux-devtools-extension , https://github.com/jhen0409/react-native-debugger
Hi!
It's 2023 and the problem is still present. I use React Native with Hermes but without Flipper because of incompatibility with some Firebase libraries.
So, I start yarn redux-devtools --hostname=localhost --port=8000 --open
, start the Metro server and I've configured the store (with RTK Query) like so:
import devToolsEnhancer from 'remote-redux-devtools';
[...]
const store = configureStore({
reducer: persistedReducer,
middleware: getDefaultMiddleware =>
getDefaultMiddleware({
serializableCheck: {
ignoredActions: [FLUSH, REHYDRATE, PAUSE, PERSIST, PURGE, REGISTER],
},
}).concat(...middlewares),
devTools: false,
enhancers: [devToolsEnhancer({realtime: true, port: 8000})],
});
All it works but every 20 seconds I got from Metro: [SocketProtocolError: Client pong timed out]
Any suggestion?
Hello @aminta Have You Managed to fix this Error ? I am getting the same error everyting is working but after 20 seconds getting Client pong timed out
I've just faced with the same issue. It's working for only a few seconds.
instead of
import devToolsEnhancer from 'remote-redux-devtools';
install @redux-devtools/remote
and use
import { devToolsEnhancer } from '@redux-devtools/remote';
@bastiankistner tried this but it does not work for me , still seeing the same error :(
The stack trace i am getting is
"SocketProtocolError: Server ping timed out\n at SCClientSocket._onSCClose (http://localhost:8081/src/main.tsx.bundle//&platform=android&dev=true&minify=false&app=com.vfmobileapp&modulesOnly=false&runModule=true:570843:17)\n at SCTransport.<anonymous> (http://localhost:8081/src/main.tsx.bundle//&platform=android&dev=true&minify=false&app=com.vfmobileapp&modulesOnly=false&runModule=true:570556:14)\n at Emitter.emit (http://localhost:8081/src/main.tsx.bundle//&platform=android&dev=true&minify=false&app=com.vfmobileapp&modulesOnly=false&runModule=true:571290:22)\n at SCTransport._onClose (http://localhost:8081/src/main.tsx.bundle//&platform=android&dev=true&minify=false&app=com.vfmobileapp&modulesOnly=false&runModule=true:572847:74)\n at http://localhost:8081/src/main.tsx.bundle//&platform=android&dev=true&minify=false&app=com.vfmobileapp&modulesOnly=false&runModule=true:572906:12\n at http://localhost:8081/src/main.tsx.bundle//&platform=android&dev=true&minify=false&app=com.vfmobileapp&modulesOnly=false&runModule=true:34875:21\n at _callTimer (http://localhost:8081/src/main.tsx.bundle//&platform=android&dev=true&minify=false&app=com.vfmobileapp&modulesOnly=false&runModule=true:34786:9)\n at Object.callTimers (http://localhost:8081/src/main.tsx.bundle//&platform=android&dev=true&minify=false&app=com.vfmobileapp&modulesOnly=false&runModule=true:34994:9)\n at MessageQueue.__callFunction (http://localhost:8081/src/main.tsx.bundle//&platform=android&dev=true&minify=false&app=com.vfmobileapp&modulesOnly=false&runModule=true:3292:31)\n at http://localhost:8081/src/main.tsx.bundle//&platform=android&dev=true&minify=false&app=com.vfmobileapp&modulesOnly=false&runModule=true:3012:17"
and the error i am getting is
So I was using
remote-redux-devtools
with a localremotedev
instance and the redux devtools extension for chrome to use for debugging one of my project and after some really long hours trying to get these things to work I was able to make a connection, but there's a catch: the connection keeps getting closed and reopened, and I simply can't figure out why!I started the project using the
create-react-native-app
helper andexpo-cli
.Environment:
create-react-native-app v2.0.2 react-native-cli v2.0.1 react-native v0.59.8 expo-cli v2.20.1 node v11.14.0 npm v6.7.0 yarn v1.16.0
This is my
package.json
To start debugging my project first I start the local devserver by using:
remotedev --host=192.168.2.183 --port=8000
Then I run
adb reverse tcp:8000 tcp:8000
with my device connected (I'm not using emulator). On the code where I create my store I connect to the remotedev server like this:
Then I start the packager like usual with
yarn start
, and then things start getting crazy, because when connecting to the local devserver, my packager log shows this:The output of the
remotedev
command looks like this:And when I start the remote redux devtools extension on chrome it connects to the application for an instant, then disconnects, and keeps repeating this.