Legoktm added a comment.
Untested, but I believe the correct code should be:
def get_results(endpoint_url, query):
sparql = SPARQLWrapper(endpoint_url, agent='MyCoolTool/0.1
[email protected]')
sparql.setQuery(query)
sparql.setReturnFormat(JSON)
return sparql.query().convert()
Based off of
https://github.com/RDFLib/sparqlwrapper/blob/master/SPARQLWrapper/Wrapper.py#L446
Where should I send a patch to?
TASK DETAIL
https://phabricator.wikimedia.org/T226709
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: Legoktm
Cc: Legoktm, ImreSamu, Alicia_Fagerving_WMSE, Aklapper, Lucas_Werkmeister_WMDE,
darthmon_wmde, Nandana, Lahi, Gq86, GoranSMilovanovic, QZanden, EBjune, merbst,
LawExplorer, Salgo60, _jensen, rosalieper, Jonas, Xmlizer, jkroll, Smalyshev,
Wikidata-bugs, Jdouglas, aude, Tobias1984, Manybubbles, Lydia_Pintscher, Mbch331
_______________________________________________
Wikidata-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs