naugtur / blocked-at

Detects node eventloop block and reports where it started
MIT License
321 stars 25 forks source link

failing test: Expected test/index.js:17 in stack trace #10

Closed andrewsensus closed 6 years ago

andrewsensus commented 6 years ago

npm test fails. Looking a bit closer, .\test\index.js is the failing component (not .\test\runtime.js, which I ran on its own & it passed).

PS C:\Working\blocked-at> node .\test\index.js
slow: 99.777ms
slow: 99.666ms
101.79732501220703 [ '    at new Immediate (timers.js:816:5)',
  '    at createImmediate (timers.js:858:19)',
  '    at setImmediate (timers.js:845:10)',
  '    at Object.<anonymous> (C:\\Working\\blocked-at\\test\\index.js:17:1)',
  '    at Module._compile (module.js:635:30)',
  '    at Object.Module._extensions..js (module.js:646:10)',
  '    at Module.load (module.js:554:32)',
  '    at tryModuleLoad (module.js:497:12)',
  '    at Function.Module._load (module.js:489:3)',
  '    at Function.Module.runMain (module.js:676:10)',
  '    at startup (bootstrap_node.js:187:16)',
  '    at bootstrap_node.js:608:3' ]
101.19250700378419 [ '    at Promise.then (<anonymous>)',
  '    at Immediate.start (C:\\Working\\blocked-at\\test\\cases\\promise.js:9:6)',
  '    at runCallback (timers.js:789:20)',
  '    at tryOnImmediate (timers.js:751:5)',
  '    at processImmediate [as _immediateCallback] (timers.js:722:5)' ]
318.04360400390624 [ '    at Object.lookup (dns.js:182:19)',
  '    at lookupAndListen (net.js:1496:7)',
  '    at Server.listen (net.js:1472:7)',
  '    at Immediate.start (C:\\Working\\blocked-at\\test\\cases\\http.js:11:10)',
  '    at runCallback (timers.js:789:20)',
  '    at tryOnImmediate (timers.js:751:5)',
  '    at processImmediate [as _immediateCallback] (timers.js:722:5)' ]
slow: 99.807ms
100.34066600036621 [ '    at Object.fs.read (fs.js:664:11)',
  '    at C:\\Working\\blocked-at\\test\\cases\\example.js:20:10',
  '    at FSReqWrap.oncomplete (fs.js:135:15)' ]
slow: 99.063ms
102.48495599365235 [ '    at Server.connectionListener (_http_server.js:309:10)',
  '    at emitOne (events.js:116:13)',
  '    at Server.emit (events.js:211:7)',
  '    at TCP.onconnection (net.js:1561:8)' ]
slow: 99.716ms
100.05577499389648 [ '    at new Immediate (timers.js:816:5)',
  '    at createImmediate (timers.js:858:19)',
  '    at setImmediate (timers.js:845:10)',
  '    at Immediate.recursive (C:\\Working\\blocked-at\\test\\cases\\recursive.js:6:5)',
  '    at runCallback (timers.js:791:20)',
  '    at tryOnImmediate (timers.js:751:5)',
  '    at processImmediate [as _immediateCallback] (timers.js:722:5)' ]
assert.js:42
  throw new errors.AssertionError({
  ^

AssertionError [ERR_ASSERTION]: Expected test/index.js:17 in stack trace
    at Timeout._ [as _onTimeout] (C:\Working\blocked-at\test\index.js:28:3)
    at ontimeout (timers.js:475:11)
    at tryOnTimeout (timers.js:310:5)
    at Timer.listOnTimeout (timers.js:270:5)
PS C:\Working\blocked-at> git rev-parse HEAD
b5751e1fe465de0dfd43de19d42be3c82ed96d8a
PS C:\Working\blocked-at> git describe HEAD
v1.1.2
PS C:\Working\blocked-at> node --version
v8.9.1
PS C:\Working\blocked-at>
naugtur commented 6 years ago

Oh windows. Thanks for reporting, It seems to be about the slashes.

the test would have to expect test/index or test\index

If you could PR this change, I'd be grateful. My life is currently all about a certain 14daysold that needs my care and I'm writing this to you in my first break in over a week.

naugtur commented 6 years ago

huge thanks. sorry I missed the notifications...