Property to return the root of this node.

        Returns:
            Package: this node's root package.

def root(self):
        """
        Property to return the root of this node.

        Returns:
            Package: this node's root package.
        """
        node = self
        while node.package is not None:
            node = node.package
        return node