Skip to content

Investigate flaky test-dgram-udp6-send-default-host on OS X #6577

Description

@Trott
  • Version: master branch
  • Platform: OS X
  • Subsystem: test? dgram?

Failure in CI on test of unrelated change: https://ci.nodejs.org/job/node-test-commit-osx/3210/nodes=osx1010/tapTestReport/test.tap-213/

not ok 213 test-dgram-udp6-send-default-host.js
# 
# assert.js:90
#   throw new assert.AssertionError({
#   ^
# AssertionError: message was received correctly
#     at Socket.<anonymous> (/Users/iojs/build/workspace/node-test-commit-osx/nodes/osx1010/test/parallel/test-dgram-udp6-send-default-host.js:29:10)
#     at emitTwo (events.js:106:13)
#     at Socket.emit (events.js:191:7)
#     at UDP.onMessage (dgram.js:532:8)
  ---
  duration_ms: 0.145

/cc @nodejs/testing @addaleax

Activity

  1. added
    dgramIssues and PRs related to UDP and the dgram module.
    testIssues and PRs related to Node.js core tests and test infrastructure.
    macosIssues and PRs related to the macOS platform.
    on May 4, 2016
  2. Trott commented on May 4, 2016

    @Trott
    MemberAuthor
  3. Trott commented on May 4, 2016

    @Trott
    MemberAuthor
  4. santigimeno commented on May 4, 2016

    @santigimeno
    Member

    Have seen this failure locally a couple of times though I cannot reproduce it consistently :/.
    Maybe use assert.strictEqual here would help to find out what's going on.

  5. Trott commented on May 4, 2016

    @Trott
    MemberAuthor

    @santigimeno Yup, I had the same thought and am putting in the PR for that right now...

  6. Trott commented on May 4, 2016

    @Trott
    MemberAuthor
  7. mcollina commented on May 5, 2016

    @mcollina
    SponsorMember

    This is fairly unexpected, as the ipv4 equivalent of this test is not flaky.

    Is this flaky only on Mac? Hopefully #6581 should tell what's happening. I have never seen it fail here.

  8. santigimeno commented on May 5, 2016

    @santigimeno
    Member

    It looks like the problem is that sometimes the messages are not received in order, which makes sense being UDP. See output from https://ci.nodejs.org/job/node-stress-single-test/nodes=osx1010/690 :

    not ok 1 test-dgram-udp6-send-default-host.js
    # 
    # assert.js:90
    #   throw new assert.AssertionError({
    #   ^
    # AssertionError: 'hello' === 'yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy
    #     at Socket.<anonymous> (/Users/iojs/build/workspace/node-stress-single-test/nodes/osx1010/test/parallel/test-dgram-udp6-send-default-host.js:29:10)
    #     at emitTwo (events.js:106:13)
    #     at Socket.emit (events.js:191:7)
    #     at UDP.onMessage (dgram.js:532:8)
      ---
      duration_ms: 0.139
    
  9. addaleax commented on May 5, 2016

    @addaleax
    Member

    Could it be that the kernel decides to reorder the packets here for some reason? That’s allowed, although I can’t see why it would. But it would explain why the test is flaky and why this is an OS-specific issue.

  10. santigimeno commented on May 5, 2016

    @santigimeno
    Member

    @addaleax Some comments here like this suggest that could be the reason

  11. addaleax commented on May 5, 2016

    @addaleax
    Member

    👍 I guess the IPv4 test has a chance of being flaky too, then?

  12. santigimeno commented on May 5, 2016

    @santigimeno
    Member

    Is there an equivalent IPv4 test? I can't find it.

  13. addaleax commented on May 5, 2016

    @addaleax
    Member

    @santigimeno test/parallel/test-dgram-send-default-host.js

  14. santigimeno commented on May 5, 2016

    @santigimeno
    Member

    @addaleax Thanks! I guess it should also be rewritten

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    dgramIssues and PRs related to UDP and the dgram module.macosIssues and PRs related to the macOS platform.testIssues and PRs related to Node.js core tests and test infrastructure.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions