Is the M121-course out-of-date?

I just completed the “Lab - $match”-lab in Chapter 1 of the M121 course.

However, after a few failed attempts with the validator, I simple took a guess at the answer and guessed correctly. But, the weird thing is that when I tried to run the “correct answer” (which was all but identical to my code) it still gave me the wrong answer.

Has the data in the cluster been updated and the validator isn’t? Seems odd that the “correct solution” doesn’t give the correct answer.

The data has not change. The validation has not change and returns the correct answer with the correct pipeline. The pipeline given as the solution is the correct pipeline.

Something must be wrong with your environment or with how you are doing the lab.

Are you connected to the appropriate cluster?

What output to you get from the validation script?

The script returns “You aren’t returning the correct number of documents”.
I tried copying the correct pipeline from the course site, and then run “db.movies.aggregate(pipeline).itcount()”, and got 23, when the answer according to the lab is 15.

If your pipeline produces

then your pipeline is wrong and most likely NOT

to the correct solution.

23 is the correct number of documents to return. The lab does not ask for the number of documents. It asks for the value produced by the validation script.

How many documents are return by your pipeline? You may publish your pipeline using Hide Details or Blur Spoiler so we can help you figure out where you erred.

Oh, right. I can’t believe I missed that part. Sorry, for taking up your time.

1 Like