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

TestCafe crashes on Node 18 #7396

Closed
alex-zh opened this issue Nov 25, 2022 · 2 comments
Closed

TestCafe crashes on Node 18 #7396

alex-zh opened this issue Nov 25, 2022 · 2 comments
Assignees
Labels
FREQUENCY: critical TYPE: bug The described behavior is considered as wrong (bug).

Comments

@alex-zh
Copy link

alex-zh commented Nov 25, 2022

What is your Scenario?

Everything works fine on Node 14.
Update to Node 18 leads to "500 Internal Server Error" while loading
http://localhost:5003/GFxi51qUa!s!utf-8/http://localhost:8080/hub/assets/main.js
though http://localhost:8080/hub/assets/main.js is available
Checked the same problem with different domain names (besides localhost).
See attached screenshots.

What is the Current behavior?

It seems there is some internal problem with testcafe proxying, should work correctly

What is the Expected behavior?

Should work correctly

What is your public website URL? (or attach your complete example)

What is your TestCafe test code?

Standard site using webpack-devserver

Your complete configuration file

No response

Your complete test report

No response

Screenshots

TestCafe_Node18

Steps to Reproduce

  1. Run tests
  2. See the page is not open

TestCafe version

2.1.0

Node.js version

18.12.1

Command-line arguments

Browser name(s) and version(s)

Chrome 107.0.5304.122

Platform(s) and version(s)

Windows

Other

No response

@alex-zh alex-zh added the TYPE: bug The described behavior is considered as wrong (bug). label Nov 25, 2022
@need-response-app need-response-app bot added the STATE: Need response An issue that requires a response or attention from the team. label Nov 25, 2022
@Aleksey28
Copy link
Collaborator

Hi @alex-zh,

I managed to reproduce the issue. We will update this thread once we have any news.

For the team:

  1. Start http-server with any page and any port.
  2. Try to open the URL with localhost in http-playground.

@need-response-app need-response-app bot removed the STATE: Need response An issue that requires a response or attention from the team. label Nov 28, 2022
@AndreyBelym
Copy link
Contributor

It happens due to this change in Node.js: nodejs/node#40537. We will try to fix it ASAP. Right now, you can add this line at the start of some of your test files or a JS config file:

require('dns').setDefaultResultOrder('ipv4first');

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
FREQUENCY: critical TYPE: bug The described behavior is considered as wrong (bug).
Projects
None yet
Development

No branches or pull requests

3 participants