Skip to content
This repository has been archived by the owner on Nov 24, 2018. It is now read-only.

setViewport fails when local chrome running in non-default port / host #265

Closed
anttiviljami opened this issue Aug 26, 2017 · 1 comment
Closed

Comments

@anttiviljami
Copy link
Contributor

in the setViewport function, we're using CDP.version(), which according to chrome-remote-interface's documentation should be provided with an options object, just like CDP.New()

https://github.com/graphcool/chromeless/blob/db10706f13812a0de64ea5a15ccf9a16a4dfb8f9/src/util.ts#L27

When running the chrome debugger in a non-default localhost:9222 configuration, using setViewport fails with this error:

error:  Error: connect ECONNREFUSED 127.0.0.1:9222
    at Object.exports._errnoException (util.js:1016:11)
    at exports._exceptionWithHostPort (util.js:1039:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1138:14)

The solution is to supply the options correctly on this line

@anttiviljami
Copy link
Contributor Author

related to larger issue: #267

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

No branches or pull requests

1 participant