'Add comment node
:param content_hash: Hash of node content
:param page: Doc page for node
:param version: Slug for project version to apply node to
:type version: str
:param commit: Commit that node was updated in
:type commit: str'

def add_node(self, content_hash, page, version, commit):

    from readthedocs.comments.models import NodeSnapshot, DocumentNode
    project_obj = Project.objects.get(slug=self.slug)
    version_obj = project_obj.versions.get(slug=version)
    try:
        NodeSnapshot.objects.get(hash=content_hash, node__project=project_obj, node__version=version_obj, node__page=page, commit=commit)
        return False
    except NodeSnapshot.DoesNotExist:
        DocumentNode.objects.create(hash=content_hash, page=page, project=project_obj, version=version_obj, commit=commit)
    return True
