收藏
回答

wx.notifyGroupMembers 在正式版报错?

问题:wx.notifyGroupMembers 在正式版报错 undefined is not an object,体验版正常

代码片段:wx.notifyGroupMembers({
  title: '高低甩两杆兄弟们',
  members: ['AM29gde0L0z9FeRbqnREX7MbUAJS0GgaGPawjvqkNKaHFA0Jsw'],
  entrancePath: '/packageChatTool/pages/landing/index?id=xxx',
  type: 'complete',
  success: (res) => console.log('success', res),
  fail: (err) => console.log('fail', err)
});

问题描述:
使用聊天工具模式(chatTool)开发小程序,调用 wx.notifyGroupMembers API。

环境信息:
- 基础库版本:3.7.8
- 独立分包,使用 Skyline 渲染器

问题现象:
1. 在开发者工具和体验版中,wx.notifyGroupMembers 调用正常,返回 success
2. 发布到正式版后,同样的代码报错:notifyGroupMembers:fail undefined is not an object

已排查:
- 所有参数都已验证不为 undefined
- members 数组是有效的字符串数组(从 wx.selectGroupMembers 获取)
- title、entrancePath、type 都是有效字符串
- API 可用性检查通过(typeof wx.notifyGroupMembers === 'function')

请问这是 API 在正式版中的已知问题吗?或者有什么特殊限制?


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

2 个回答

  • 李三刚
    李三刚
    04-22

    如果报错: notifyGroupMembers:fail undefined is not an object (evaluating 'e.split')" 

    八成是因为entrancePath路径前加了斜杠/,去掉就行了



    04-22
    有用
    回复
  • 智能回答 智能回答 本次回答由AI生成
    01-28
    有用
登录 后发表内容