[BUG]使用jsonpath能力,解析类似($.pCvr)时,会取不到数据
- Dominant language
- Java
- Stars
- 4.4k
- Forks
- 613
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 6
Description
### 问题描述
使用jsonpath能力,解析类似($.pCvr)时,会取不到数据,但是使用fastjson就可以正常解析到数据
### 环境信息
- OS信息:11th Gen Intel(R) Core(TM) i7-1165G7 @ 2.80GHz 2.80 GHz
- JDK信息: Openjdk 1.8.0262
- 版本信息:Fastjson2 2.0.51
### 重现步骤
*如何操作可以重现该问题:*
1. 使用 com.alibaba.fastjson2.JSONPath#eval(java.lang.Object, java.lang.String)方法
2. 输入:source为pb结构的数据, path为 $.pCvr
3. 解析为null,但是使用fastjson是可以正常解析的
```java
Object value = com.alibaba.fastjson2.JSONPath.eval(source, fieldPath);
```
Contributor guide
Research direction
Start with com.alibaba.fastjson2.JSONPath#eval(Object, String) and reproduce the report using the protobuf-backed source and path $.pCvr. Compare its result with fastjson; done means the JSONPath lookup returns the expected pCvr value instead of null for the reported input.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100