Vue-cli: npm run build failed

Created on 2 Aug 2019  Â·  6Comments  Â·  Source: vuejs/vue-cli

Version

3.9.3

Reproduction link

https://github.com/DesarrollosAMCH/conquiseven

Environment info

System:
    OS: Linux 4.15 Ubuntu 18.04.1 LTS (Bionic Beaver)
    CPU: (1) x64 Intel(R) Xeon(R) CPU E5-2650 v4 @ 2.20GHz
  Binaries:
    Node: 8.11.4 - /usr/bin/node
    Yarn: 1.9.4 - /usr/bin/yarn
    npm: 5.6.0 - /usr/bin/npm
  Browsers:
    Chrome: Not Found
    Firefox: Not Found
  npmGlobalPackages:
    @vue/cli: 3.9.3

Steps to reproduce

npm install
npm run build

What is expected?

make build to deploy project on porduction server

What is actually happening?

npm run build

â ¹ Building for production...

ERROR Failed to compile with 36 errors 11:32:59

These dependencies were not found:

  • core-js/modules/es6.array.find in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Tables/UnidadesEvaluadasTable.vue?vue&type=script&lang=js&, ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/pages/admin/UnidadesPage.vue?vue&type=script&lang=js&
  • core-js/modules/es6.array.find-index in ./src/components/NotificationPlugin/index.js, ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Tables/UnidadesEvaluadasTable.vue?vue&type=script&lang=js&
  • core-js/modules/es6.function.name in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Cards/Card.vue?vue&type=script&lang=js&, ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Tables/ClubesTable.vue?vue&type=script&lang=js& and 9 others
  • core-js/modules/es6.number.constructor in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/NotificationPlugin/Notification.vue?vue&type=script&lang=js&, ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Tables/UnidadesEvaluadasTable.vue?vue&type=script&lang=js& and 1 other
  • core-js/modules/es6.regexp.replace in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/pages/admin/EventosDetallePage.vue?vue&type=script&lang=js&
  • core-js/modules/es6.regexp.search in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/pages/app/EvaluarActividadPage.vue?vue&type=script&lang=js&
  • core-js/modules/es6.regexp.to-string in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Cards/ChartCard.vue?vue&type=script&lang=js&
  • core-js/modules/web.dom.iterable in ./src/components/NotificationPlugin/index.js, ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Tables/EventosTable.vue?vue&type=script&lang=js& and 13 others

To install them, you can run: npm install --save core-js/modules/es6.array.find core-js/modules/es6.array.find-index core-js/modules/es6.function.name core-js/modules/es6.number.constructor core-js/modules/es6.regexp.replace core-js/modules/es6.regexp.search core-js/modules/es6.regexp.to-string core-js/modules/web.dom.iterable
ERROR Build failed with errors.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] build: vue-cli-service build
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /home/forge/.npm/_logs/2019-08-02T11_32_59_427Z-debug.log


i tried execute the command that vue-cli recomends:

npm install --save core-js/modules/es6.array.find core-js/modules/es6.array.find-index core-js/modules/es6.function.name core-js/modules/es6.number.constructor core-js/modules/es6.regexp.replace core-js/modules/es6.regexp.search core-js/modules/es6.regexp.to-string core-js/modules/web.dom.iterable

but this was response:

npm ERR! code ENOLOCAL
npm ERR! Could not install from "core-js/modules/es6.array.find" as it does not contain a package.json file.

npm ERR! A complete log of this run can be found in:
npm ERR! /home/forge/.npm/_logs/2019-08-02T11_37_00_531Z-debug.log

Most helpful comment

sorry, i tried npm install --save core-js@2 and the errors are still there

All 6 comments

npm install --save core-js@2

Sorry for the inconvenience.
It was a mistake that the old default preset didn't include this dependency by default.
We'll try to provide a more comprehensible error output.

SOLVED!

Thank you very much!

npm install --save core-js@2

Sorry for the inconvenience.
It was a mistake that the old default preset didn't include this dependency by default.
We'll try to provide a more comprehensible error output.

thanks.

sorry, i tried npm install --save core-js@2 and the errors are still there

Same issue and installing core-js 2 to solve a problem from running version 3 is not a good solution. Core-js 2.6.11 is deprecated and therefore is not a good solution when I'am trying to use current libraries.

I got it to work by building a new app and using the version definitions of the new app build.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

wahidrahim picture wahidrahim  Â·  3Comments

Gonzalo2683 picture Gonzalo2683  Â·  3Comments

brandon93s picture brandon93s  Â·  3Comments

Benzenes picture Benzenes  Â·  3Comments

jgribonvald picture jgribonvald  Â·  3Comments