Commit f6af3f5
committed
Release 4.0.0: upgrade from
Upgrade grunt-contrib-internal from 6 to 8, which
updates CI from Node 10,12,14 to Node 14,16,18,20.
Fix default connect() hostname to work on Node 18+, where otherwise
CI fails as follows:
> Running "nodeunit:tests" (nodeunit) task
> Testing connect_test.jsFatal error: connect ECONNREFUSED ::1:8000
> Error: connect ECONNREFUSED ::1:8000
> at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16)
Previously, grunt-contrib-connect was passing empty string or null
down to `connect(,hostname)` to leave the default implicitly handled
by `connect` and Node's built-in `http.Server` class. Then, later,
it was doing a fallback to `0.0.0.0` but this only affected the CLI
output text, not the value passed to `connect()`.
Node 17+ changed per nodejs/node#40702 to
prefer IPv6 loopback when available (`::`) instead of IPv4 loopback
(`0.0.0.0`), unless `0.0.0.0` is explicitly passed.
This was fixed in Node 20, with `http.get` underlying `net` TCP module
implementing "Happy Eyeballs" (same as browsers and curl) which
basically means trying both IPv6 and IPv4. nodejs/node#44731
The workaround is to call `dns.setDefaultResultOrder('ipv4first')`
which ensures that the first try is over IPv4 instead of IPv6.opn@6 to open@7, require Node 161 parent 7658372 commit f6af3f5
File tree
6 files changed
+8683
-2158
lines changed- .github/workflows
- tasks
6 files changed
+8683
-2158
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
4 | 10 | | |
5 | 11 | | |
6 | 12 | | |
| |||
13 | 19 | | |
14 | 20 | | |
15 | 21 | | |
16 | | - | |
17 | 22 | | |
| 23 | + | |
18 | 24 | | |
19 | 25 | | |
20 | 26 | | |
21 | | - | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
22 | 30 | | |
23 | 31 | | |
24 | | - | |
| 32 | + | |
25 | 33 | | |
26 | 34 | | |
27 | 35 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
1 | 6 | | |
2 | 7 | | |
3 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
380 | 380 | | |
381 | 381 | | |
382 | 382 | | |
| 383 | + | |
383 | 384 | | |
384 | 385 | | |
385 | 386 | | |
| |||
412 | 413 | | |
413 | 414 | | |
414 | 415 | | |
415 | | - | |
| 416 | + | |
0 commit comments