Skip to content

Switching to Scratch causes challenge to hang #586

@navzam

Description

@navzam

Repro steps:

  1. Start a challenge
  2. Switch programming language to Scratch
  3. "Loading..." screen appears and never goes away. There doesn't seem to be any way to recover the challenge (refreshing challenge, switching to another scene and coming back to the challenge, etc.)

I think it has to do with currentLanguage being set to "scratch", but code doesn't have "scratch" as a key, so in this code:

const language = this.currentLanguage;
const code = language ? this.code[language] : undefined;
if (!scene || scene.type === Async.Type.Unloaded || !language || !code) {
return <Loading />;
}

!code is always true

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinghighHigh priority issue

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions