UKGovLD / registry-core

Linked data registry - core application and example UI
https://github.com/UKGovLD/registry-core/wiki
Apache License 2.0
23 stars 9 forks source link

error message for bulk collection type registration #71

Open smrgeoinfo opened 9 years ago

smrgeoinfo commented 9 years ago

Uploading a batch file to define a skos:Collection, I used rdfs:member to identify the contained concepts and get this: "Action failed: Bad Request - MetamorphicFaciesCollection.ttl - No children of bulk collection type found".

It took me awhile to realize that the problem wasn't that skos:Collection wasn't being identified as a bulk collection type, but that the concepts weren't typed correctly to be members of a skos:Collection. The actual problem is that the membership predicate is skos:member, not rdfs:member. Would it be possible for the error message to be more specific, something like "No children of skos:Collection or reg:Register declared"

here's the ttl I'm testing with:

@prefix dct: <http://purl.org/dc/terms/> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix skos: <http://www.w3.org/2004/02/skos/core#> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix reg:   <http://purl.org/linked-data/registry#> .
@prefix metafac: <metafacies1/> . 

<metafacies1>
            a  skos:Collection , reg:Register  ;
              rdfs:label        "CGI Metamorphic Facies Category Collection"@en ;
              dct:description   "This file contains..." @en ;
              rdfs:member   metafac:amphibolite_metamorphic_facies , metafac:eclogite_metamorphic_facies .

metafac:amphibolite_metamorphic_facies 
            a  skos:Concept ;
            rdfs:label "amphibolite metamorphic facies" ;
            dct:description "yada yada."@en .

metafac:eclogite_metamorphic_facies
            a skos:Concept ;
            rdfs:label "eclogite metamorphic facies" ;
            dct:description "more yada yada"@en .
der commented 9 years ago

Fair point. I've improved that message. With your test data it now says: Found bulk collection type skos:Collection, but no children found using membership property skos:member