ImpowerGames / impower

An all-in-one, community-powered indie development platform that gives creative people the tools they need to bring their ideas to life.
https://www.impower.app
2 stars 1 forks source link

Dynamic section without closing brace does not display error and crashes runtime #170

Closed Wipeless closed 2 years ago

Wipeless commented 2 years ago

Describe the bug Normally, when you use the go-to > command, you'll receive an error if you try to make it go to a section that doesn't exist.

However, if you don't correctly define your braces { or }, these section errors never appear.

Also, if you attempt to run this invalid go-to command it also prevents the script from running correctly until you refresh your browser.

Steps To Reproduce

  1. Create the following script:
    
    # Root

The root

{Firs

^

First

First try

Root


2. Verify that you don't see any errors.
3. Run your script.

Expected Result An error would generate saying that the section Firs cannot be found in {Firs. Or perhaps, an error should first be generated about the missing closing curly brace.

Actual Result No errors are generated. The script runs in play mode but never gets past the go-to command.
Also, if you attempt to correct this by writing Firs to a valid section choice of First, the error will still persist until you refresh your browser.

Desktop (please complete the following information):

Additional Context This can also be seen with the following incorrect brace combinations: Firs} {First // even with a correctly defined section, the missing brace doesn't generate an error First|S // missing braces prevents the invalid section "S" from being discovered

lovelle-cardoso commented 2 years ago

@Wipeless Fixed by 4424c03f

Wipeless commented 2 years ago

Verified!