-
Notifications
You must be signed in to change notification settings - Fork 29.7k
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
test: retry on smartos if ECONNREFUSED #3941
Conversation
R: @indutny |
Is retrying just once generally enough? Perhaps it should log something to stderr? |
SmartOS has a bug that causes unexpected ECONNREFUSED errors. See https://smartos.org/bugview/OS-2767 If ECONNREFUSED on SmartOS, retry the test one time. Fixes: nodejs#3864 Fixes: nodejs#2815 PR-URL: nodejs#3941
In most cases, once is probably enough. If stress testing a single test, we typically have to run hundreds of times before we see a failure like this. The exception might be the max-connections test that opens 200 connection attempts, so it may fail much more often. But that test has a fix for this problem within itself, which is probably appropriate. It's a special case. I skipped logging to stderr because I wasn't sure it wouldn't mess up TAP output etc. But I can take a closer look and sort that out... |
Bikeshed question, feel free to ignore: Should the commit message be |
You are right, logging it this way will break TAP (most likely). Let's keep it as it is for now, and then fix somewhere later. |
I think |
if (output.UnexpectedOutput() and | ||
sys.platform == 'sunos5' and | ||
'ECONNREFUSED' in output.output.stderr): | ||
sys.stderr.write('ECONNREFUSED encountered on SmartOS; retrying test.') |
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.
Sorry, but I think I was wrong about it. This sounds like a bad idea. We should fix it later.
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 created a new branch and moved the write()
statement outside of the if
so that it triggered every time. It didn't seem to mess up TAP. https://ci.nodejs.org/job/node-test-commit-smartos/387/nodes=smartos14-32/console
So, we could leave it in if the info is helpful. (I'll have to add a \n
to the print string, but that's easy enough of course.)
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.
It actually should use some of the classes in this file to produce correct output, be it TAP or anything else. Right now it doesn't fit into the global scheme of test.py
, this is why I am a bit worried about leaving it as it is.
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.
Cool, I'm happy to take it out.
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.
Yep, let's do it this way!
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 mean remove it for now, and open PR later
Logging to stderr removed, will figure that out in a subsequent PR. |
LGTM, if CI is green |
@Trott I think you started wrong CI ;) |
@indutny Indeed. Let's try again... |
Thanks! |
SmartOS has a bug that causes unexpected ECONNREFUSED errors. See https://smartos.org/bugview/OS-2767 If ECONNREFUSED on SmartOS, retry the test one time. Fixes: nodejs#3864 Fixes: nodejs#2815 PR-URL: nodejs#3941
Landed in 8bc8038 |
SmartOS has a bug that causes unexpected ECONNREFUSED errors. See https://smartos.org/bugview/OS-2767 If ECONNREFUSED on SmartOS, retry the test one time. Fixes: #3864 Fixes: #2815 PR-URL: #3941 Reviewed-By: Fedor Indutny <fedor@indutny.com>
SmartOS has a bug that causes unexpected ECONNREFUSED errors. See https://smartos.org/bugview/OS-2767 If ECONNREFUSED on SmartOS, retry the test one time. Fixes: #3864 Fixes: #2815 PR-URL: #3941 Reviewed-By: Fedor Indutny <fedor@indutny.com>
SmartOS has a bug that causes unexpected ECONNREFUSED errors. See https://smartos.org/bugview/OS-2767 If ECONNREFUSED on SmartOS, retry the test one time. Fixes: #3864 Fixes: #2815 PR-URL: #3941 Reviewed-By: Fedor Indutny <fedor@indutny.com>
SmartOS has a bug that causes unexpected ECONNREFUSED errors. See https://smartos.org/bugview/OS-2767 If ECONNREFUSED on SmartOS, retry the test one time. Fixes: #3864 Fixes: #2815 PR-URL: #3941 Reviewed-By: Fedor Indutny <fedor@indutny.com>
SmartOS has a bug that causes unexpected ECONNREFUSED errors. See https://smartos.org/bugview/OS-2767 If ECONNREFUSED on SmartOS, retry the test one time. Fixes: #3864 Fixes: #2815 PR-URL: #3941 Reviewed-By: Fedor Indutny <fedor@indutny.com>
SmartOS has a bug that causes unexpected ECONNREFUSED errors. See https://smartos.org/bugview/OS-2767 If ECONNREFUSED on SmartOS, retry the test one time. Fixes: #3864 Fixes: #2815 PR-URL: #3941 Reviewed-By: Fedor Indutny <fedor@indutny.com>
There is a known issue with SmartOS that is generally worked around in `tools/test.py`. However, a more robust workaround is required for some tests that open many network connections. `test-http-regr-nodejsgh-2928` is one such test. Fixes: nodejs#5445 Refs: nodejs#3941 PR-URL: nodejs#5454
There is a known issue with SmartOS that is generally worked around in `tools/test.py`. However, a more robust workaround is required for some tests that open many network connections. `test-http-regr-nodejsgh-2928` is one such test. Fixes: nodejs#5445 Refs: nodejs#3941 PR-URL: nodejs#5454 Reviewed-By: Fedor Indutny <fedor@indutny.com>
There is a known issue with SmartOS that is generally worked around in `tools/test.py`. However, a more robust workaround is required for some tests that open many network connections. `test-http-regr-gh-2928` is one such test. Fixes: #5445 Refs: #3941 PR-URL: #5454 Reviewed-By: Fedor Indutny <fedor@indutny.com>
There is a known issue with SmartOS that is generally worked around in `tools/test.py`. However, a more robust workaround is required for some tests that open many network connections. `test-http-regr-gh-2928` is one such test. Fixes: #5445 Refs: #3941 PR-URL: #5454 Reviewed-By: Fedor Indutny <fedor@indutny.com>
There is a known issue with SmartOS that is generally worked around in `tools/test.py`. However, a more robust workaround is required for some tests that open many network connections. `test-http-regr-gh-2928` is one such test. Fixes: #5445 Refs: #3941 PR-URL: #5454 Reviewed-By: Fedor Indutny <fedor@indutny.com>
SmartOS has a bug that causes unexpected ECONNREFUSED errors.
See https://smartos.org/bugview/OS-2767
If ECONNREFUSED on SmartOS, retry the test one time.
Fixes: #3864