microsoft / microsoft/pxt

Tutorial tool displaying Python code snippets instead of JavaScript

Open
#10,897 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

tutorials
Dominant language
TypeScript
Stars
2.3k
Forks
641
Avg merge
12h 4m
Merged PRs (30d)
57

Description

In the Tutorial Tool, if you have a JavaScript tutorial with spy code snippets, it displays them as Python.
Repro -

Arcade JavaScript Tutorial

@explicitHints true

Step

Instructions here....

sprites.onOverlap(SpriteKind.Player, SpriteKind.Food, function (sprite, otherSprite) {
	info.changeScoreBy(1)
    otherSprite.setPosition(randint(0, 160), randint(0, 120))
    info.startCountdown(10)
})

You'll see the code snippet shown in Python instead -

Image

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the Tutorial Tool entry point at https://makecode.com/tutorial-tool and reproduce the issue with the JavaScript markdown and spy snippet shown in the report. Done means JavaScript spy snippets render as JavaScript rather than Python; no source file or test is named in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, python, typescript
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.