首页 > 解决方案 > 为什么我在 nuxtjs 中收到关于 eslint-module 的 Nuxt 致命错误?

问题描述

我正在从事别人拥有的项目。首先,我遇到了 empty_nuxt 错误。我已经通过几个步骤解决了这个问题。但是现在,我遇到了以下错误(我要为你添加图片)我尝试了这种方式:'npm install eslint --save-dev','npm i node-sass-import','./node_modules/ .bin/eslint --init','npm install --save-dev @nuxtjs/eslint-module'。但他们都没有工作。我正在添加错误照片。如果你知道,请帮助我。先感谢您 :)

npm WARN old lockfile 
npm WARN old lockfile The package-lock.json file was created with an old version of npm,
npm WARN old lockfile so supplemental metadata must be fetched from the registry.
npm WARN old lockfile
npm WARN old lockfile This is a one-time fix-up, please be patient...
npm WARN old lockfile
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm WARN deprecated debug@4.2.0: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.2.0: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.2.0: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.2.0: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.2.0: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.2.0: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.2.0: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.2.0: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.2.0: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.2.0: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.2.0: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severityommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated html-webpack-plugin@3.2.0: 3.x is no longer supported
npm WARN deprecated eslint-loader@3.0.3: This loader has been deprecated. Please use eslint-webp
npm WARN deprecated babel-eslint@10.1.0: babel-eslint is now @babel/eslint-parser. This package 
npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use oblematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use oblematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/
npm WARN deprecated mkdirp@0.5.1: Legacy versions of mkdirp are no longer supported. Please upda Promises in 1.x.)
npm WARN deprecated tar@2.2.2: This version of tar is no longer supported, and will not receive 
npm WARN deprecated core-js@2.6.11: core-js@<3.3 is no longer maintained and not recommended forims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing version of core-js.
npm ERR! code 1
npm ERR! path C:\Users\Seda\Desktop\huseyinsavran\node_modules\node-sass
npm ERR! command failed
npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c node scripts/build.js
npm ERR! Building: F:\Programlar\node.exe C:\Users\Seda\Desktop\huseyinsavran\node_modules\node-cflags= --libsass_ldflags= --libsass_library=
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp verb cli [
npm ERR! gyp verb cli   'F:\\Programlar\\node.exe',
npm ERR! gyp verb cli   'C:\\Users\\Seda\\Desktop\\huseyinsavran\\node_modules\\node-gyp\\bin\\n
npm ERR! gyp verb cli   'rebuild',
npm ERR! gyp verb cli   '--verbose',
npm ERR! gyp verb cli   '--libsass_ext=',
npm ERR! gyp verb cli   '--libsass_cflags=',
npm ERR! gyp verb cli   '--libsass_ldflags=',
npm ERR! gyp verb cli   '--libsass_library='
npm ERR! gyp verb cli ]
npm ERR! gyp info using node-gyp@3.8.0
npm ERR! gyp info using node@16.10.0 | win32 | x64
npm ERR! gyp verb command rebuild []
npm ERR! gyp verb command clean []
npm ERR! gyp verb clean removing "build" directory
npm ERR! gyp verb command configure []
npm ERR! gyp verb check python checking for Python executable "python2" in the PATH
npm ERR! gyp verb `which` failed Error: not found: python2
npm ERR! gyp verb `which` failed     at getNotFoundError (C:\Users\Seda\Desktop\huseyinsavran\no
npm ERR! gyp verb `which` failed     at F (C:\Users\Seda\Desktop\huseyinsavran\node_modules\whic
npm ERR! gyp verb `which` failed     at E (C:\Users\Seda\Desktop\huseyinsavran\node_modules\whic
npm ERR! gyp verb `which` failed     at C:\Users\Seda\Desktop\huseyinsavran\node_modules\which\w
npm ERR! gyp verb `which` failed     at C:\Users\Seda\Desktop\huseyinsavran\node_modules\isexe\i
npm ERR! gyp verb `which` failed     at C:\Users\Seda\Desktop\huseyinsavran\node_modules\isexe\w
npm ERR! gyp verb `which` failed     at FSReqCallback.oncomplete (node:fs:198:21)
npm ERR! gyp verb `which` failed  python2 Error: not found: python2
npm ERR! gyp verb `which` failed     at getNotFoundError (C:\Users\Seda\Desktop\huseyinsavran\no
npm ERR! gyp verb `which` failed     at F (C:\Users\Seda\Desktop\huseyinsavran\node_modules\whic
npm ERR! gyp verb `which` failed     at E (C:\Users\Seda\Desktop\huseyinsavran\node_modules\whic
npm ERR! gyp verb `which` failed     at C:\Users\Seda\Desktop\huseyinsavran\node_modules\which\w
npm ERR! gyp verb `which` failed   code: 'ENOENT'                                            e\i
npm ERR! gyp verb `which` failed }                                                           e\w
npm ERR! gyp verb check python checking for Python executable "python" in the PATH
npm ERR! gyp verb `which` succeeded python F:\Anaconda3\python.EXE
npm ERR! gyp ERR! configure error
npm ERR! gyp ERR! stack Error: Command failed: F:\Anaconda3\python.EXE -c import sys; print "%s.%s.%s" % sys.version_info[:3];
npm ERR! gyp ERR! stack   File "<string>", line 1
npm ERR! gyp ERR! stack     import sys; print "%s.%s.%s" % sys.version_info[:3];
npm ERR! gyp ERR! stack                                ^
npm ERR! gyp ERR! stack SyntaxError: invalid syntax
npm ERR! gyp ERR! stack
npm ERR! gyp ERR! stack     at ChildProcess.exithandler (node:child_process:397:12)
npm ERR! gyp ERR! stack     at ChildProcess.emit (node:events:390:28)
npm ERR! gyp ERR! stack     at maybeClose (node:internal/child_process:1064:16)
npm ERR! gyp ERR! stack     at Process.ChildProcess._handle.onexit (node:internal/child_process:301:5)
npm ERR! gyp ERR! System Windows_NT 10.0.19042
npm ERR! gyp ERR! command "F:\\Programlar\\node.exe" "C:\\Users\\Seda\\Desktop\\huseyinsavran\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
npm ERR! gyp ERR! cwd C:\Users\Seda\Desktop\huseyinsavran\node_modules\node-sass
npm ERR! gyp ERR! node -v v16.10.0
npm ERR! gyp ERR! node-gyp -v v3.8.0
npm ERR! gyp ERR! not ok
npm ERR! Build failed with error code: 1

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Seda\AppData\Local\npm-cache\_logs\2021-10-14T21_24_40_991Z-debug.log
PS C:\Users\Seda\Desktop\huseyinsavran>

在此处输入图像描述

标签: vue.jsnuxt.jseslintvuejs3node-sass

解决方案


推荐阅读