-
Notifications
You must be signed in to change notification settings - Fork 60
Description
Describe the bug
Cannot deserialize value of type
java.lang.Stringfrom Object value (tokenJsonToken.START_OBJECT)
at [Source: REDACTED (StreamReadFeature.INCLUDE_SOURCE_IN_LOCATION disabled); line: 2, column: 11] (through reference chain: com.atlassian.jira.issue.fields.rest.json.beans.CommentJsonBean["body"])
To Reproduce
Steps to reproduce the behavior:
Open a Jira Issue in VSC, post a comment with a similar body to this one and see the error output
please submit a PR with your requested updates.
<some url>
if the response is meant to return a url, please use the {color:red}{{links}}{color} collection with the {color:red}{{linkType_v01.json}}{color} common component.
{code:json}
{
"links": {
"type": "array",
"items": { "$ref": "../../../../common/linkType_v01.json" }
}
}
{code}
---
sample response payload
{code:json}
{
"links": [
{
"linkID": "1",
"href": "<link>",
"method": "GET",
"mediaType": "application/json",
"rel": "self"
}
]
}
{code}
curl to recreate the error
curl -X POST "https://<jira-domain>com/rest/api/2/issue/<issue-id>/comment?expand=renderedBody" -H "Accept:application/json, text/plain, */*" -H "Content-Type:application/json" -H "User-Agent:atlascode/2.x axios/0.19.2" -H "X-Atlassian-Token:no-check" -H "Authorization:Bearer <token>" --data '{"body":{"type":"doc","content":[{"type":"paragraph","content":[{"type":"text","text":"please submit a PR with your requested updates. "},{"type":"hardBreak","attrs":{"text":"\n"}},{"type":"text","marks":[{"type":"link","attrs":{"href":"https://<internal link>"}]},{"type":"paragraph","content":[{"type":"text","text":"if the response is meant to return a url, please use the "},{"type":"text","marks":[{"type":"code"}],"text":"links"},{"type":"text","text":" collection with the "},{"type":"text","marks":[{"type":"code"}],"text":"linkType_v01.json"},{"type":"text","text":" common component. "}]},{"type":"codeBlock","attrs":{"language":"json"},"content":[{"type":"text","text":"{\n \"links\": {\n \"type\": \"array\",\n \"items\": {\n \"$ref\": \"../../../../common/linkType_v01.json\"\n }\n }\n}"}]},{"type":"paragraph","content":[{"type":"text","text":"—"}]},{"type":"orderedList","attrs":{"order":1},"content":[{"type":"listItem","content":[{"type":"paragraph"},{"type":"orderedList","attrs":{"order":1},"content":[{"type":"listItem","content":[{"type":"paragraph"},{"type":"orderedList","attrs":{"order":1},"content":[{"type":"listItem","content":[{"type":"paragraph","content":[{"type":"text","text":"sample response payload"}]}]}]}]}]}]}]},{"type":"codeBlock","attrs":{"language":"json"},"content":[{"type":"text","text":"{\n \"links\": [\n {\n \"linkID\": \"1\",\n \"href\": <link>,\n \"method\": \"GET\",\n \"mediaType\": \"application/json\",\n \"rel\": \"self\"\n }\n ]\n}"}]}],"version":1}}'
Expected behavior
The comment should be created
Environment and Version (please complete the following information):
Version: 1.107.1 (user setup)
Commit: 994fd12f8d3a5aa16f17d42c041e5809167e845a
Date: 2025-12-17T14:15:14.850Z
Electron: 39.2.3
ElectronBuildId: 12895514
Chromium: 142.0.7444.175
Node.js: 22.21.1
V8: 14.2.231.21-electron.0
OS: Windows_NT x64 10.0.22631
Name: Atlassian: Jira, Rovo Dev, Bitbucket
Id: atlassian.atlascode
Description: Bringing the power of Jira, Rovo Dev, and Bitbucket to VS Code - With Atlassian for VS Code you can create and view issues, start work on issues, create pull requests, do code reviews, start builds, get build statuses and more!
Version: 4.1.108
Publisher: Atlassian
VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=Atlassian.atlascode