comunica / jQuery-Widget.js

🖼 A jQuery widget to query heterogeneous interfaces using Comunica SPARQL
http://query.linkeddatafragments.org/
MIT License
19 stars 34 forks source link

yarn run dev fails: Cannot find module 'webpack-cli/bin/config-yargs' #79

Closed jakubklimek closed 3 years ago

jakubklimek commented 3 years ago

With 6972d0850c6acfc7f8812917267f56d1697b1eb8 I run into this issue when trying to run yarn run dev as instructed:

klimek@KUBA-1:~/jQuery-Widget.js$ node -v
v15.2.1
klimek@KUBA-1:~/jQuery-Widget.js$ npm -v
7.0.8
klimek@KUBA-1:~/jQuery-Widget.js$ yarn install
yarn install v1.22.5
[1/4] Resolving packages...
[2/4] Fetching packages...
info fsevents@1.2.7: The platform "linux" is incompatible with this module.
info "fsevents@1.2.7" is an optional dependency and failed compatibility check. Excluding it from installation.
info idb-connector@1.1.8: The platform "linux" is incompatible with this module.
info "idb-connector@1.1.8" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning "@comunica/actor-init-sparql > @comunica/actor-query-operation-sparql-endpoint@1.18.0" has unmet peer dependency "@comunica/utils-datasource@^1.2.0".
warning "@comunica/actor-init-sparql > @comunica/actor-rdf-resolve-quad-pattern-hypermedia@1.18.0" has unmet peer dependency "@comunica/utils-datasource@^1.0.0".
warning " > @comunica/runner@1.18.0" has unmet peer dependency "@comunica/bus-init@^1.0.0".
warning " > @comunica/runner@1.18.0" has unmet peer dependency "@comunica/core@^1.0.0".
[4/4] Building fresh packages...
$ comunica-compile-config config/config-default.json > comunica-engine.js
Done in 42.30s.
klimek@KUBA-1:~/jQuery-Widget.js$ yarn run dev
yarn run v1.22.5
$ npm run prepare && webpack-dev-server --config webpack.config.js --mode development

> prepare
> comunica-compile-config config/config-default.json > comunica-engine.js

node:internal/modules/cjs/loader:922
  throw err;
  ^

Error: Cannot find module 'webpack-cli/bin/config-yargs'
Require stack:
- /home/klimek/jQuery-Widget.js/node_modules/webpack-dev-server/bin/webpack-dev-server.js
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:919:15)
    at Function.Module._load (node:internal/modules/cjs/loader:763:27)
    at Module.require (node:internal/modules/cjs/loader:991:19)
    at require (node:internal/modules/cjs/helpers:92:18)
    at Object.<anonymous> (/home/klimek/jQuery-Widget.js/node_modules/webpack-dev-server/bin/webpack-dev-server.js:80:1)
    at Module._compile (node:internal/modules/cjs/loader:1102:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1131:10)
    at Module.load (node:internal/modules/cjs/loader:967:32)
    at Function.Module._load (node:internal/modules/cjs/loader:807:14)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:76:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    '/home/klimek/jQuery-Widget.js/node_modules/webpack-dev-server/bin/webpack-dev-server.js'
  ]
}
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
rubensworks commented 3 years ago

Thanks for reporting.

Seems to be caused by webpack-cli assuming webpack 5, but we haven't updated to 5 yet. Looking into #77 should fix this.