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

Investigate flaky parallel/test-net-better-error-messages-port-hostname #12075

Closed
Trott opened this issue Mar 27, 2017 · 8 comments
Closed

Investigate flaky parallel/test-net-better-error-messages-port-hostname #12075

Trott opened this issue Mar 27, 2017 · 8 comments
Labels
flaky-test Issues and PRs related to the tests with unstable failures on the CI. net Issues and PRs related to the net subsystem. test Issues and PRs related to the tests.

Comments

@Trott
Copy link
Member

Trott commented Mar 27, 2017

  • Version: v8.0.0-pre
  • Platform: centos5-32
  • Subsystem: test, net

https://ci.nodejs.org/job/node-test-commit-linux/8716/nodes=centos5-32/console

not ok 740 parallel/test-net-better-error-messages-port-hostname
  ---
  duration_ms: 40.342
  severity: fail
  stack: |-
    
    assert.js:81
      throw new assert.AssertionError({
      ^
    AssertionError: 'EAI_AGAIN' === 'ENOTFOUND'
        at Socket.<anonymous> (/home/iojs/build/workspace/node-test-commit-linux/nodes/centos5-32/test/parallel/test-net-better-error-messages-port-hostname.js:11:10)
        at Socket.<anonymous> (/home/iojs/build/workspace/node-test-commit-linux/nodes/centos5-32/test/common.js:461:15)
        at emitOne (events.js:115:13)
        at Socket.emit (events.js:210:7)
        at connectErrorNT (net.js:1052:8)
        at _combinedTickCallback (internal/process/next_tick.js:80:11)
        at process._tickCallback (internal/process/next_tick.js:104:9)
  ...
@Trott Trott added test Issues and PRs related to the tests. net Issues and PRs related to the net subsystem. labels Mar 27, 2017
@Trott
Copy link
Member Author

Trott commented Mar 27, 2017

@nodejs/testing

@Trott
Copy link
Member Author

Trott commented Mar 27, 2017

EAI_AGAIN is basically "DNS timed out" which seems like it could be legitimate. I'm not convinced thiat we shouldn't allow for that. Thoughts?

@Trott
Copy link
Member Author

Trott commented Mar 27, 2017

I could be mistaken, but it looks to me that test-digitalocean-centos5-x86-1 is configured to use Google DNS. So this test reaches out to the Internet. I wonder if we should move it to test/internet (although I suspect an awful lot of our tests do DNS lookups like this so maybe just live with it and allow for the occasional EAI_AGAIN). @nodejs/build

@cjihrig
Copy link
Contributor

cjihrig commented Mar 27, 2017

The test could be updated to allow for EAI_AGAIN. I wonder why EAI_AGAIN wasn't clumped into the group of errors comprising the made up ENOTFOUND (not saying we should do that now).

Another alternative would be to monkey patch the DNS to always return the correct error. I don't think that's a great idea, but I don't like moving things to test/internet either.

@Trott
Copy link
Member Author

Trott commented Jul 30, 2017

@addaleax Any chance this is a good candidate for the test-double DNS server that always returns an error that you created in common?

@addaleax
Copy link
Member

addaleax commented Jul 30, 2017

@Trott I think that’s doable and makes sense, yes. :) I can look into it, but if you want this could actually be a nice second or third contribution or so.

Edit: That might also actually allow us to test a real domain + port combination instead of the fake *** one here

@addaleax
Copy link
Member

Sorry, I misread that, net uses dns.lookup, not dns.resolve, so using dns.setServers() won’t have any effect here.

@refack refack added the flaky-test Issues and PRs related to the tests with unstable failures on the CI. label Jul 31, 2017
@BridgeAR
Copy link
Member

This got fixed by 0309619

danbev added a commit to danbev/node that referenced this issue Oct 22, 2017
The motivation for this commit is that these two test fail on systems
that have different Name Service Switch configuration settings. A
concrete example of this is when using Red Hat Enterprise Linux (RHEL)
7.

If Name Service Switch is available on the operating system then it
might be configured differently (/etc/nsswitch.conf).
If the system is configured with no dns the error code will be
AI_AGAIN, but if there are more services after the dns entry, for
example some linux distributions skip a myhostname service by default
which would still produce the ENOTFOUND error.

This commit suggests checking for either ENOTFOUND or EAI_AGAIN to
accommodate systems like the ones described above. The references below
indicate that others have run, or are running, into this aswell.

Refs: nodejs#12075
Refs: nodejs/help#687
danbev added a commit to danbev/node that referenced this issue Oct 25, 2017
The motivation for this commit is that these two test fail on systems
that have different Name Service Switch configuration settings. A
concrete example of this is when using Red Hat Enterprise Linux (RHEL)
7.

If Name Service Switch is available on the operating system then it
might be configured differently (/etc/nsswitch.conf).
If the system is configured with no dns the error code will be
AI_AGAIN, but if there are more services after the dns entry, for
example some linux distributions skip a myhostname service by default
which would still produce the ENOTFOUND error.

This commit suggests checking for either ENOTFOUND or EAI_AGAIN to
accommodate systems like the ones described above. The references below
indicate that others have run, or are running, into this aswell.

Refs: nodejs#12075
Refs: nodejs/help#687
Refs: nodejs#15825
PR-URL: nodejs#16378
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
cjihrig pushed a commit that referenced this issue Oct 25, 2017
The motivation for this commit is that these two test fail on systems
that have different Name Service Switch configuration settings. A
concrete example of this is when using Red Hat Enterprise Linux (RHEL)
7.

If Name Service Switch is available on the operating system then it
might be configured differently (/etc/nsswitch.conf).
If the system is configured with no dns the error code will be
AI_AGAIN, but if there are more services after the dns entry, for
example some linux distributions skip a myhostname service by default
which would still produce the ENOTFOUND error.

This commit suggests checking for either ENOTFOUND or EAI_AGAIN to
accommodate systems like the ones described above. The references below
indicate that others have run, or are running, into this aswell.

Refs: #12075
Refs: nodejs/help#687
Refs: #15825
PR-URL: #16378
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
addaleax pushed a commit to ayojs/ayo that referenced this issue Oct 26, 2017
The motivation for this commit is that these two test fail on systems
that have different Name Service Switch configuration settings. A
concrete example of this is when using Red Hat Enterprise Linux (RHEL)
7.

If Name Service Switch is available on the operating system then it
might be configured differently (/etc/nsswitch.conf).
If the system is configured with no dns the error code will be
AI_AGAIN, but if there are more services after the dns entry, for
example some linux distributions skip a myhostname service by default
which would still produce the ENOTFOUND error.

This commit suggests checking for either ENOTFOUND or EAI_AGAIN to
accommodate systems like the ones described above. The references below
indicate that others have run, or are running, into this aswell.

Refs: nodejs/node#12075
Refs: nodejs/help#687
Refs: nodejs/node#15825
PR-URL: nodejs/node#16378
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
MylesBorins pushed a commit that referenced this issue Nov 16, 2017
The motivation for this commit is that these two test fail on systems
that have different Name Service Switch configuration settings. A
concrete example of this is when using Red Hat Enterprise Linux (RHEL)
7.

If Name Service Switch is available on the operating system then it
might be configured differently (/etc/nsswitch.conf).
If the system is configured with no dns the error code will be
AI_AGAIN, but if there are more services after the dns entry, for
example some linux distributions skip a myhostname service by default
which would still produce the ENOTFOUND error.

This commit suggests checking for either ENOTFOUND or EAI_AGAIN to
accommodate systems like the ones described above. The references below
indicate that others have run, or are running, into this aswell.

Refs: #12075
Refs: nodejs/help#687
Refs: #15825
PR-URL: #16378
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
MylesBorins pushed a commit that referenced this issue Nov 21, 2017
The motivation for this commit is that these two test fail on systems
that have different Name Service Switch configuration settings. A
concrete example of this is when using Red Hat Enterprise Linux (RHEL)
7.

If Name Service Switch is available on the operating system then it
might be configured differently (/etc/nsswitch.conf).
If the system is configured with no dns the error code will be
AI_AGAIN, but if there are more services after the dns entry, for
example some linux distributions skip a myhostname service by default
which would still produce the ENOTFOUND error.

This commit suggests checking for either ENOTFOUND or EAI_AGAIN to
accommodate systems like the ones described above. The references below
indicate that others have run, or are running, into this aswell.

Refs: #12075
Refs: nodejs/help#687
Refs: #15825
PR-URL: #16378
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
MylesBorins pushed a commit that referenced this issue Nov 28, 2017
The motivation for this commit is that these two test fail on systems
that have different Name Service Switch configuration settings. A
concrete example of this is when using Red Hat Enterprise Linux (RHEL)
7.

If Name Service Switch is available on the operating system then it
might be configured differently (/etc/nsswitch.conf).
If the system is configured with no dns the error code will be
AI_AGAIN, but if there are more services after the dns entry, for
example some linux distributions skip a myhostname service by default
which would still produce the ENOTFOUND error.

This commit suggests checking for either ENOTFOUND or EAI_AGAIN to
accommodate systems like the ones described above. The references below
indicate that others have run, or are running, into this aswell.

Refs: #12075
Refs: nodejs/help#687
Refs: #15825
PR-URL: #16378
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
addaleax pushed a commit to ayojs/ayo that referenced this issue Dec 7, 2017
The motivation for this commit is that these two test fail on systems
that have different Name Service Switch configuration settings. A
concrete example of this is when using Red Hat Enterprise Linux (RHEL)
7.

If Name Service Switch is available on the operating system then it
might be configured differently (/etc/nsswitch.conf).
If the system is configured with no dns the error code will be
AI_AGAIN, but if there are more services after the dns entry, for
example some linux distributions skip a myhostname service by default
which would still produce the ENOTFOUND error.

This commit suggests checking for either ENOTFOUND or EAI_AGAIN to
accommodate systems like the ones described above. The references below
indicate that others have run, or are running, into this aswell.

Refs: nodejs/node#12075
Refs: nodejs/help#687
Refs: nodejs/node#15825
PR-URL: nodejs/node#16378
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
flaky-test Issues and PRs related to the tests with unstable failures on the CI. net Issues and PRs related to the net subsystem. test Issues and PRs related to the tests.
Projects
None yet
Development

No branches or pull requests

5 participants