gpt4 book ai didi

node.js - gulp 包任务 -ReferenceError : primordials is not defined

转载 作者:太空宇宙 更新时间:2023-11-04 03:14:24 27 4
gpt4 key购买 nike

团队,

我的 Ci Pipeline azure 失败,发现错误如下。我已经尝试过 How to fix ReferenceError: primordials is not defined in node 的解决方案但没有运气

以下错误:

##[section]Starting: gulp Package-Generate
==============================================================================
Task : Gulp
Description : Node.js streaming task based build system
Version : 0.141.2
Author : Microsoft Corporation
Help : [More Information](https://go.microsoft.com/fwlink/?LinkID=613721)
==============================================================================
[command]C:\npm\prefix\gulp.cmd Package-Generate --gulpfile d:\a\1\s\gulpfile.js --configuration release
fs.js:27
const { Math, Object } = primordials;
^

ReferenceError: primordials is not defined
at fs.js:27:26
at req_ (d:\a\1\s\node_modules\natives\index.js:143:24)
at Object.req [as require] (d:\a\1\s\node_modules\natives\index.js:55:10)
at Object.<anonymous> (d:\a\1\s\node_modules\graceful-fs\fs.js:1:37)
at Module._compile (internal/modules/cjs/loader.js:956:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:973:10)
at Module.load (internal/modules/cjs/loader.js:812:32)
at Function.Module._load (internal/modules/cjs/loader.js:724:14)
at Module.require (internal/modules/cjs/loader.js:849:19)
at require (internal/modules/cjs/helpers.js:74:18)
##[error]Gulp failed with error: C:\npm\prefix\gulp.cmd failed with return code: 1
##[section]Finishing: gulp Package-Generate

最佳答案

我在使用 Gulp 3.9.1NodeJS 12.14.0 时收到此错误。

我已经解决了卸载 NodeJS 12.14.0 和安装 NodeJS 10.13.0 版本的问题。

然后一切正常。

关于node.js - gulp 包任务 -ReferenceError : primordials is not defined,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58856370/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com