I assume you mean `if not isinstance(value, list):`, but yes, that was the source of my confusion.