W2 - Emojify - Excercise3 - sentences_to_indices error

Hi there, i’m having an issue with this specific excercise on this weeks course is showing all tests passed but at grading time it says there is an error and it’s not giving me the excercise as passed.
Has anyone faced this issue and know how to fix it?
Thanks in advance!

Most likely there is an error in your sentences_to_indices() function that the notebook’s tests did not catch, but the grader’s tests did.

Items to check are whether your code uses any global variables, or fixed index references, that are not available to the grader.

FYI, please do not post your code on the forum. That’s not allowed by the Code of Conduct.
If a mentor needs to see your code, we’ll contact you via a private message with instructions.

Your code for X_Indices[i,j] = ... seems overly complicated. And I’m suspicious about that + 1 at the end. Maybe try = word_to_index[w] instead.

Sorry, didn’t remember that about the code of conduct. Will take a look at it. Thanks!