Troubleshooting Penjee. Common Student Errors

So, you tried to complete a Penjee challenge and you did not receive the message below:

 

assignment-complete

Below are the most common reasons for this problem.

Reason #1 : (Very rare, but frustrating)

You are 100% sure your code  is correct but the assignment isn’t completing.

Though this happens very  rarely, sometimes the web page does not load all of the files correctly (maybe you’re on a slow network, maybe our server got temporarily bogged down a bit by a lot traffic), and even though your code is correct, the assignment is not completing.

You even compared your code  to the solution code with diff, and you’re 100% sure that you wrote the right code.

The solution to this is simple : Reload the web page!

First, copy and paste your solution code , then re-load the webpage and  run the code again.  Re-loading the page always solves this very rare problem.

If it’s still not working, then I’m sorry my friend there’s some small syntax error in there somewhere!  Feel free to email me  ( max [at] penjee (dot) com  ), in that case, and I’ll get back to you quickly.

 

Reason #2 : You started in the wrong cell

starting-position

 

 

Note: On a very rare occasion, when a part of the Penjee app does not load properly, you  will get this same error (“not starting at right spot”). If you’re sure that you did indeed start at the right place. Just reload the web page  and try again. This error is very rare (like 1 out of maybe every 200 times that penjee loads and we are working on a bug fix for this btw). This is reason #1 above.

 

Reason #3: You forgot the last fish

As you know, Pam, our penguin, loves to grab all the fish; however, it’s easy to forget to get the final fish. Usually, that last fish is resting under the penguin when the program ends. So it looks like you grabbed all the fish, but you actually forgot the one at the end!

forgot-the-last-fish

 

common-error-forgot-that-last-fish

As you can see, the logger in the bottom right is very helpful. Always rely on the logger to see what is actually happening (this also will help sharpen your debugging skills)

Reason #4: Python indents

Indents, indents indents. You gotta be careful of your indents. Sometimes, the easiest way to solve this problem is by completely starting over. Just start again from scratch, rewrite each line.

Learning how to debug indents is just a part of learning python. We have several assignments in our curriculum that specifically tackle how to handle indents. Here’ s an image directly from one of the assignments:

 

 

fix-indents

 

The most tricky type of Python indent problem is when you add an extra tab at the start of an empty line! This is an “invisible error” because it looks like nothing is there, but as you know (or will soon learn) spaces/indents have a powerful meaning in Python.

space-at-start-of-line

 

So, what are you waiting for?  Let’s learn Python now!