Editing a PR comment stops rendering markdown

Issue #458 resolved
Ian Chamberlain created an issue

I've noticed that when reviewing a PR, it is only possible to edit a review comment once successfully before it reverts to rendering the comment contents as plaintext rather than markdown. The user account picture is also not displayed on the comment any longer.

Example (edit: higher quality):

markdown_stops_rendering.gif

This isn't a huge issue most of the time, since it is mostly cosmetic, with one exception – editing the comment again after this happens will result in the markdown effectively being escaped, so the comment will lose all formating (e.g. ` in the original comment source becomes \` in the final result).

Also possibly related – I can't seem to reproduce it reliably (possibly fixed in recent update?), but I have noticed that sometimes this plaintext version of the edited comment appears alongside the properly rendered view instead of replacing it.

This occurs when using the extension with a Bitbucket Server.

Extension details:

Name: Jira and Bitbucket (Official)
Id: atlassian.atlascode
Description: Bringing the power of Jira 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: 2.6.6
Publisher: Atlassian
VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=Atlassian.atlascode

VSCode details:

Version: 1.47.2
Commit: 17299e413d5590b14ab0340ea477cdd86ff13daf
Date: 2020-07-15T18:18:50.054Z (4 days ago)
Electron: 7.3.2
Chrome: 78.0.3904.130
Node.js: 12.8.1
V8: 7.8.279.23-electron.0
OS: Darwin x64 19.6.0

Comments (9)

  1. Pramod Busam Account Deactivated

    @{557058:c0430571-619b-452e-8e71-9bdd9e451cde} Can you check if version 2.8.0 of the extension fixes this issue.

    I was unable to reproduce this issue. However, we fixed another issue related to comments duplicating in diff view and I'm wondering if that fixes this problem too.

  2. Ian Chamberlain Account Deactivated reporter

    @{557058:a30b5736-f3cf-41d7-aad0-99c9ffac78ce} I have been unable to check due to #478 but I will update with a comment once I have a chance to attempt a reproduction.

  3. ComeEasy Account Deactivated

    I faced the scenario several times with 2.8.0 and 2.8.2, and did not reproduce the issue. Markdown and even syntax highlighting inside fenced blocks work as expected even if I edit the comment several times in a row.

    Version: 1.49.1
    Commit: 58bb7b2331731bf72587010e943852e13e6fd3cf
    Date: 2020-09-16T23:23:33.049Z
    Electron: 9.2.1
    Chrome: 83.0.4103.122
    Node.js: 12.14.1
    V8: 8.3.110.13-electron.0
    OS: Linux x64 5.8.10-200.fc32.x86_64

    atlascode 2.8.2

  4. Ian Chamberlain Account Deactivated reporter

    Okay, now that issues with PR list have been fixed I came back to check this. It seems in order to trigger I have to edit the comment a couple times, and importantly the comment must be saved for the effect to occur. Saving a second time would result in the markdown getting escaped as it appears in the comment box.

    Something else to note: I can restore the markdown render by closing the file and reopening it. I seem to remember this not working in the past, so it seems like an improvement (possible related to the other issue with duplicating comments).

    Here's another example recording using 2.8.2 version:

    Screen Recording 2020-09-23 at 09.50.14.mov.gif

    Updated environment info:

    Version: 1.49.1
    Commit: 58bb7b2331731bf72587010e943852e13e6fd3cf
    Date: 2020-09-16T23:21:17.533Z
    Electron: 9.2.1
    Chrome: 83.0.4103.122
    Node.js: 12.14.1
    V8: 8.3.110.13-electron.0
    OS: Darwin x64 19.6.0
    
    Name: Jira and Bitbucket (Official)
    Id: atlassian.atlascode
    Description: Bringing the power of Jira 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: 2.8.2
    Publisher: Atlassian
    VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=Atlassian.atlascode
    
  5. Nick Rundquist

    @{557058:c0430571-619b-452e-8e71-9bdd9e451cde} , we’ve just released version 2.8.3 of the extension with a change that should address the issue. Let us know if you’re still having trouble.

  6. Log in to comment