You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
They suggest to use chrome://inspect instead. But, if my understanding is correct, the inspect page can't access directly. Should we remove accessing a page and show a message only?
Reacted by artem avetisyan, Andrii Gladkyi, pokonski, Ryan Taylor Long, Oskars Ezerins, Matouš Borák and Dima K.
The discovery page content seems to have been removed and the page is now empty (since this commit, released in Chrome 100).
A workaround that works for us is to load the JSON version of the page (http://127.0.0.1:<port>/json) and append the first devtoolsFrontendUrl path to the discovery page URL.
This will launch the browser where you can inspect the content.
but, while it does open a visible browser window, the content is empty:
I was considering opening an issue for it, but it sounds like this #161 is already the issue for this bug, right? It's just that as a new user who is just following the Readme and is unfamiliar with terms like "discovery page", I would not have recognized this issue as being the one to look at for my problem. Should we update the title to some thing more like what users might be searching for, like "Debug open new tab but just shows a blank page"?
Anyway, thanks for the workaround! That does work for me:
Change the address bar to http://127.0.0.1:<port>/json
Take the first devtoolsFrontendUrl path and edit the address bar to use it.
Could those steps be automated and done for the user automatically? Or does the driver not have a way to control the visible window?
Since the instructions for this are currently incomplete, should we update the Readme in the meantime to include the full instructions (the above "workaround") for how to inspect your actual page-under-test? Unless a fix for this is forthcoming...?
I fixed it for now by monkey-patching the method which generates the debug url (put this in some file which is loaded after cuprite, e.g. spec/support/cuprite.rb if you autoload files in that folder):
moduleCapybaramoduleCupriteclassDriverdefdebug_urlresponse=JSON.parse(Net::HTTP.get(URI(build_remote_debug_url(path: "/json"))))devtools_frontend_path=response[0]&.[]("devtoolsFrontendUrl")raise"Could not generate debug url for remote debugging session"unlessdevtools_frontend_pathbuild_remote_debug_urlpath: devtools_frontend_pathendprivatedefbuild_remote_debug_url(path:)"http://#{browser.process.host}:#{browser.process.port}#{path}"endendendend
Edit: I am not sure if this is exclusive to my setup, but I also needed to add a browser option otherwise the devtools websocket wouldn't connect.
Activity
borama commentedon Aug 18, 2022
The discovery page content seems to have been removed and the page is now empty (since this commit, released in Chrome 100).
A workaround that works for us is to load the JSON version of the page (
http://127.0.0.1:<port>/json) and append the firstdevtoolsFrontendUrlpath to the discovery page URL.TylerRick commentedon Oct 27, 2022
I tried
page.driver.debug(binding)as described at https://github.com/rubycdp/cuprite#debuggingbut, while it does open a visible browser window, the content is empty:
I was considering opening an issue for it, but it sounds like this #161 is already the issue for this bug, right? It's just that as a new user who is just following the Readme and is unfamiliar with terms like "discovery page", I would not have recognized this issue as being the one to look at for my problem. Should we update the title to some thing more like what users might be searching for, like "Debug open new tab but just shows a blank page"?
Anyway, thanks for the workaround! That does work for me:
http://127.0.0.1:<port>/jsondevtoolsFrontendUrlpath and edit the address bar to use it.Could those steps be automated and done for the user automatically? Or does the driver not have a way to control the visible window?
Since the instructions for this are currently incomplete, should we update the Readme in the meantime to include the full instructions (the above "workaround") for how to inspect your actual page-under-test? Unless a fix for this is forthcoming...?
jpheos commentedon Nov 28, 2023
I have exactly the same issue as you @TylerRick .
If a add
/jsonI can find the url, but maybe you find a better solution since 2022 ?phikes commentedon Nov 29, 2023
I fixed it for now by monkey-patching the method which generates the debug url (put this in some file which is loaded after cuprite, e.g.
spec/support/cuprite.rbif you autoload files in that folder):Edit: I am not sure if this is exclusive to my setup, but I also needed to add a browser option otherwise the devtools websocket wouldn't connect.
I'd gladly create a PR if desired.
route commentedon Dec 11, 2023
@phikes does it open devtools session for you? I have this message on my Mac:

What OS, Chrome version do you have?
phikes commentedon Dec 11, 2023
Yes, it does. I use Chrome Canary on OS X Ventura 13.0.1. Did you try the
browser_optionsI posted below? Before that I always got this error.route commentedon Dec 11, 2023
Missed it somehow. Could you please create a PR?
phikes commentedon Dec 12, 2023
@route done in #252
route commentedon Dec 13, 2023
Thanks!