The problem I imagine you're having here is that you're trying to test for inappropriate input types when you don't do anything to handle that in your fibo() function up above. You'll need to add a check to make sure n is an instance of an int and raise a ValueError then.