Esm: TypeError: Cannot read property 'next' of undefined

Created on 8 Mar 2019  路  3Comments  路  Source: standard-things/esm

I'm getting a build error on Travis from ESM with the following error:

file:///home/travis/build/ericelliott/autodux/node_modules/riteway/node_modules/esm/esm.js:1
TypeError: Cannot read property 'next' of undefined
    at file:///home/travis/build/ericelliott/autodux/node_modules/riteway/node_modules/esm/esm.js:1
    at file:///home/travis/build/ericelliott/autodux/node_modules/riteway/node_modules/esm/esm.js:1
    at Object.apply (file:///home/travis/build/ericelliott/autodux/node_modules/riteway/node_modules/esm/esm.js:1)
    at file:///home/travis/build/ericelliott/autodux/node_modules/nyc/node_modules/append-transform/index.js:62:4
    at Object.<anonymous> (file:///home/travis/build/ericelliott/autodux/node_modules/nyc/node_modules/append-transform/index.js:62:4)
    at Object.xh (file:///home/travis/build/ericelliott/autodux/node_modules/riteway/node_modules/esm/esm.js:1)

I can't reproduce this on my local machine, so debugging it is tricky.

Of note though is that the error is coming from esm in RITEway, and I'm also using esm in autodux, which depends on RITEway.

Am I doing this wrong?

bug needs tests

Most helpful comment

I can repro it too, even on the same esm version. Digging in.

Update:

I've isolated the problem.

Update:

Fixed it locally.

Update:

esm v3.2.14 is released 馃帀

All 3 comments

So the last couple of updates to esm allowed it to work with the nyc cache without blowing it away (as it used to do). I'm wondering if you update your esm version across the deps if the issue is resolve. If you do that and the issue isn't it could point to a gap in the nyc cache fix.

I can't reproduce this on my local machine, so debugging it is tricky.

I can repro when running npm run test-coverage-ci, node v11.11.0, macOS

[although it also passes once in a while when run multiple times in a row.]

I can repro it too, even on the same esm version. Digging in.

Update:

I've isolated the problem.

Update:

Fixed it locally.

Update:

esm v3.2.14 is released 馃帀

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mbostock picture mbostock  路  3Comments

OmgImAlexis picture OmgImAlexis  路  3Comments

MVSICA-FICTA picture MVSICA-FICTA  路  3Comments

mAAdhaTTah picture mAAdhaTTah  路  3Comments

kherock picture kherock  路  3Comments