Search Mailing List Archives


Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort
Limit to: All This Week Last Week This Month Last Month
Select Date Range     through    

[bioontology-support] Can't make "DELETE /provisional_classes/:provisional_class_id" work

Thomas Rodenhausen thomas.rodenhausen at gmail.com
Wed Feb 26 09:05:53 PST 2014


Hi Darren,

I noticed that DELETE now works fine.
For PATCH I still have the originally reported problem. Is this a known
problem or am I maybe missing out on something?


On Mon, Jan 27, 2014 at 9:10 AM, Thomas Rodenhausen <
thomas.rodenhausen at gmail.com> wrote:

> Thanks.
>
> Just want to add the issue with PATCH below, which seems to be similar.
>
> 3 > GET
> http://data.bioontology.org/provisional_classes/737af2a0-6751-0131-e6d9-005056010074
> 3 > Accept: application/json
> 3 > Authorization: apikey token=...
>
> 4 < 200
> 4 < Age: 60
> 4 < Cache-Control: public, max-age=60
> 4 < Connection: close
> 4 < Content-Length: 590
> 4 < Content-Type: application/json;charset=utf-8
> 4 < Date: Mon, 27 Jan 2014 16:04:24 GMT
> 4 < Last-Modified: Fri, 24 Jan 2014 18:17:27 GMT
> 4 < Status: 200 OK
> 4 < Vary: User-Agent, Accept, Accept-Language, Accept-Encoding,
> Authorization, NCBO-Slice
> 4 < X-Content-Digest: 44212eef4fe92be0bcc402c637645f5e801d14a8
> 4 < X-Content-Type-Options: nosniff
> 4 < X-Rack-Cache: stale, valid, store
> {"label":"test2","synonym":[],"definition":[],"subclassOf":null,"creator":"
> http://data.bioontology.org/users/thomas.rodenhausen
> ","created":"2014-01-24T10:15:38-08:00","permanentId":null,"noteId":null,"ontology":[],"@id":"
> http://data.bioontology.org/provisional_classes/737af2a0-6751-0131-e6d9-005056010074
> ","@type":"http://data.bioontology.org/metadata/ProvisionalClass
> ","@context":{"@vocab":"http://data.bioontology.org/metadata/
> ","creator":{"@id":"http://data.bioontology.org/metadata/User
> ","@type":"@id"},"ontology":{"@id":"
> http://data.bioontology.org/metadata/Ontology","@type":"@id"}}}
>
> 5 > POST
> http://data.bioontology.org/provisional_classes/737af2a0-6751-0131-e6d9-005056010074
> 5 > Accept: application/json
> 5 > Authorization: apikey token=...
> 5 > Content-Type: application/json
> 5 > X-HTTP-Method-Override: PATCH
> {"label":"test3","synonym":[],"definition":[],"subclassOf":null,"creator":"
> http://data.bioontology.org/users/thomas.rodenhausen
> ","created":"2014-01-24T10:15:38-08:00","permanentId":null,"noteId":null,"ontology":[],"@id":"
> http://data.bioontology.org/provisional_classes/737af2a0-6751-0131-e6d9-005056010074
> ","@type":"http://data.bioontology.org/metadata/ProvisionalClass"}
>
> 6 < 500
> 6 < Connection: close
> 6 < Content-Length: 30
> 6 < Content-Type: text/html;charset=utf-8
> 6 < Date: Mon, 27 Jan 2014 16:04:24 GMT
> 6 < Status: 500 Internal Server Error
> 6 < X-Content-Type-Options: nosniff
> 6 < X-Frame-Options: SAMEORIGIN
> 6 < X-Rack-Cache: invalidate, pass
> 6 < X-XSS-Protection: 1; mode=block
> <h1>Internal Server Error</h1>
>
>
> On Thu, Jan 23, 2014 at 1:47 PM, Darren Weber <dlweber at stanford.edu>wrote:
>
>>
>> Hi Thomas,
>>
>> A fix for this should be available in the next release.  Thanks for
>> reporting the bug.
>>
>> Take care,
>> Darren
>>
>> PS, details of the fix are at
>> https://github.com/ncbo/ontologies_api/commit/0a0dddbfe7aec2db3d8c291bac5a1508351bea1c
>>
>>
>>
>> On 1/23/14, 11:07 AM, Thomas Rodenhausen wrote:
>>
>>  I had tried this before, it results in the same HTTP 500, see below.
>> Also note that a GET for the URI returns a 404, that's why I had tried
>> only the last part of the URI, which works at least for GET.
>>
>>  3 > DELETE
>> http://data.bioontology.org/provisional_classes/http%3A%2F%2Fdata.bioontology.org%2Fprovisional_classes%2F4e3b6790-65eb-0131-7e69-005056010073
>> 3 > Accept: application/json
>> 3 > Authorization: apikey token=...
>>
>>  4 < 500
>> 4 < Connection: close
>> 4 < Content-Length: 30
>> 4 < Content-Type: text/html;charset=utf-8
>> 4 < Date: Thu, 23 Jan 2014 19:03:36 GMT
>> 4 < Status: 500 Internal Server Error
>> 4 < X-Content-Type-Options: nosniff
>> 4 < X-Frame-Options: SAMEORIGIN
>> 4 < X-Rack-Cache: invalidate, pass
>> 4 < X-XSS-Protection: 1; mode=block
>> <h1>Internal Server Error</h1>
>>
>>  1 > GET
>> http://data.bioontology.org/provisional_classes/http%3A%2F%2Fdata.bioontology.org%2Fprovisional_classes%2F4e3b6790-65eb-0131-7e69-005056010073
>> 1 > Accept: application/json
>> 1 > Authorization: apikey token=...
>>
>>  2 < 404
>> 2 < Age: 0
>> 2 < Cache-Control: public, max-age=60
>> 2 < Connection: close
>> 2 < Content-Length: 140
>> 2 < Content-Type: application/json;charset=utf-8
>> 2 < Date: Thu, 23 Jan 2014 19:05:27 GMT
>> 2 < Last-Modified: Wed, 22 Jan 2014 23:38:27 GMT
>> 2 < Status: 404 Not Found
>> 2 < Vary: User-Agent, Accept, Accept-Language, Accept-Encoding,
>> Authorization, NCBO-Slice
>> 2 < X-Content-Digest: 2d9b8c551b17ead68f6a51e042464baab321c87a
>> 2 < X-Content-Type-Options: nosniff
>> 2 < X-Rack-Cache: miss, store
>> {"errors":["Provisional class
>> http://data.bioontology.org/provisional_classes/4e3b6790-65eb-0131-7e69-005056010073not found"],"status":404}
>>
>>
>>
>> On Thu, Jan 23, 2014 at 11:58 AM, Darren Weber <dlweber at stanford.edu>wrote:
>>
>>>
>>> Hi Thomas,
>>>
>>> Looking at the documentation at
>>> http://data.bioontology.org/documentation#ProvisionalClass
>>>
>>> There is a DELETE method available.  The URI takes the form:
>>>
>>> {service_endpoint}/{resource_id}
>>>
>>> where {resource_id} is a full URI; translating for this example we get:
>>>
>>> service_endpoint = http://data.bioontology.org/provisional_classes/
>>> resource_id =
>>> http://data.bioontology.org/provisional_classes/4e3b6790-65eb-0131-7e69-005056010073
>>> resource_id_encoded = http%3A%2F%2Fdata.bioontology.org
>>> %2Fprovisional_classes%2F4e3b6790-65eb-0131-7e69-005056010073
>>>
>>> (Encoding the resource_id can be done with various tools; for this
>>> example, I've used http://meyerweb.com/eric/tools/dencoder/.)
>>>
>>> So, the full URI for the DELETE looks like this:
>>>
>>>
>>> http://data.bioontology.org/provisional_classes/http%3A%2F%2Fdata.bioontology.org%2Fprovisional_classes%2F4e3b6790-65eb-0131-7e69-005056010073
>>>
>>> Hope that helps,
>>>
>>> Darren
>>>
>>>
>>>
>>> On 1/23/14, 8:49 AM, Thomas Rodenhausen wrote:
>>>
>>>   Hi,
>>>
>>>  see below I can't make this work, although a GET on the same URI does.
>>> Can you tell me what I am doing wrong?
>>>
>>>  Also tried
>>> - paths including the colon
>>> - the full blown id string e.g.
>>> http://data.bioontology.org/provisional_classes/4e3b6790-65eb-0131-7e69-005056010073
>>> - apikey as query string instead of authorization header
>>>
>>>  Thank you
>>>
>>>
>>>  1 > GET
>>> http://data.bioontology.org/provisional_classes/4e3b6790-65eb-0131-7e69-005056010073
>>> 1 > Accept: application/json
>>> 1 > Authorization: apikey token=...
>>>
>>>  2 < 200
>>> 2 < Age: 60
>>> 2 < Cache-Control: public, max-age=60
>>> 2 < Connection: close
>>> 2 < Content-Length: 589
>>> 2 < Content-Type: application/json;charset=utf-8
>>> 2 < Date: Thu, 23 Jan 2014 16:18:58 GMT
>>> 2 < Last-Modified: Wed, 22 Jan 2014 23:38:27 GMT
>>> 2 < Status: 200 OK
>>> 2 < Vary: User-Agent, Accept, Accept-Language, Accept-Encoding,
>>> Authorization, NCBO-Slice
>>> 2 < X-Content-Digest: 07c5d1cec4fc52329ff7371eebe8e07cfa25931b
>>> 2 < X-Content-Type-Options: nosniff
>>> 2 < X-Rack-Cache: stale, valid, store
>>>
>>> {"label":"test","synonym":[],"definition":[],"subclassOf":null,"creator":"
>>> http://data.bioontology.org/users/thomas.rodenhausen
>>> ","created":"2014-01-22T15:31:56-08:00","permanentId":null,"noteId":null,"ontology":[],"@id":"
>>> http://data.bioontology.org/provisional_classes/4e3b6790-65eb-0131-7e69-005056010073
>>> ","@type":"http://data.bioontology.org/metadata/ProvisionalClass
>>> ","@context":{"@vocab":"http://data.bioontology.org/metadata/
>>> ","creator":{"@id":"http://data.bioontology.org/metadata/User
>>> ","@type":"@id"},"ontology":{"@id":"
>>> http://data.bioontology.org/metadata/Ontology","@type":"@id"}}}
>>>
>>>  3 > DELETE
>>> http://data.bioontology.org/provisional_classes/4e3b6790-65eb-0131-7e69-005056010073
>>> 3 > Accept: application/json
>>> 3 > Authorization: apikey token=...
>>>
>>>  4 < 500
>>> 4 < Connection: close
>>> 4 < Content-Length: 30
>>> 4 < Content-Type: text/html;charset=utf-8
>>> 4 < Date: Thu, 23 Jan 2014 16:20:35 GMT
>>> 4 < Status: 500 Internal Server Error
>>> 4 < X-Content-Type-Options: nosniff
>>> 4 < X-Frame-Options: SAMEORIGIN
>>> 4 < X-Rack-Cache: invalidate, pass
>>> 4 < X-XSS-Protection: 1; mode=block
>>> <h1>Internal Server Error</h1>
>>>
>>>
>>>   _______________________________________________
>>> bioontology-support mailing listbioontology-support at lists.stanford.eduhttps://mailman.stanford.edu/mailman/listinfo/bioontology-support
>>>
>>>
>>>
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.stanford.edu/pipermail/bioontology-support/attachments/20140226/2c71cf9b/attachment-0001.html>


More information about the bioontology-support mailing list