def decode(node):
    'Convert cmdx Node to shortest unique path\n\n    This is the same as `node.shortestPath()`\n    To get an absolute path, use `node.path()`\n\n    '
    try:
        return node.shortestPath()
    except AttributeError:
        return node.name(namespace=True)
Convert cmdx Node to shortest unique path

This is the same as `node.shortestPath()`
To get an absolute path, use `node.path()`
def decode(node):
    'Convert cmdx Node to shortest unique path\n\n    This is the same as `node.shortestPath()`\n    To get an absolute path, use `node.path()`\n\n    '
    try:
        return node.shortestPath()
    except AttributeError:
        return node.name(namespace=True)