Inserts are no effortless. The issue was the default graph specification. 
The 500 error I got did not lead me to this.
The code I run now to insert triples into a Topbraid EDG development server 
is as follows:

    endpoint = "http://localhost:8083/tbl/sparql"; 
    query = """
        INSERT DATA {graph <urn:x-evn-master:testdata>
        { <http://example.org/ontologies/testOnto#ind14> a 
<http://example.org/ontologies/testOnto#testClass>  . }
        }"""
    sparql = SPARQLWrapper(endpoint)
    
    sparql.setQuery(query)
    result = sparql.query()

regards,
Richard

On Thursday, August 20, 2020 at 7:49:39 PM UTC+2 [email protected] wrote:

> Dear Richard,
>
> Maybe I am not catching all the details of your question, but it looks 
> like setCredentials is used somewhere in your code, because auth is only 
> applied in case credentials has been provided.
>
>
> https://github.com/RDFLib/sparqlwrapper/blob/master/SPARQLWrapper/Wrapper.py#L715
>
> Just in case, this is an example SPARQL update query 
> https://sparqlwrapper.readthedocs.io/en/stable/main.html#sparql-update-example
>
> In your case, you will need to be remove these lines:
> sparql.setHTTPAuth(DIGEST)
> sparql.setCredentials("login", "password") 
>
> I hope it helps
>
> Best,
>
> Carlos Tejo
>
> On Thu, Aug 20, 2020 at 12:55 PM [email protected] <
> [email protected]> wrote:
>
>>
>> Dear all,
>>
>> Ik want to insert triples in a sparql endpoint that has no authorisation 
>> because it runs on my local machine. I do get an 500 error and assume that 
>> is caused by permissions.
>>
>> I do not use any authorisation so both sparql.setHTTPAuth(BASIC or 
>> *DIGEST* ) are not approperiate, None is not accepted.
>>
>> How can this be done?
>>
>> Regards,
>> Richard D
>>
>> -- 
>> http://github.com/RDFLib
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "rdflib-dev" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected].
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/rdflib-dev/87a68f13-1900-49ed-a3ef-a2d18af482een%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/rdflib-dev/87a68f13-1900-49ed-a3ef-a2d18af482een%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
http://github.com/RDFLib
--- 
You received this message because you are subscribed to the Google Groups 
"rdflib-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/rdflib-dev/6bc50157-f484-4bd5-a500-9e64bd06b77an%40googlegroups.com.

Reply via email to