nodejs / citgm

Canary in the Gold Mine

Home Page:https://www.npmjs.com/package/citgm

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Node.js 18 CITGM Results

BethGriggs opened this issue · comments

Node.js 18 CITGM

Multiple platforms:

Anything concrete I could help with in here?

For Jest, the failures.test was fixed in jestjs/jest@8c52045. The coverage failure comes from source-map:

Error: You must provide the URL of lib/mappings.wasm by calling SourceMapConsumer.initialize({ 'lib/mappings.wasm': ... }) before using SourceMapConsumer
    at readWasm (/Users/simen/repos/jest/node_modules/v8-to-istanbul/node_modules/source-map/lib/read-wasm.js:8:13)
    at wasm (/Users/simen/repos/jest/node_modules/v8-to-istanbul/node_modules/source-map/lib/wasm.js:25:16)
    at /Users/simen/repos/jest/node_modules/v8-to-istanbul/node_modules/source-map/lib/source-map-consumer.js:264:14
    at V8ToIstanbul.load (/Users/simen/repos/jest/node_modules/v8-to-istanbul/lib/v8-to-istanbul.js:65:26)
    at /Users/simen/repos/jest/packages/jest-reporters/build/CoverageReporter.js:614:11
    at async Promise.all (index 0)
    at CoverageReporter._getCoverageResult (/Users/simen/repos/jest/packages/jest-reporters/build/CoverageReporter.js:572:35)
    at CoverageReporter.onRunComplete (/Users/simen/repos/jest/packages/jest-reporters/build/CoverageReporter.js:220:34)
    at ReporterDispatcher.onRunComplete (/Users/simen/repos/jest/packages/jest-core/build/ReporterDispatcher.js:73:9)
    at TestScheduler.scheduleTests (/Users/simen/repos/jest/packages/jest-core/build/TestScheduler.js:353:5)

or possibly v8-to-istanbul. /cc @bcoe (to reproduce, run yarn && node scripts/build && cd e2e/coverage-provider-v8/no-sourcemap && node ../../../packages/jest/bin/jest.js --coverage-provider v8 --coverage)

For tape, i have no idea how to reproduce that error locally. It shouldn't block node 18 because it's part of dev scripts, but if there's a way i could get a docker image, or ssh into something, and repro it, that would help resolve it.

For tape, i have no idea how to reproduce that error locally. It shouldn't block node 18 because it's part of dev scripts, but if there's a way i could get a docker image, or ssh into something, and repro it, that would help resolve it.

Since these are failing in Jenkins, you can request access to a host by opening an issue in the build repo, similar to nodejs/build#2909. The process is documented at https://github.com/nodejs/build/blob/09308290d8401e15fcd3f7f5c6610a6ea13df75a/GOVERNANCE.md#temporary-access.

FWIW, the remaining test failure in Jest also happens in the test suite of v8-to-istanbul. I'm somewhat surprised c8 still works in the node repo itself - their test suite is also very broken using node 18.

image

EDIT: you probably don't use source maps actually, so doesn't trigger the code path?

@BethGriggs the issue is fetch being a global, it breaks source-map (with more than 160M downloads a week, although the broken v7 has less since it's async only). See https://www.runpkg.com/?source-map@0.7.3/lib/read-wasm.js#1

Same thing happens using node 17 and --experimental-fetch.

npm init -y && npm install --save source-map

// file.mjs
import {SourceMapConsumer} from 'source-map'

await new SourceMapConsumer({version: '3', sources: [], mappings: []})
$ node file.mjs
$ echo $?
0
$ node --experimental-fetch file.mj
(node:21808) ExperimentalWarning: Fetch is an experimental feature. This feature could change at any time
(Use `node --trace-warnings ...` to show where the warning was created)
/Users/simen/repos/source-map-boom/node_modules/source-map/lib/read-wasm.js:8
      throw new Error("You must provide the URL of lib/mappings.wasm by calling " +
            ^

Error: You must provide the URL of lib/mappings.wasm by calling SourceMapConsumer.initialize({ 'lib/mappings.wasm': ... }) before using SourceMapConsumer
    at readWasm (/Users/simen/repos/source-map-boom/node_modules/source-map/lib/read-wasm.js:8:13)
    at wasm (/Users/simen/repos/source-map-boom/node_modules/source-map/lib/wasm.js:25:16)
    at /Users/simen/repos/source-map-boom/node_modules/source-map/lib/source-map-consumer.js:264:14
    at async file:///Users/simen/repos/source-map-boom/file.mjs:3:1

Node.js v17.8.0
$ echo $?
1

I'm confused with this one as we're supposed to already be skipping on AIX and Linux s390x:

citgm/lib/lookup.json

Lines 61 to 65 in 4034fb7

"blake2b-wasm": {
"maintainers": ["mafintosh", "addaleax"],
"prefix": "v",
"skip": ["win32", "aix", "s390"]
},

I'm confused with this one as we're supposed to already be skipping on AIX and Linux s390x:

citgm/lib/lookup.json

Lines 61 to 65 in 4034fb7

"blake2b-wasm": {
"maintainers": ["mafintosh", "addaleax"],
"prefix": "v",
"skip": ["win32", "aix", "s390"]
},

oh we haven't published a new version with #887 🤦 .

oh we haven't published a new version with #887 🤦 .

We have now (v8.0.6) 🙂.

oh we haven't published a new version with #887 🤦 .

We have now (v8.0.6) 🙂.

Please push the release commit.

Please push the release commit.

🤦. Done. (I'd already pushed the tag but forgot to push the main branch.)

I opened up nodejs/node#42638 as I think the breakage of source-map deserves some attention.

@BethGriggs Jest HEAD should be fixed by jestjs/jest@c6902a0. I'll be releasing a new major sometime this month which includes it, but for green CITGM maybe get head instead of latest?

Above was wrong due to nodejs/node#42792. However, jestjs/jest@78d4088 is green on Node 18 for Jest (modulus react-native example, but CITGM skips the examples).

I had it in my head Node 18 would come next week, but I'll try to make a stable release this weekend. HEAD should be green, tho