简体   繁体   English

(插件汇总核心)错误:无法加载/Users/Naseem/AppData/Roaming/npm/node_modules/wpe-lightning-cli/src/alias/wpe-lightning.js

[英](plugin Rollup Core) Error: Could not load /Users/Naseem/AppData/Roaming/npm/node_modules/wpe-lightning-cli/src/alias/wpe-lightning.js

How can I fix this issue?我该如何解决这个问题?

$ lng build

√ Removing "E:\workspace\xxx\xxx\build" folder

√ Ensuring "E:\workspace\xxx\xxx\build" folder exists

√ Copying support files to "E:\workspace\xxx\xxx\build"

- Copying static assets to "E:\workspace\xxx\xxx\build"cp: no such file or directory: ./static
√ Copying static assets to "E:\workspace\xxx\xxx\build"

√ Copying settings.json to "E:\workspace\xxx\xxx\build"

√ Copying metadata.json to "E:\workspace\xxx\xxx\build"

× Error while creating ES6 bundle (see log)


E:\workspace\xxx\xxx\src\index.js → build\appBundle.js...
[!] (plugin Rollup Core) Error: Could not load /Users/Naseem/AppData/Roaming/npm/node_modules/wpe-lightning-cli/src/alias/wpe-lightning.js (imported by E:\workspace\xxx\xxx\node_modules\wpe-lightning-sdk\src\Lightning\index.js): ENOENT: no such file or directory, open 'E:\Users\Naseem\AppData\Roaming\npm\node_modules\wpe-lightning-cli\src\alias\wpe-lightning.js'
Error: Could not load /Users/Naseem/AppData/Roaming/npm/node_modules/wpe-lightning-cli/src/alias/wpe-lightning.js (imported by E:\workspace\xxx\xxx\node_modules\wpe-lightning-sdk\src\Lightning\index.js): ENOENT: no such file or directory, open 'E:\Users\Naseem\AppData\Roaming\npm\node_modules\wpe-lightning-cli\src\alias\wpe-lightning.js'

(node:7472) UnhandledPromiseRejectionWarning: Error: Error: Command failed with exit code 1: C:\Users\Naseem\AppData\Roaming\npm\node_modules\wpe-lightning-cli\node_modules\.bin\rollup -c C:\Users\Naseem\AppData\Roaming\npm\node_modules\wpe-lightning-cli\src\configs\rollup.es6.config.js --input E:\workspace\xxx\xxx\src\index.js
--file E:\workspace\xxx\xxx\build\appBundle.js --name APP_com_epam_lgi
    at execa.then.catch.e (C:\Users\Naseem\AppData\Roaming\npm\node_modules\wpe-lightning-cli\src\helpers\build.js:150:13)
    at process._tickCallback (internal/process/next_tick.js:68:7)
(node:7472) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 3)
(node:7472) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.


using npm -v > 6.13.4
using node -v > v10.19.0

I managed to work around this problem by relocating the workspace to the same drive (from D: to C: in my case).我设法通过将工作区重新定位到同一个驱动器来解决这个问题(在我的情况下,从 D: 到 C:)。

Before:前:


   D:\work\myproj\com.work.Test\src\index.js → build\appBundle.js...
    [!] (plugin Rollup Core) Error: Could not load /Users/myuser/AppData/Roaming/npm/node_modules/wpe-lightning-cli/src/alias/wpe-lightning.js (imported by D:\work\myproj\com.work.Test\node_modules\wpe-lightning-sdk\src\Lightning\index.js): ENOENT: no such file or directory, open 'D:\Users\myuser\AppData\Roaming\npm\node_modules\wpe-lightning-cli\src\alias\wpe-lightning.js'
    Error: Could not load /Users/myuser/AppData/Roaming/npm/node_modules/wpe-lightning-cli/src/alias/wpe-lightning.js (imported by D:\work\myproj\com.work.Test\node_modules\wpe-lightning-sdk\src\Lightning\index.js): ENOENT: no such file or directory, open 'D:\Users\myuser\AppData\Roaming\npm\node_modules\wpe-lightning-cli\src\alias\wpe-lightning.js'
    
    (node:28464) UnhandledPromiseRejectionWarning: Error: Error: Command failed with exit code 1: C:\Users\myuser\AppData\Roaming\npm\node_modules\wpe-lightning-cli\node_modules\.bin\rollup -c C:\Users\myuser\AppData\Roaming\npm\node_modules\wpe-lightning-cli\src\configs\rollup.es6.config.js --input D:\work\myproj\com.work.Test\src\index.js --file D:\work\myproj\com.work.Test\build\appBundle.js --name APP_com_work_Test
    at C:\Users\myuser\AppData\Roaming\npm\node_modules\wpe-lightning-cli\src\helpers\build.js:150:13
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
    (node:28464) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 3)
    (node:28464) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

After:后:


    C:\work\proj\com.work.Test>lng build
    √ Testing internet connection..
    √ Verifying if your installation of Lightning-CLI is up to date.
    √ Removing "C:\work\proj\com.work.Test\build" folder
    √ Ensuring "C:\work\proj\com.work.Test\build" folder exists
    √ Copying support files to "C:\work\proj\com.work.Test\build"
    √ Copying static assets to "C:\work\proj\com.work.Test\build"
    √ Copying settings.json to "C:\work\proj\com.work.Test\build"
    √ Copying metadata.json to "C:\work\proj\com.work.Test\build"
    √ Building ES6 appBundle and saving to "C:\work\proj\com.work.Test\build"

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 错误:找不到模块“C:\Users\senyo\AppData\Roaming\npm\node_modules\expo-cli\bin\expo.js” - Error: Cannot find module 'C:\Users\senyo\AppData\Roaming\npm\node_modules\expo-cli\bin\expo.js' 错误:找不到模块 'C:\Users\nguye\AppData\Local\nodejs\node_modules\npm\bin\npm-cli.js' - Error: Cannot find module 'C:\Users\nguye\AppData\Local\nodejs\node_modules\npm\bin\npm-cli.js' 找不到模块:错误:无法解析“D:\GitHub\project”中的“./C:/Users/user/AppData/Roaming/npm/node_modules/next/dist/client/next.js” - Module not found: Error: Can't resolve './C:/Users/user/AppData/Roaming/npm/node_modules/next/dist/client/next.js' in 'D:\GitHub\project' 错误:ENOENT:没有这样的文件或目录,打开'C:\\ Users \\ Dylan \\ AppData \\ Roaming \\ npm \\ node_modules \\ n_ \\ lodash-3。*。tgz' - Error: ENOENT: no such file or directory, open 'C:\Users\Dylan\AppData\Roaming\npm\node_modules\n_\lodash-3.*.tgz' Node.js/Windows 错误:ENOENT,stat 'C:\\Users\\RT\\AppData\\Roaming\\npm' - Node.js/Windows error: ENOENT, stat 'C:\Users\RT\AppData\Roaming\npm' 错误:ENOENT,状态为“ C:\\ Users \\ Ali \\ AppData \\ Roaming \\ npm” - Error: ENOENT, stat 'C:\Users\Ali\AppData\Roaming\npm' 错误:尝试运行 npm 时找不到模块“C:\Program Files\nodejs\node_modules\npm\bin\node_modules\npm\bin\npm-cli.js” - Error: Cannot find module 'C:\Program Files\nodejs\node_modules\npm\bin\node_modules\npm\bin\npm-cli.js' when trying to run npm npm ERR:错误:EACCES,权限被拒绝。 访问'/Users/patrikkozak/.npm-global/lib/node_modules/@vue/cli' - npm ERR! Error: EACCES: permission denied, access '/Users/patrikkozak/.npm-global/lib/node_modules/@vue/cli' 找不到模块 'C:\\node_modules\\npm\\bin\\npm-cli.js - Cannot find module 'C:\node_modules\npm\bin\npm-cli.js 错误:EINVAL:无效参数,mkdir 'C:\Users\user\'C:\Users\User\AppData\Roaming\npm - Error: EINVAL: invalid argument, mkdir 'C:\Users\user\'C:\Users\User\AppData\Roaming\npm
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM