zalmoxisus / remotedev-server

Connect Redux DevTools extension to a remote app.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Debugging on an Android Physical Device While Also Running remotedev-server Results in SocketProtocolErrors

HAMPLENI opened this issue · comments

Setup

OS

Windows 10

remote-redux-devtools

"remote-redux-devtools": "0.5.0"

const composeEnhancers = composeWithDevTools({hostname: "localhost", port: 8000});

remotedev-server

"remotedev-server": "0.2.4"

remotedev --hostname=localhost --port=8000 --injectserver=reactnative

adb reverse tcp:8000 tcp:8000

remotedev-app

    "react": "15.6.2",
    "react-dom": "15.6.2",
    "react-scripts": "1.0.17",
    "remotedev-app": "0.10.8"

<DevToolsApp socketOptions={{hostname: "localhost", port: "8000", autoReconnect: true}} />

Issue

After I run the

adb reverse tcp:8081 tcp:8081

command and attach the debugger, I get the following errors in Chrome Developer Tools window for the React Native application:

...\node_modules\remote-redux-devtools\lib\devTools.js:216 SocketProtocolError {name: "SocketProtocolError", message: "Server ping timed out", code: 4000, stack: "SocketProtocolError: Server ping timed out↵ at …=android&dev=true&hot=false&minify=false:3236:42)"}code: 4000message: "Server ping timed out"name: "SocketProtocolError"stack: "SocketProtocolError: Server ping timed out↵ at SCSocket._onSCClose (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:85992:15)↵ at SCTransport. (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:85696:12)↵ at SCTransport.Emitter.emit (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:86424:20)↵ at SCTransport.SCEmitter.emit (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:86352:26)↵ at SCTransport._onClose (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:87119:30)↵ at http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:87175:10↵ at http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:11570:19↵ at Object.callTimer (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3353:9)↵ at Object.callTimers (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3383:25)↵ at MessageQueue.callFunction (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3236:42)"__proto: Error

...\node_modules\remote-redux-devtools\lib\devTools.js:216 SocketProtocolError {name: "SocketProtocolError", message: "Server ping timed out", code: 4000, stack: "SocketProtocolError: Server ping timed out↵ at …=android&dev=true&hot=false&minify=false:3236:42)"}code: 4000message: "Server ping timed out"name: "SocketProtocolError"stack: "SocketProtocolError: Server ping timed out↵ at SCSocket._onSCClose (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:85992:15)↵ at SCTransport. (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:85696:12)↵ at SCTransport.Emitter.emit (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:86424:20)↵ at SCTransport.SCEmitter.emit (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:86352:26)↵ at SCTransport._onClose (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:87119:30)↵ at http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:87175:10↵ at http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:11570:19↵ at Object.callTimer (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3353:9)↵ at Object.callTimers (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3383:25)↵ at MessageQueue.callFunction (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3236:42)"__proto: Error

...\node_modules\remote-redux-devtools\lib\devTools.js:216 SocketProtocolError {name: "SocketProtocolError", message: "Client connection establishment timed out", code: 4007, stack: "SocketProtocolError: Client connection establishme…=android&dev=true&hot=false&minify=false:3236:42)"}code: 4007message: "Client connection establishment timed out"name: "SocketProtocolError"stack: "SocketProtocolError: Client connection establishment timed out↵ at SCSocket._onSCClose (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:85992:15)↵ at SCTransport. (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:85701:12)↵ at SCTransport.Emitter.emit (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:86424:20)↵ at SCTransport.SCEmitter.emit (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:86352:26)↵ at SCTransport._onClose (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:87122:30)↵ at http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:87061:10↵ at http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:11570:19↵ at Object.callTimer (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3353:9)↵ at Object.callTimers (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3383:25)↵ at MessageQueue.callFunction (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3236:42)"__proto: Error

Remote Redux DevTools works properly if I do not attach the debugger and React Native debugging works properly if I do not inject RemoteDev server into the React Native local server.

Also, I am able to do this just fine when using an Android Emulator.

Same here
I runing remotedev-server on my mac, and inspecting physical android device. Geting timeouts.

Android 8