KnowledgeLinks / rdfframework

RdfFramework Python Package
MIT License
3 stars 0 forks source link

Calling SPARQLProcessor run throws a TypeError: get_all_item_data() #21

Open jermnelson opened 6 years ago

jermnelson commented 6 years ago

Attempted to test SPARQLProcessor from command-line Python:

>>> from rdfframework.rml.processor import SPARQLProcessor`
>>> mapv4_processor = SPARQLProcessor(`
        ["bf-to-map4.ttl",`
        "D:/2018/dpla-service-hub/profiles/map4.ttl"],`
        triplestore_url=TRIPLESTORE_URL)`
>>> mapv4_processor.run(item=rdflib.URIRef("https://digitalcc.coloradocollege.edu/islandora/object/coccc:8473"),
>>>     instance=rdlfib.URIRef("https://plains2peaks.org/0e9fa0e8-0ba2-11e8-8277-005056c00008"))
Traceback (most recent call last):`
  File "", line 2, in `
    instance=instance)`
  File "d:\2018\rdfframework\rdfframework\rml\processor.py", line 935, in run
    debug=False)`
TypeError: get_all_item_data() missing 1 required positional argument: 'items'
mstabile75 commented 6 years ago

Fixed the call to get_all_item_data in the rml processor file. For a particular mapping the a paramaterization of the query may want to be cleaned depending on the data so that the results list doesn't balloon to large or data is missing. kwargs 'filters' adds special filters and 'special_union' adds addtional method for adding more triples.