GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — 企微接收客户标签变更事件序列化成Bean异常 · Issue #2137 · binarywang/WxJava

企微接收客户标签变更事件序列化成Bean异常 #2137

New issue
Copy link
New issue
Copy link
Closed
Closed
企微接收客户标签变更事件序列化成Bean异常#2137
Copy link
Milestone
4.1.0

Description

@lixiaojie09
lixiaojie09
opened on May 28, 2021
Issue body actions

简要描述

接收客户标签变更事件时,
<xml> <SuiteId> <![CDATA[ww122cacf30fe7f949]]> </SuiteId> <AuthCorpId> <![CDATA[ww673a375b380d45e0]]> </AuthCorpId> <InfoType> <![CDATA[change_external_tag]]> </InfoType> <TimeStamp>1622182830</TimeStamp> <ChangeType> <![CDATA[update]]> </ChangeType> <Id> <![CDATA[etEsNADQAAaiB0cWCSDFiJ2qCap-ww9A]]> </Id> <TagType> <![CDATA[tag]]> </TagType> </xml>
使用代码 WxCpTpXmlMessage.fromXml(decryptXml) 转成 WxCpTpXmlMessage 出错。

模块版本情况

  • WxJava 模块名: weixin-java-cp
  • WxJava 版本号: 4.0.8.B

详细描述

CoversionException日志
---- Debugging information ----
cause-exception : java.lang.NumberFormatException
cause-message : For input string: "etEsNADQAAaiB0cWCSDFiJ2qCap-ww2b"
class : java.lang.Integer
required-type : java.lang.Integer
converter-type : com.thoughtworks.xstream.converters.SingleValueConverterWrapper
wrapped-converter : com.thoughtworks.xstream.converters.basic.IntConverter
line number : 1
class[1] : me.chanjar.weixin.cp.bean.message.WxCpTpXmlMessage
required-type[1] : me.chanjar.weixin.cp.bean.message.WxCpTpXmlMessage
converter-type[1] : com.thoughtworks.xstream.converters.reflection.ReflectionConverter
version : not available

Activity

  1. binarywang commented on May 30, 2021

    @binarywang
    binarywang
    on May 30, 2021
    Owner
    More actions

    看来是id类型不匹配,应该改为String

    cause-message : For input string: "etEsNADQAAaiB0cWCSDFiJ2qCap-ww2b"

  2. binarywang
    added this to the 4.1.0 milestone on May 30, 2021
  3. binarywang
    added a commit that references this issue on May 30, 2021

    🎨 #2137 【企业微信】消息类里的Id修改为String以兼容字符串类型

    99bc87d
  4. lixiaojie09 commented on May 30, 2021

    @lixiaojie09
    lixiaojie09
    on May 30, 2021
    Author
    More actions

    是的,确实是id是整型所引起的。但我不确定更改为String类型后,是否会影响到原有整形xml信息的convert。例如部门的XML消息。https://work.weixin.qq.com/api/doc/90001/90143/90640

  5. binarywang commented on May 30, 2021

    @binarywang
    binarywang
    on May 30, 2021
    Owner
    More actions

    单元测试跑下就知道了,没问题,已试过

  6. binarywang
    added a commit that references this issue on May 30, 2021

    🎨 #2137 【企业微信】消息类里的Id修改为String以兼容字符串类型

    8f73c40
  7. lixiaojie09 commented on May 30, 2021

    @lixiaojie09
    lixiaojie09
    on May 30, 2021
    Author
    More actions

    ok! thk~

  8. binarywang
    closed this as completedon Jun 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      • 4.1.0

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.