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

"adb reverse" Still Necessary with --injectserver=reactnative #51

Open
HAMPLENI opened this issue Dec 1, 2017 · 0 comments
Open

"adb reverse" Still Necessary with --injectserver=reactnative #51

HAMPLENI opened this issue Dec 1, 2017 · 0 comments

Comments

@HAMPLENI
Copy link

HAMPLENI commented Dec 1, 2017

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

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}} />

Potential Issue

According to this section of README.md, I should not need to run

adb reverse tcp:8000 tcp:8000

since I am using injectserver:

https:/zalmoxisus/remotedev-server#connect-from-android-device-or-emulator

I get the following error in the debugger for the React Native app if I do not execute adb reverse tcp:8000 tcp:8000:

remote-redux-devtools\lib\devTools.js:216

name: SocketProtocolError
message: "Socket hung up"
code: 1006
stack:

SocketProtocolError: Socket hung up
at SCSocket._onSCClose (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:85993:15)
at SCTransport. (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:85702:12)
at SCTransport.Emitter.emit (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:86425:20)
at SCTransport.SCEmitter.emit (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:86353:26)
at SCTransport._onClose (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:87123:30)
at WebSocket.wsSocket.onerror (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:87057:12)
at WebSocket.dispatchEvent (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:11240:35)
at http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:10317:16
at RCTDeviceEventEmitter.emit (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:10466:35)
at MessageQueue.__callFunction (http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3237:42)

It works properly if I execute:

adb reverse tcp:8000 tcp:8000

Is this to be expected?

If so, I would like to find a way to make sure that port is forwarded whenever an Android emulator or connected device is running off of my machine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant