Error:

The most common cause for this error is a syntax or compilation issue in your code submission.

You can debug your code inside of the sandbox by interacting with the sandbox application after saving your code, then looking for stack traces in the Sandbox Output. You can also put print statements in your code submission and interact with the sandbox application, then look in the Sandbox Output for your print statements. This is explained more in-depth below.

Debugging in our Main UI

After changing the code in the Code Editor tab, click Save Code. This will update the code running on your sandbox:

Now try running the sandbox web application by using the functionality you patched (e.g. log in, search, etc) to find the error. 

You will see any errors in the "Sandbox Output" section on the bottom of the screen.

Clicking Sandbox Output will show you any print/stdout/stderr output and any stack traces from your code. For tips on getting output through print statements check out this article.

Debugging in our Legacy UI

Several of our lessons are still being migrated to our new UI. But some of the same principles apply.

After clicking Patch Sandbox:

The code on your sandbox will be updated. Then go back to the sandbox web application and try running the function you patched (e.g. login, search, etc) to find the error.

You will see any errors in the "OUTPUT & ERRORS" on the right side of the screen.

Clicking on the "OUTPUT & ERRORS" tab will show you the output from your code:

Our Legacy UI will sometimes suppress the stack traces from your code. If you are having trouble debugging your code, please go back to the HackEDU app and chat with us with the Chat icon in the bottom right of the screen. Our support team can help!

Did this answer your question?