webrtc / samples

WebRTC Web demos and samples
https://webrtc.github.io/samples
BSD 3-Clause "New" or "Revised" License
13.94k stars 5.71k forks source link

Cannot find module travis-multirunner@4.6.0 #1568

Closed kuchaguangjie closed 2 years ago

kuchaguangjie commented 2 years ago

After clone the code, and run pnpm i, get error:

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Progress: resolved 403, reused 388, downloaded 0, added 0, done
node_modules/.pnpm/registry.npmmirror.com+geckodriver@3.0.2/node_modules/geckodriver: Running postinstall script...
node_modules/.pnpm/registry.npmmirror.com+travis-multirunner@4.6.0/node_modules/travis-multirunner: Running postinstall script, failed in 69ms
.../node_modules/travis-multirunner postinstall$ node bin/travis-sync
│ node:internal/modules/cjs/loader:936
│   throw err;
│   ^
│ Error: Cannot find module '/mnt/mars/git_repository/webrtc/samples/node_modules/.pnpm/registry.npmmirror.com+travis-multirunner@4.6.0
│ Require stack:
│ - /mnt/mars/git_repository/webrtc/samples/node_modules/.pnpm/registry.npmmirror.com+travis-multirunner@4.6.0/node_modules/travis-mult
│     at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
│     at Function.Module._load (node:internal/modules/cjs/loader:778:27)
│     at Module.require (node:internal/modules/cjs/loader:1005:19)
│     at require (node:internal/modules/cjs/helpers:102:18)
│     at Object.<anonymous> (/mnt/mars/git_repository/webrtc/samples/node_modules/.pnpm/registry.npmmirror.com+travis-multirunner@4.6.0
│     at Module._compile (node:internal/modules/cjs/loader:1101:14)
│     at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
│     at Module.load (node:internal/modules/cjs/loader:981:32)
│     at Function.Module._load (node:internal/modules/cjs/loader:822:12)
│     at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12) {
│   code: 'MODULE_NOT_FOUND',
│   requireStack: [
│     '/mnt/mars/git_repository/webrtc/samples/node_modules/.pnpm/registry.npmmirror.com+travis-multirunner@4.6.0/node_modules/travis-m
│   ]
│ }
└─ Failed in 70ms
 ELIFECYCLE  Command failed with exit code 1.

Then I try to install travis-multirunner via:

pnpm add travis-multirunner

And, get error:

node_modules/.pnpm/registry.npmmirror.com+travis-multirunner@4.6.0/node_modules/travis-multirunner: Running postinstall script, failed in 71ms
.../node_modules/travis-multirunner postinstall$ node bin/travis-sync
│ node:internal/modules/cjs/loader:936
│   throw err;
│   ^
│ Error: Cannot find module '/mnt/mars/git_repository/webrtc/samples/node_modules/.pnpm/registry.npmmirror.com+travis-multirunner@4.6.0/package.json'
│ Require stack:
│ - /mnt/mars/git_repository/webrtc/samples/node_modules/.pnpm/registry.npmmirror.com+travis-multirunner@4.6.0/node_modules/travis-multirunner/bin/travis-sync
│     at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
│     at Function.Module._load (node:internal/modules/cjs/loader:778:27)
│     at Module.require (node:internal/modules/cjs/loader:1005:19)
│     at require (node:internal/modules/cjs/helpers:102:18)
│     at Object.<anonymous> (/mnt/mars/git_repository/webrtc/samples/node_modules/.pnpm/registry.npmmirror.com+travis-multirunner@4.6.0/node_modules/travis-multirunner/bin/travis-sync:15:1
│     at Module._compile (node:internal/modules/cjs/loader:1101:14)
│     at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
│     at Module.load (node:internal/modules/cjs/loader:981:32)
│     at Function.Module._load (node:internal/modules/cjs/loader:822:12)
│     at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12) {
│   code: 'MODULE_NOT_FOUND',
│   requireStack: [
│     '/mnt/mars/git_repository/webrtc/samples/node_modules/.pnpm/registry.npmmirror.com+travis-multirunner@4.6.0/node_modules/travis-multirunner/bin/travis-sync'
│   ]
│ }
└─ Failed in 72ms
 ELIFECYCLE  Command failed with exit code 1.

Did the project use some very old npm dependency ? Any idea how to fix that?

alvestrand commented 2 years ago

I have not tried to build samples with pnpm. Have you tried building it with npm?

hthetiot commented 2 years ago

Using npm 8.13.2 works for me, this only occurs using pnpm that is not the official package manager for NodeJS and it works with yarn anyway.

You could at least add "using pnpm" in the issue title, but to be fair, this is not this project fault and I dont think you should bother the maintainer for that if that works using more mainstream NodeJs package manager.

fippo commented 2 years ago

not an issue we can solve