java.lang.ClassCastException: com.alibaba.fastjson.JSONObject cannot be cast to java.lang.String

GitHub | Archer456 | 4 months ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    GitHub comment 230#252457397

    GitHub | 4 months ago | Archer456
    java.lang.ClassCastException: com.alibaba.fastjson.JSONObject cannot be cast to java.lang.String

    Root Cause Analysis

    1. java.lang.ClassCastException

      com.alibaba.fastjson.JSONObject cannot be cast to java.lang.String

      at macaca.client.commands.Element.getText()
    2. macaca.client.commands
      Element.getText
      1. macaca.client.commands.Element.getText(Element.java:83)
      1 frame
    3. macaca.client
      MacacaClient.text
      1. macaca.client.MacacaClient.text(MacacaClient.java:934)
      1 frame
    4. uiauto
      H5MobileTest.test_case_1
      1. uiauto.H5MobileTest.test_case_1(H5MobileTest.java:55)
      1 frame