Skip to content

test: possible flaky test-repl.js #4823

Description

@techjeffharris

I just filed my first PR #4822 and a test in test-repl.js failed.

@chrisdickinson recommended that I create an issue and /CC @Trott

sending "require(\"internal/repl\")"
Unix data: "{ createInternalRepl: [Function: createRepl] }\nnode via Unix socket> ", expecting /^Error: Cannot find module 'internal\/repl'/

assert.js:89
  throw new assert.AssertionError({
  ^
AssertionError: null == true
    at Socket.<anonymous> (/home/jeff/git/node/test/parallel/test-repl.js:69:16)
    at emitOne (events.js:91:13)
    at Socket.emit (events.js:183:7)
    at readableAddChunk (_stream_readable.js:147:16)
    at Socket.Readable.push (_stream_readable.js:111:10)
    at Pipe.onread (net.js:523:20)
Command: out/Release/node /home/jeff/git/node/test/parallel/test-repl.js
[01:31|% 100|+ 1010|-   2]: Done                                               
Makefile:91: recipe for target 'test' failed
make: *** [test] Error 1

Activity

  1. added
    replIssues and PRs related to the REPL subsystem.
    testIssues and PRs related to Node.js core tests and test infrastructure.
    on Jan 23, 2016
  2. santigimeno commented on Feb 26, 2016

    @santigimeno
    Member

    @techjeffharris on what platform? Is still happening?

  3. techjeffharris commented on Mar 2, 2016

    @techjeffharris
    ContributorAuthor

    Ubuntu Gnome 15.10 node v5.x. whichever version was current on Nodesource's ppa the day that I posted that comment.. I'm guessing that it was 5.5 or 5.4. sorry I didn't note that at the time >_<

  4. joaocgreis commented on Mar 23, 2016

    @joaocgreis
    Member

    This test is flaky on any slow machine because it has a 5s timeout in the code. Here is such a failure on RPi1: https://ci.nodejs.org/job/node-test-binary-arm/1468/RUN_SUBSET=3,nodes=pi1-raspbian-wheezy/tapTestReport/test.tap-97/

    This failure in the opening comment looks different, though.

  5. Trott commented on Jun 30, 2016

    @Trott
    Member

    Except for one build failure, stress test for this came up clean. https://ci.nodejs.org/job/node-stress-single-test/765/

    I'm going to close this. Feel free to comment or re-open if it recurs or if you otherwise think it should not be closed at this time.

  6. diastremskii commented on Feb 19, 2017

    @diastremskii
    Contributor

    Not sure if issue should be reopened, but it seems what this test fails if (for some reason) NODE_PATH contains /usr/lib/nodejs and this way node can load all internal libraries without --expose_internal flag.
    I guess some old version of node.js or something else could set this variable. I encountered this issue on PC what had node v0.10.x some time ago.
    Running test with NODE_DEBUG=module shows what module is loaded from /usr/lib/nodejs:

    $ NODE_DEBUG=module node ./test/parallel/test-repl
    [...]
    sending "require(\"internal/repl\")"
    MODULE 9395: Module._load REQUEST internal/repl parent: <repl>
    MODULE 9395: looking for "internal/repl" in ["/home/ubuntu/node/repl/node_modules","/home/ubuntu/node/node_modules","/home/ubuntu/node_modules","/home/node_modules","/node_modules","/usr/lib/nodejs","/home/ubuntu/.node_modules","/home/ubuntu/.node_libraries","/usr/lib/node","/usr/lib/nodejs","/home/ubuntu/.node_modules","/home/ubuntu/.node_libraries","/usr/lib/node"]
    MODULE 9395: load "/usr/lib/nodejs/internal/repl.js" for module "/usr/lib/nodejs/internal/repl.js"
    [...]
    Unix data: "{ createInternalRepl: [Function: createRepl] }\nnode via Unix socket> ", expecting /^Error: Cannot find module 'internal\/repl'/
     
    assert.js:85
      throw new assert.AssertionError({
      ^
    AssertionError: null == true
        at Socket.<anonymous> (/home/ubuntu/node/test/parallel/test-repl.js:76:16)
        at emitOne (events.js:96:13)
        at Socket.emit (events.js:188:7)
        at readableAddChunk (_stream_readable.js:176:18)
        at Socket.Readable.push (_stream_readable.js:134:10)
        at Pipe.onread (net.js:548:20)```
    
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

    replIssues and PRs related to the REPL subsystem.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