Bug in Building a Mario Database

I am working on the Building a Mario Database tutorial in the Relational Database Certification. I am pretty sure that I am stuck because of a bug. Attached is a picture of where I am at (I just updated Daisy’s favorite color to Orange). The error message is '“characters” should have the correct rows for “Daisy” and “Yoshi”. ’ There were no updates for Yoshi in the instructions so that row should still be correct. I have also attached a picture of my current table. Is it me or is there a problem with the tutorial?


1 Like

HI @shreecheryl and @multisonic !

Have both of you tried resetting the lesson?
Sometimes, resetting the lesson will help correct answers go through.

1 Like

Yes, I have tried resetting.

Me too. And interestingly, resetting that level undoes the work of at least one additional level (adding the Daisy and Yoshi rows) instead of simply restoring the state to Daisy’s row values before the favorite_color change.

I have passed along this thread over to Tom so he can take a look at this.

2 Likes

Can both of you also edit your posts to include the SQL command you entered for this challenge?

1 Like

Oops, I deleted my post instead of editing it

Original Post:

I’m stuck at the exact same point. I double checked all the values in the previously inputted rows and can’t seem to make this test pass. Must be a bug - can anyone confirm?

The command I used to complete this challenge was:

UPDATE characters SET favorite_color='Orange' WHERE name='Daisy';
1 Like

I used the exact same SQL command as @multisonic. UPDATE characters SET favorite_color=‘Orange’ WHERE name=‘Daisy’;

Hey @shreecheryl & @multisonic,

It appears you have both done it correctly. The test that is supposed to be used is here. It checks that your database has the correct info, and both of the screen shots appear to be correct.

There’s some strange bugs that occur sometimes when going through these tutorials. We are continuously trying to improve their stability. One of them is that sometimes a new test doesn’t properly load and/or the instructions get a little misaligned with the tests. I think something like that has happened here. The error message you say you see is, “characters” should have the correct rows for “Daisy” and “Yoshi”. It looks like the test for that message is two before the one you are seeing. Change Daisy’s color back to yellow to see if it will pass: UPDATE characters SET favorite_color=‘Yellow’ WHERE name='Daisy’; That should be all you would need to do to pass the test two before the one the instructions show.

Not exactly sure what will happen if it does. The instructions may stay the same, but the next test would load - still one before what the instructions show. If you made it that far, enter SELECT * FROM characters; to pass that step and it should be caught back up to the instructions.

Let us know if you have any luck with any of that. If not, I can try and help some more.

If all else fails, you can always start the tutorial from the beginning again. I know it stinks, but it does make for some good practice

1 Like

I am COMPLETELY stuck now. I am now trying to start over and nothing is working. I have closed and restarted everything several times and it is unable to complete the Remote-Containers: Rebuild and Reopen in Container command. I don’t know what else to do. Is it possible that I need to delete my current copy of RDB and clone it to my computer again?

Thanks for the guidance. Unfortunately, using the previous command to “trick” the misaligned test doesn’t work.

When I tried running: UPDATE characters SET favorite_color='Yellow' WHERE name='Daisy';, I got a test failure message “You should have the correct values for ‘Daisy’”.

When I then tried to re-run the command UPDATE characters SET favorite_color='Orange' WHERE name='Daisy';, I get the earlier test failure message: “‘characters’ should have the correct rows for ‘Daisy’ and ‘Yoshi’”

In your experience, how likely does it seem that we would encounter this same bug at this same point if we started from the beginning of this particular tutorial?

Thanks again for all your work on this. Let me know if I can provide any further information to help debug this.

Hey @shreecheryl,

Sorry for your troubles. Your command to build the container worked the first time you tried - or at least one other time. You probably tried, but I would close everything and try again. If it keeps happening, you could check the logs for errors and see what they say. Maybe try to troubleshoot or share them here. I doubt that re-cloning the rdb-alpha repo would help - nothing changed in it. I guess unless you cloned it a while ago - the last change was November 30th.

Hey @multisonic,

So what I think happened for you is that a new test loaded, and the old test didn’t get commented out. It might be tough, and I can’t promise it will work, but I can try to help fix it. You need to change the test files within the project. There’s a .vscode/settings.json file, with a property, that is keeping them hidden. Open a regular terminal (not the psql one in the images), and enter this in it:

sed -i -e 's/".freeCodeCamp": true,/".freeCodeCamp": false,/g' ~/project/.vscode/settings.json

That will unhide the tutorial files in your vscode. In your screenshot, the files aren’t shown. You would need to click that top left button that looks like two pieces of paper to see them. You should then see a .freeCodeCamp folder - expand it and the test folder within it. Look at the few most recent test files - they will be something like 680.test.js and 690.test.js. All of them, except for the most recent one (likely 690.test.js) should be commented out. Comment out all of them except the most recent one - carefully - only comment out the files I suggested and don’t change anything else. If that’s the problem, the tests might run automatically and pass after you comment it out - assuming your database still has Orange for Daisy’s color. If the database isn’t correct any more, change her color back - or whatever else you need to do. Good luck - I’ll be here.

4 Likes

Thank you for getting back to me. I lost my patience yesterday so I ended up deleting/uninstalling everything and starting over from scratch. I am up and running again but I am staying away from the Mario Database tutorial until I am sure it is okay. Has anyone successfully completed it?

I completed the tutorial about a couple of weeks ago.
Sometimes when I go through the challenge one of the challenges doesn’t register and I have to reset it for it to go through.
But I am not sure why your mario database isn’t working :woman_shrugging:
Hopefully it will work now

If you are skipping mario right now, then you will probably have to skip celestial bodies right now too since the mario lessons prepare you for that project.

You can do the Learn Bash scripting by building 5 projects and then try mario again later.

3 Likes

Thank you so much for all of your help, Jessica. I appreciate you! :smiling_face_with_three_hearts:

1 Like

This method worked for me. After running the command to unhide the test files I found that 670.test.js was not commented out. Once I did that I received a “Level Complete” and moved on to 700. :smiley:

2 Likes

Ran into some issues that completely blocked tests passing out of the gate yesterday after install on Win10. The very first tests would not pass after rebuilding container w and w/o cache, resetting lesson, resetting terminal, etc. Theorizing it may be a bug on Windows and/or with my VScode extensions. I also had changed the default terminal to Git Bash months ago…at any rate I am going to try out on my macbook instead today. I did finally get the first test to pass after multiple resets, but was then encountering the same thing on the second (‘pwd’) test. Here’s video of what I was experiencing:
Youtube clip of my issue

Hey @sieis, did you get a chance to try it on your mac? any luck?

I did. Up and running fine on Mac. I am still uncertain as to the root of the issue on Win10, but I am grateful it’s without a hitch on the Mac.
Thanks for the followup!

1 Like