pxt-microbit icon indicating copy to clipboard operation
pxt-microbit copied to clipboard

Inline comments are ignored in Python when returning to blocks

Open microbit-mark opened this issue 4 years ago • 1 comments

Describe the bug There appears to be a difference in behaviour when someone tries to use inline comments in Python and switch to blocks and back. Not sure what the default behaviour is supposed to be.

It seems that when someone adds an inline comment in Python and switches to blocks and back, the comment is ignored. If the comment is added on a new line it is included as part of the block for the code below it.

In Javascript, a line-level comment appears to be moved to a new line when you switch to blocks and then remains on that line when y

To Reproduce

https://user-images.githubusercontent.com/31242877/124438342-f6ffce00-dd6f-11eb-8bb0-8d0026d5bb4f.mp4

Expected behavior I would expect that if I added a comment at the end of a line, that it would stay there when I switch between languages

Desktop (please complete the following information):

  • OS: [e.g. iOS] Mac
  • Browser [e.g. chrome, safari] Firefox
  • Version [e.g. 22] 89

microbit-mark avatar Jul 05 '21 08:07 microbit-mark

Still repros.

abchatra avatar May 20 '25 18:05 abchatra