W2_Collaborative_RecSys_Assignment_Indentation Error


I’m running C3_W2_Collaborative_RecSys_Assignment - UNQ_C1 successfully in the notebook but it fails upon Submission for grading. seems to be related to a “\n” character messing up the compile in the cell. I’ve removed all possible whitespace and copied back/forth to VSCode.

Output in notebook:

Submission error:

Hello @Dave_Cotton,

The problem should be in the indentation of your 4th cell that was submitted to the grader.

If you can run the 4th cell without any problem, then maybe the system has not saved your latest, working version of the assignment, so that the grader was still looking at something before. So, try to save it, and resubmit.

Btw, I will move this thread from the DLS forum back to the MLS forum for you. Please post in the right place next time :wink:


Thanks alot Raymond for the quick reply. I’m not sure about where to post - my assignments have been super smooth until now.

I’m able to run the page from top to bottom with zero errors. I’ll poke at it a bit more

No worries. I hope they will keep being smooth after this one :wink: , but just in case, you may start browsing from this link next time, then go to the right course and the right week, then start a draft from there.

It is great that it is zero errors, make sure to save it - there is a File menu and a Save button therein.


If you are working on the notebook locally in VSCode, and then upload the notebook to Coursera Labs for grading, that can cause a lot of problems.

Hey guys. FYI I was able to get past this by ensuring all whitespace was spaces (vs. possible mix of tabs). Wonder if there’s some parsing leniency difference between running individual cells and the grader?

Also @TMosh I’m just copying code from VSCode and plopping it into the cell - not using any VS extensions or anything fancy

If you have the option to copy as plain text, that will mitigate any issues. I’ve seen problems with VSCode doing something weird with line formatting when imported to Coursera Labs.