C5W3 Trigger Word Detection Assignment. We expected function modelf to return type <class ‘bool’> but I get NoneType object

Got the following error, but the UNIT TEST section of UNQ_C5 passed all the tests, don’t know what could be the problem, when I write type(modelf) I get <class ‘function’> type.

“Code Cell UNQ_C5: Unexpected error (AttributeError(”‘NoneType’ object has no attribute ‘op’")) occurred during function check. We expected function modelf to return type <class ‘bool’>. Please check that this function is defined properly.
If you see many functions being marked as incorrect, try to trace back your steps & identify if there is an incorrect function that is being used in other steps.
This dependency may be the cause of the errors."

Re-ran by the third time, and now it has scored 100, may be I missed a cell to play.

Often this happens if you update the code but don’t click the “Save” button before you run “Submit”.

1 Like