-
Notifications
You must be signed in to change notification settings - Fork 30
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
Made '--debug-brk' parameter optional to be able run testcafe on Electron > 19 #92
Conversation
fix: make --debug-brk parameter optional as it no longer works since…
Thank you for your contribution to TestCafe. We will review this PR. |
README.md
Outdated
@@ -175,6 +175,10 @@ __Optional.__ `testcafe-browser-provider-electron` suppresses `did-navigate` and | |||
|
|||
__Optional.__ If `true`, DevTools will be opened just before tests start. | |||
|
|||
### enableDebug |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we need an extra option.
You can calculating the module logic depending on Electron version:
- if Electron < 19, use the old behavior (the
--debug-brk=<port>
will be used`). - if Electron >= 19, use the
--inspect-brk=${ports[1]}
parameter.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought about it, but how can I get the electron version?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have a few ideas on how to implement it in another way. We will check them and update this thread as soon we have any news.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@miherlosev any news here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if someone needs this update urgently, you can install it from fork, but hope changes will be released soon
npm i github:hackolade/testcafe-browser-provider-electron#feat/v0.0.19
Hi @lenchvolodymyr! Thank you for your contribution. I discussed your PR with the team and we decided we should drop supporting older Electron versions that use the |
Hi @AndreyBelym , this even better:
I'll update PR soon |
…versions fix: drop support of old electron versions that used parameter --debu…
@AndreyBelym it's done |
Hi @lenchvolodymyr, Thank you for your work. We will review it. |
--debug-brk
was deprecated since nodejs 7.7.0 and in electron 1.7.4 was added a support for--inspect
. In Electron 19--debug-brk
was supressed and no longer works, which leads to an error: "Unable to connect".I added a new option
enableDebug
that allows using an old parameter--debug-brk
for Electron < 1.7.4 and use--inspect
by default for newer Electron versions.Related issue: #90