Python TypeError: 'list' object is not callable with a dict dictionary, if boolean
I have a dictionary that converts an index number to a node name. I am trying to check if the name is already in a list. I get an error list 'object not callable'. An image of my code is attached.