Build Failed: TypeError: Cannot convert undefined or null to object
TypeError: Cannot read property ‘getParameter’ of null
TypeError: Cannot read property ‘getParameter’ of null
macOS 10.13.6版本。
没逐个打包,基本的web和wx都是报这个错,无法build。
预览运行都是好的。
Build Failed: TypeError: Cannot convert undefined or null to object
TypeError: Cannot read property ‘getParameter’ of null
TypeError: Cannot read property ‘getParameter’ of null
macOS 10.13.6版本。
没逐个打包,基本的web和wx都是报这个错,无法build。
预览运行都是好的。
完整日志看看,我们这边没有复现这个问题。
Build Failed: TypeError: Cannot convert undefined or null to object
at Function.keys ()
at module.exports.getAssetUuids (/Applications/CocosCreator.app/Contents/Resources/app.asar/editor/core/build-results.js:1:461)
at Gulp. (/Applications/CocosCreator.app/Contents/Resources/app.asar/editor/core/gulp-build.js:1:9950)
at module.exports (/Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/orchestrator/lib/runTask.js:34:7)
at Gulp.Orchestrator._runTask (/Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:273:3)
at Gulp.Orchestrator._runStep (/Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:214:10)
at /Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:279:18
at finish (/Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/orchestrator/lib/runTask.js:21:8)
at cb (/Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/orchestrator/lib/runTask.js:29:3)
at BrowserWindow. (/Applications/CocosCreator.app/Contents/Resources/app.asar/editor/core/gulp-build.js:1:9030)
at r.waterfall.r (/Applications/CocosCreator.app/Contents/Resources/app.asar/editor/lib/builder/index.js:1:3393)
at /Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:52:16
at /Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:696:30
at /Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:167:37
at /Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:1209:30
at Gulp.doneCallback (/Applications/CocosCreator.app/Contents/Resources/app.asar/editor/core/gulp-build.js:1:27675)
at Gulp.Orchestrator.stop (/Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:150:9)
at /Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:277:22
at finish (/Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/orchestrator/lib/runTask.js:21:8)
TypeError: Cannot read property ‘getParameter’ of null
at Device._initCaps (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/renderer/render-engine.js:5051:46)
at new Device (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/renderer/render-engine.js:5009:18)
at Object.initWebGL (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/renderer/index.js:54:35)
at Object._initRenderer (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/CCGame.js:361:30)
at Object._initEngine (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/CCGame.js:112:22)
at Object._prepareFinished (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/CCGame.js:123:22)
at Object.prepare (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/CCGame.js:162:26)
at Object.run (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/CCGame.js:168:22)
at /Applications/CocosCreator.app/Contents/Resources/app.asar/editor/page/build/build-worker.js:1:1623
at fn (/Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:746:34)
at EventEmitter.i (/Applications/CocosCreator.app/Contents/Resources/app.asar/editor/core/gulp-build.js:1:8692)
at Object.onceWrapper (events.js:293:19)
at emitTwo (events.js:106:13)
at EventEmitter.emit (events.js:194:7)
at WebContents. (/Applications/CocosCreator.app/Contents/Resources/electron.asar/browser/api/web-contents.js:247:13)
at emitTwo (events.js:106:13)
at WebContents.emit (events.js:194:7)
TypeError: Cannot read property ‘getParameter’ of null
at Device._initCaps (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/renderer/render-engine.js:5051:46)
at new Device (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/renderer/render-engine.js:5009:18)
at Object.initWebGL (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/renderer/index.js:54:35)
at Object._initRenderer (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/CCGame.js:361:30)
at Object._initEngine (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/CCGame.js:112:22)
at Object._prepareFinished (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/CCGame.js:123:22)
at Object.prepare (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/CCGame.js:162:26)
at Object.run (/Applications/CocosCreator.app/Contents/Resources/engine/bin/.cache/dev/cocos2d/core/CCGame.js:168:22)
at /Applications/CocosCreator.app/Contents/Resources/app.asar/editor/page/build/build-worker.js:1:1623
at fn (/Applications/CocosCreator.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:746:34)
大概是这样的:
1新安装creator后build成功。
2然后我关闭creator后,再build就都失败了。
3需要我删除所有creator软件相关的文件后再安装
4回到1
能看下怎么解决这个问题呢?
每次打包都不行。
不知道你的webgl为什么报错,重新安装下显卡驱动试试。
同样的问题,研究半天,不知道怎么解决,系统 mac os high sierra 10.13.6, cocoscreater 2.0.9
现象是,打开构建发布窗口前,场景编辑器的节点图像都是好的,,打开构建发布窗口后,场景编辑器的图片就消失看不见了,,点构建就失败,报错和楼主一样。
打开任何一个 editor window ,都会导致场景编辑器的图像消失
我升级到2.1.0了,暂没出现问题
好的,试试看。
2.1.0又开始报这个错了,重启重装删工程都没用。
是的,2.1.0也不行
mac os系统,显卡驱动应该是好的,,不是windows。
我现在的解决办法是,出现错误把除assets和project.json外的文件全删了,重启电脑和creator
这个方法,我这边还是不行。
这个问题非常奇葩,搞得我们整个项目都快完蛋了,官方的快来看看吧。
我是从1.10升级上来的,升级上来后,修复了些api,在开发模式下运行完美。一旦构建就报错,报的错千奇百怪。但是可以确定的是,在构建过程中cocos creator运行了项目的代码,而因为环境缺少一些变量导致构建出错,出错的地方是quick-scripts里面的脚本。
然而当我把temp目录删除后,再构建就能成功,但是代码却运行不起来,场景加载好后就停止在那里了。
[4329] Error: Build Failed: TypeError: Cannot convert undefined or null to object
at Function.keys ()
at module.exports.getAssetUuids (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/core/build-results.js:1:461)
at Gulp. (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/core/gulp-build.js:1:10011)
at module.exports (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/lib/runTask.js:34:7)
at Gulp.Orchestrator._runTask (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:273:3)
at Gulp.Orchestrator._runStep (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:214:10)
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:279:18
at finish (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/lib/runTask.js:21:8)
at cb (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/lib/runTask.js:29:3)
at BrowserWindow. (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/core/gulp-build.js:1:9090)
at r.waterfall.r (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/lib/builder/index.js:1:3393)
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:52:16
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:696:30
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:167:37
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:1209:30
at Gulp.doneCallback (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/core/gulp-build.js:1:29044)
at Gulp.Orchestrator.stop (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:150:9)
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:277:22
at finish (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/lib/runTask.js:21:8)
[ error [========================================] 100% 0.0s ]
[4329] Error: TypeError: Cannot convert undefined or null to object
at Function.keys ()
at module.exports.getAssetUuids (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/core/build-results.js:1:461)
at Gulp. (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/core/gulp-build.js:1:10011)
at module.exports (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/lib/runTask.js:34:7)
at Gulp.Orchestrator._runTask (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:273:3)
at Gulp.Orchestrator._runStep (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:214:10)
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/index.js:279:18
at finish (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/lib/runTask.js:21:8)
at cb (/Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/orchestrator/lib/runTask.js:29:3)
at BrowserWindow. (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/core/gulp-build.js:1:9090)
at Editor.Builder.buildCommand.e (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/index.js:1:1677)
at r.series.e (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/lib/builder/index.js:1:4648)
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:726:13
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:52:16
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:264:21
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:44:16
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:723:17
at /Applications/CocosCreator2.app/Contents/Resources/app.asar/node_modules/async/lib/async.js:167:37
at r.waterfall.r (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/lib/builder/index.js:1:3778)
[4329] Error: Error: no_user_info
at /Users/skxtay/Work/cocos/BlackJack/temp/quick-scripts/assets/Script/Module/http.js:26:31
at
at EventEmitter.i (/Applications/CocosCreator2.app/Contents/Resources/app.asar/editor/core/gulp-build.js:1:8752)
at Object.onceWrapper (events.js:293:19)
at emitTwo (events.js:106:13)
at EventEmitter.emit (events.js:194:7)
at WebContents. (/Applications/CocosCreator2.app/Contents/Resources/electron.asar/browser/api/web-contents.js:247:13)
at emitTwo (events.js:106:13)
at WebContents.emit (events.js:194:7)
no_user_info是后端返回的,因为构建的时候没有cookie呀,
/Applications/CocosCreator2.app/Contents/Resources/electron.asar/browser/api/web-contents.js
还有这个脚本是搞什么的?是从这里发起的
解决了吗,我也遇到这个问题了