hedyorg / hedy

Hedy is a gradual programming language to teach children programming. Gradual languages use different language levels, where each level adds new concepts and syntactic complexity. At the end of the Hedy level sequence, kids master a subset of syntactically valid Python.
https://www.hedy.org
European Union Public License 1.2
1.32k stars 289 forks source link

Running the forward example after the echo example in level 1 [BUG] #1427

Closed OnnoEbbens closed 2 years ago

OnnoEbbens commented 2 years ago

Describe the bug In level 1, if I first run the echo example and then the forward example the output screen remains black and no line is shown. With the examples I mean the command examples from the pane on the left. This also happens when I use the turn example instead of the forward example. I think it has something to do with the ask command but I am not sure.

Paste the Hedy code & level first I use this:

ask What is your favorite color?
echo so your favorite color is 

after running I replace the code with this: forward 100

The feedback is positive but no line is drawn (see screenshot)

image

Expected behavior I want to see a line when I run forward 100

TiBiBa commented 2 years ago

I've found a fix! This is due to us using hide() on the turtle canvas when we get user input. But, we forget to toggle the canvas again on a new run (so it is still hidden...). Will make a PR with a fix right away and it should be fixed in a minute.

OnnoEbbens commented 2 years ago

Thanks!