I am currently attempting to link to and fill in a knowledge graph (KG) using the python API. I initially was trying to follow the instructions from this demo "Building Web Applications and Notebooks with ArcGIS Knowledge" https://mediaspace.esri.com/media/t/1_6f3u6m9c .
I'm using api version '2.1.0.3' and connecting to a KG hosted on ArcGIS Enterprise.
------
import sys
from arcgis.gis import GIS
from arcgis.graph import KnowledgeGraph
gis = GIS("https://arcgis.edc.renci.org/portal",'#######',verify_cert=False)
kg = KnowledgeGraph("https://arcgis.edc.renci.org/server/rest/services/Hosted/GFloat/KnowledgeGraphServer",gis = gis)
-------
This works fine but when I try to see if the KG is empty
-------
for types in kg.datamodel['entity_types']:
print(types)
for types in kg.datamodel['relationship_types']:
print(types)
--------
and ready for inputs (expect Document and HasDocument to be returned) I only get this error.
AttributeError: 'NoneType' object has no attribute 'to_value_object'
Am I doing something wrong or is the dev summit video already obsolete?