type hinting within a class

class Node: def append_child(self, node: Node): if node != None: self.first_child = node self.child_nodes += [node] How do I do node: Node? Because when I run it, it says name ‘Node’ is not defined. Should I just remove the : Node and instance check it inside the function? But then how could I access node‘s … Read more