class RaiseVisitor(object):

    def __init__(self):
        self.nodes = []

def visitRaise(self, n):
    self.nodes.append(n)
Python: How can I know which exceptions might be thrown from a method call