Emojify - KeyError ('funny',)

Hi,
I have a problem with “Programming Assignment: Emojify”.
Although all the tasks are “passed” I get a score of 0 for the following reason: “Exercise 5 - Cell # 22. Can’t compile the student’s code. Error: KeyError (‘funny’,)”.
I don’t understand why. All runs are ok.
Can anyone help me?
Thank you,
F.

Hey @francescopcaforio , I’m going to DM you regarding this.

1 Like

I am getting the same error @Mubsi. Please help.

Hey @kumarsaurabh what exactly is your error ?

Exercise 5
I also get an error: cell #14 Can’t compile the student’s code. Error: KeyError(‘never’,)

@Mubsi Even I am getting the same error - “Cell #22. Can’t compile the student’s code. Error: KeyError(‘funny’,)” Even after all tests are passing.

Hey @MuskaanManocha.

Please make sure you are using the latest version of the assignment.

Secondly, your particular error is because you are either missing, or incorrectly applying an “if” statement in the second “for” loop of Exercise 3.

@Msubi: I also have the same error. I checked the dictionaries word_to_vec_map and word_to_index, and both contain ‘funny’ as index. The version of my notebook is Emoji_v3a.

Could you please help? Thanks!

Hey @bertcarremans , if your error is exactly, “Emojify - KeyError (‘funny’,)”, then in Ex 3 either you are skipping have an “if” statement or is incorrect in the second “for” loop.

1 Like

Yeah, I guess I didn’t have the latest version. It worked now. Thanks

1 Like

How to get “the new version”?? My version is Emoji_v3a I just click on “Work in Browser” button. I am accessing this notebook for the first time in July 2021, so I should have the latest version…
The if statement? that if statement (second for-loop) was there, so I don’t see why I could have it incorrect. I just replace the None on “if w in None:”
Please help
Thanks

Never mind, I found the issue, thanks

@Mubsi - I am now facing this exact issue. ALl tests passed in the work in browser but 0 score sbumission?

Hey @jlecornu, this thread will help you: Help! My code is correct, but the grader gives me 0 points! - Course 5 Version

@Mubsi - Thanks for your help: I have tried the following?

Hey @jlecornu , firstly, it is against the honour code to publicly publish solution code. I have removed it from your post.

Secondly, this is what I’m talking about (ex 3):

@jlecornu , if this is not helping still. Kindly DM your notebook, and I shall take a look.

Many apologies, I thought this was in our private message!

1 Like

No worries. Were you able to get the grade ?

1 Like