收藏
回答

请各位大神教我一下怎么处理这个云函数调用失败504002?多谢多谢

【云函数调用失败】 Error: cloud.callFunction:fail Error: errCode: -504002 functions execute fail | errMsg: Error: Cannot find module 'wx-server-sdk'

    at Function.Module._resolveFilename (module.js:538:15)

    at Function.Module._load (module.js:468:25)

    at Module.require (module.js:587:17)

    at require (internal/module.js:11:18)

    at Object.<anonymous> (/var/user/index.js:1:77)

    at Module._compile (module.js:643:30)

    at Object.Module._extensions..js (module.js:654:10)

    at Module.load (module.js:556:32)

    at tryModuleLoad (module.js:499:12)

    at Function.Module._load (module.js:491:3) (callId: 1716785585715-0.14892532009901105) (trace: 12:53:5 start->12:53:6 system error (Error: errCode: -504002 functions execute fail | errMsg: Error: Cannot find module 'wx-server-sdk'

    at Function.Module._resolveFilename (module.js:538:15)

    at Function.Module._load (module.js:468:25)

    at Module.require (module.js:587:17)

    at require (internal/module.js:11:18)

    at Object.<anonymous> (/var/user/index.js:1:77)

    at Module._compile (module.js:643:30)

    at Object.Module._extensions..js (module.js:654:10)

    at Module.load (module.js:556:32)

    at tryModuleLoad (module.js:499:12)

    at Function.Module._load (module.js:491:3)), abort)

_callee4$ @ app.js? [sm]:77

s @ regeneratorRuntime.js:1

(anonymous) @ regeneratorRuntime.js:1

(anonymous) @ regeneratorRuntime.js:1

asyncGeneratorStep @ asyncToGenerator.js:1

i @ asyncToGenerator.js:1

Promise.then (async)

asyncGeneratorStep @ asyncToGenerator.js:1

c @ asyncToGenerator.js:1

Promise.then (async)

asyncGeneratorStep @ asyncToGenerator.js:1

c @ asyncToGenerator.js:1

(anonymous) @ asyncToGenerator.js:1

(anonymous) @ asyncToGenerator.js:1

call @ app.js? [sm]:82

_callee$ @ index.js? [sm]:103

s @ regeneratorRuntime.js:1

(anonymous) @ regeneratorRuntime.js:1

(anonymous) @ regeneratorRuntime.js:1

asyncGeneratorStep @ asyncToGenerator.js:1

c @ asyncToGenerator.js:1

(anonymous) @ asyncToGenerator.js:1

(anonymous) @ asyncToGenerator.js:1

init @ index.js? [sm]:106

onLoad @ index.js? [sm]:97

(anonymous) @ WAServiceMainContext.js:2

Setting data field "status" to undefined is invalid.

_callee$ @ index.js? [sm]:104

s @ regeneratorRuntime.js:1

(anonymous) @ regeneratorRuntime.js:1

(anonymous) @ regeneratorRuntime.js:1

asyncGeneratorStep @ asyncToGenerator.js:1

c @ asyncToGenerator.js:1

Promise.then (async)

asyncGeneratorStep @ asyncToGenerator.js:1

c @ asyncToGenerator.js:1

(anonymous) @ asyncToGenerator.js:1

(anonymous) @ asyncToGenerator.js:1

init @ index.js? [sm]:106

onLoad @ index.js? [sm]:97

(anonymous) @ WAServiceMainContext.js:2

回答关注问题邀请回答
收藏

2 个回答

  • showms
    showms
    05-27

    npm安装一下wx-server-sdk

    05-27
    有用
    回复
  • 跨商通
    跨商通
    05-27

     Cannot find module 'wx-server-sdk'

    05-27
    有用
    回复
登录 后发表内容