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

Unable to find chrome session started by Protractor #4606

Closed
m2kannojiya opened this issue Feb 23, 2018 · 5 comments
Closed

Unable to find chrome session started by Protractor #4606

m2kannojiya opened this issue Feb 23, 2018 · 5 comments

Comments

@m2kannojiya
Copy link

I want to run lighthouse on complete flow. I can automate this with protractor or any other automation tool but when I am running lighthouse. It is opening new instance of Chrome driver and run like incognito window i.e. entirely new session. Is there any way we can get existing session so that we can audit entire flow of an application.

@patrickhulce
Copy link
Collaborator

I'm not super familiar with protractor, but from what I can tell it's based on Selenium/WebDriver which uses the same protocol Lighthouse does. Basic approach you'll want to follow is to make sure you tell protractor to tell selenium to use the same port option you're passing to Lighthouse.

Headless chrome section on webdriver might help. Looks like you might want to use seleniumArgs argument of protract to pass --port=9222?

@ebidel might be able to help a little more.

@m2kannojiya
Copy link
Author

Unfortunately protractor can't use -remote-debugging-port which may help but that is used by chrome itself so it is not possible. @patrickhulce do you know any other automation tool which can be used with lighthouse? Do you ever come across this type of requirement by other users. I think this is very common scenario and there should be some way to achieve this.

@patrickhulce
Copy link
Collaborator

We're working on making sure Lighthouse works really well with puppeteer and there are a few open issues describing how to get things started today (#3837, #4403). Some folks over in #1418 have some automation stories as well.

You seem to have figured this one out already, but also noticed that over in #1833 @paulirish noted

there's currently no way that selenium can hand over control to lighthouse, as chromedriver doesn't support proxying raw protocol commands, and we'd need that.

so sorry for the wild goose chase on that :)

@m2kannojiya
Copy link
Author

Thanks Patrick for information

@Utsavutsavs
Copy link

can we use lighthouse with protractor for end to end flow??
please guide if yes

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

No branches or pull requests

4 participants
@patrickhulce @m2kannojiya @Utsavutsavs and others