bug with urn namespace - 2

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

bug with urn namespace - 2

Massimo Coletti
If I create a simple ontology, with 1 class, and the following namespace:

urn:nir:stato:decreto.legislativo:2003-06-30

Protege is not able to reload the project after saving an closing it.
Also if I create a new project from the existing owl file, the problem
persist.

The owl file is:

<?xml version="1.0"?>
<rdf:RDF
     xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
     xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
     xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
     xmlns:owl="http://www.w3.org/2002/07/owl#"
     xmlns="urn:nir:stato:decreto.legislativo:2003-06-30#"
   xml:base="urn:nir:stato:decreto.legislativo:2003-06-30">
   <owl:Ontology rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30"/>
   <owl:Class rdf:ID="OneConcept"/>
</rdf:RDF>

<!-- Created with Protege (with OWL Plugin 2.2, Build 311)
http://protege.stanford.edu -->

-------------------------------------------------------------------------
To unsubscribe go to http://protege.stanford.edu/community/subscribe.html

Reply | Threaded
Open this post in threaded view
|

Re: bug with urn namespace - 2

Tania Tudorache
Hi Massimo,

I have just tested the URN support in the latest beta (318). It seems
that there is a problem with the MetadataTab in handling the URNs but
the content of the ontology is loaded correctly. If you disable the
MetadataTab from your project and then reload the project (the pprj
file, not owl file) you won't get any exception anymore.

You can even import the URN ontology into another ontology and this will
import correctly and will also be displayed correctly in the MetadataTab.

Here is the OWL file with URN namespace that I generated with Protege
3.2 b318:

<?xml version="1.0"?>
<rdf:RDF
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
    xmlns="urn:nir:stato:decreto.legislativo:2003-06-30;196:"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
    xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
    xmlns:owl="http://www.w3.org/2002/07/owl#"
  xml:base="urn:nir:stato:decreto.legislativo:2003-06-30;196">
  <owl:Ontology
rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196"/>
  <owl:Class
rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196:Class_2"/>
  <owl:Class
rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196:Class_1"/>
</rdf:RDF>

<!-- Created with Protege (with OWL Plugin 2.2, Build 318)  
http://protege.stanford.edu -->

Tania


Massimo Coletti wrote:

> If I create a simple ontology, with 1 class, and the following namespace:
>
> urn:nir:stato:decreto.legislativo:2003-06-30
>
> Protege is not able to reload the project after saving an closing it.
> Also if I create a new project from the existing owl file, the problem
> persist.
>
> The owl file is:
>
> <?xml version="1.0"?>
> <rdf:RDF
>     xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
>     xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
>     xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
>     xmlns:owl="http://www.w3.org/2002/07/owl#"
>     xmlns="urn:nir:stato:decreto.legislativo:2003-06-30#"
>   xml:base="urn:nir:stato:decreto.legislativo:2003-06-30">
>   <owl:Ontology
> rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30"/>
>   <owl:Class rdf:ID="OneConcept"/>
> </rdf:RDF>
>
> <!-- Created with Protege (with OWL Plugin 2.2, Build 311)
> http://protege.stanford.edu -->
>
> -------------------------------------------------------------------------
> To unsubscribe go to http://protege.stanford.edu/community/subscribe.html
>
>

-------------------------------------------------------------------------
To unsubscribe go to http://protege.stanford.edu/community/subscribe.html

Reply | Threaded
Open this post in threaded view
|

Re: bug with urn namespace - 2

Tania Tudorache
In reply to this post by Massimo Coletti
Hi Massimo,

I have just tested the URN support in the latest beta (318). It seems that there is a problem with the MetadataTab in handling the URNs but the content of the ontology is loaded correctly. If you disable the MetadataTab from your project and then reload the project (the pprj file, not owl file) you won't get any exception anymore.

You can even import the URN ontology into another ontology and this will import correctly and will also be displayed correctly in the MetadataTab (see screenshot attached).

Here is OWL file with URN namespace that I generated with Protege 3.2 b318:

<?xml version="1.0"?>
<rdf:RDF
    xmlns:rdf= " http://www.w3.org/1999/02/22-rdf-syntax-ns #"
    xmlns="urn:nir:stato:decreto.legislativo:2003-06-30;196:"
    xmlns:xsd= " http://www.w3.org/2001/XMLSchema #"
    xmlns:rdfs= " http://www.w3.org/2000/01/rdf-schema #"
    xmlns:owl= " http://www.w3.org/2002/07/owl #"
  <a href="xml:base=">xml:base= "urn:nir:stato:decreto.legislativo:2003-06-30;196">
  <owl:Ontology rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196"/>
  <owl:Class rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196:Class_2"/>
  <owl:Class rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196:Class_1"/>
</rdf:RDF>

<!-- Created with Protege (with OWL Plugin 2.2, Build 318)  http://protege.stanford.edu -->

Tania





Massimo Coletti wrote:
If I create a simple ontology, with 1 class, and the following namespace:

urn:nir:stato:decreto.legislativo:2003-06-30

Protege is not able to reload the project after saving an closing it.
Also if I create a new project from the existing owl file, the problem
persist.

The owl file is:

<?xml version="1.0"?>
<rdf:RDF
    xmlns:rdf= " http://www.w3.org/1999/02/22-rdf-syntax-ns #"
    xmlns:xsd= " http://www.w3.org/2001/XMLSchema #"
    xmlns:rdfs= " http://www.w3.org/2000/01/rdf-schema #"
    xmlns:owl= " http://www.w3.org/2002/07/owl #"
    xmlns="urn:nir:stato:decreto.legislativo:2003-06-30#"
  <a href="xml:base=">xml:base= "urn:nir:stato:decreto.legislativo:2003-06-30">
  <owl:Ontology rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30"/>
  <owl:Class rdf:ID="OneConcept"/>
</rdf:RDF>

<!-- Created with Protege (with OWL Plugin 2.2, Build 311) http://protege.stanford.edu -->




including_urn_screenshot.JPG (54K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: bug with urn namespace - 2

Nick Drummond
Massimo, Tania,

It's actually slightly more robust than that - this loads fine in Protege 318 (including the metadata tab).
I think its about the form of the URNs - if you try to edit the ontology URI Protege sticks a # on the end of the default namespace.
This causes the ontology to fail to load the next time.

I'm not sure what the correct syntax is - I can only find an ancient RFC [1] but it appears that # is a reserved character that cannot be used.  If anyone has a more up to date reference please let me know.

So, for now, URN namespaces ending in ":" appear to be supported (see Holger's comment [2])

But it doesn't seem like much has changed since 2004 - we need to do some more work on this if its important for people to use URNs. 

Nick

[2] http://article.gmane.org/gmane.comp.misc.ontology.protege.owl/2789/match=urn


On 9 May 2006, at 21:09, Tania Tudorache wrote:

Hi Massimo,

I have just tested the URN support in the latest beta (318). It seems that there is a problem with the MetadataTab in handling the URNs but the content of the ontology is loaded correctly. If you disable the MetadataTab from your project and then reload the project (the pprj file, not owl file) you won't get any exception anymore.

You can even import the URN ontology into another ontology and this will import correctly and will also be displayed correctly in the MetadataTab (see screenshot attached).

Here is OWL file with URN namespace that I generated with Protege 3.2 b318:

<?xml version="1.0"?>
<rdf:RDF
    xmlns:rdf= " http://www.w3.org/1999/02/22-rdf-syntax-ns #"
    xmlns="urn:nir:stato:decreto.legislativo:2003-06-30;196:"
    xmlns:xsd= " http://www.w3.org/2001/XMLSchema #"
    xmlns:rdfs= " http://www.w3.org/2000/01/rdf-schema #"
    xmlns:owl= " http://www.w3.org/2002/07/owl #"
  <A href="xml:base=">xml:base= "urn:nir:stato:decreto.legislativo:2003-06-30;196">
  <owl:Ontology rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196"/>
  <owl:Class rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196:Class_2"/>
  <owl:Class rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196:Class_1"/>
</rdf:RDF>

<!-- Created with Protege (with OWL Plugin 2.2, Build 318)  http://protege.stanford.edu -->

Tania





Massimo Coletti wrote:
If I create a simple ontology, with 1 class, and the following namespace:

urn:nir:stato:decreto.legislativo:2003-06-30

Protege is not able to reload the project after saving an closing it.
Also if I create a new project from the existing owl file, the problem
persist.

The owl file is:

<?xml version="1.0"?>
<rdf:RDF
    xmlns:rdf= " http://www.w3.org/1999/02/22-rdf-syntax-ns #"
    xmlns:xsd= " http://www.w3.org/2001/XMLSchema #"
    xmlns:rdfs= " http://www.w3.org/2000/01/rdf-schema #"
    xmlns:owl= " http://www.w3.org/2002/07/owl #"
    xmlns="urn:nir:stato:decreto.legislativo:2003-06-30#"
  <A href="xml:base=">xml:base= "urn:nir:stato:decreto.legislativo:2003-06-30">
  <owl:Ontology rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30"/>
  <owl:Class rdf:ID="OneConcept"/>
</rdf:RDF>

<!-- Created with Protege (with OWL Plugin 2.2, Build 311) http://protege.stanford.edu -->



<including_urn_screenshot.JPG>

Reply | Threaded
Open this post in threaded view
|

Re: bug with urn namespace - 2

Massimo Coletti
Hi all,

please observe that the trailing semicolon was added by Protégé itself,
it was not part of my urn.

This format of urn was not an invention of mine, but is the standard
used to identify italian laws; you can find a reference on the website
www.normeinrete.it. It is a project aimed at a unique identification of
all the normative documents.

I have solved the issue using an URI that is the full href used to
reference the norm:

      http://www.nir.it/cgi-bin/N2Ln?urn:nir:stato:decreto.legislativo:2003;196

In this way I don't have any more problem. Anyway, I beleive that the
issue is still there; I checked with the RFC for URI and URN syntax, and
it seems correct.

Cheers,

Massimo

Nick Drummond ha scritto:

> Massimo, Tania,
>
> It's actually slightly more robust than that - this loads fine in
> Protege 318 (including the metadata tab).
> I think its about the form of the URNs - if you try to edit the
> ontology URI Protege sticks a # on the end of the default namespace.
> This causes the ontology to fail to load the next time.
>
> I'm not sure what the correct syntax is - I can only find an ancient
> RFC [1] but it appears that # is a reserved character that cannot be
> used.  If anyone has a more up to date reference please let me know.
>
> So, for now, URN namespaces ending in ":" appear to be supported (see
> Holger's comment [2])
>
> But it doesn't seem like much has changed since 2004 - we need to do
> some more work on this if its important for people to use URNs.
>
> Nick
>
> [1] http://www.ietf.org/rfc/rfc2141.txt
> [2] http://article.gmane.org/gmane.comp.misc.ontology.protege.owl/2789/match=urn 
>
>
>
> On 9 May 2006, at 21:09, Tania Tudorache wrote:
>
>> Hi Massimo,
>>
>> I have just tested the URN support in the latest beta (318). It seems
>> that there is a problem with the MetadataTab in handling the URNs but
>> the content of the ontology is loaded correctly. If you disable the
>> MetadataTab from your project and then reload the project (the pprj
>> file, not owl file) you won't get any exception anymore.
>>
>> You can even import the URN ontology into another ontology and this
>> will import correctly and will also be displayed correctly in the
>> MetadataTab (see screenshot attached).
>>
>> Here is OWL file with URN namespace that I generated with Protege 3.2
>> b318:
>>
>> <?xml version="1.0"?>
>> <rdf:RDF
>>     xmlns:rdf= " <http://www.w3.org/1999/02/22-rdf-syntax-ns>
>> http://www.w3.org/1999/02/22-rdf-syntax-ns #"
>> <http://www.w3.org/1999/02/22-rdf-syntax-ns>
>>     xmlns="urn:nir:stato:decreto.legislativo:2003-06-30;196:"
>>     xmlns:xsd= " <http://www.w3.org/2001/XMLSchema>
>> http://www.w3.org/2001/XMLSchema #" <http://www.w3.org/2001/XMLSchema>
>>     xmlns:rdfs= " <http://www.w3.org/2000/01/rdf-schema>
>> http://www.w3.org/2000/01/rdf-schema #"
>> <http://www.w3.org/2000/01/rdf-schema>
>>     xmlns:owl= " <http://www.w3.org/2002/07/owl>
>> http://www.w3.org/2002/07/owl #" <http://www.w3.org/2002/07/owl>
>>   xml:base= "urn:nir:stato:decreto.legislativo:2003-06-30;196">
>>   <owl:Ontology
>> rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196"/>
>>   <owl:Class
>> rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196:Class_2"/>
>>   <owl:Class
>> rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30;196:Class_1"/>
>> </rdf:RDF>
>>
>> <!-- Created with Protege (with OWL Plugin 2.2, Build 318)  
>> http://protege.stanford.edu -->
>>
>> Tania
>>
>>
>>
>>
>>
>> Massimo Coletti wrote:
>>> If I create a simple ontology, with 1 class, and the following
>>> namespace:
>>>
>>> urn:nir:stato:decreto.legislativo:2003-06-30
>>>
>>> Protege is not able to reload the project after saving an closing it.
>>> Also if I create a new project from the existing owl file, the problem
>>> persist.
>>>
>>> The owl file is:
>>>
>>> <?xml version="1.0"?>
>>> <rdf:RDF
>>>     xmlns:rdf= " <http://www.w3.org/1999/02/22-rdf-syntax-ns>
>>> http://www.w3.org/1999/02/22-rdf-syntax-ns #"
>>> <http://www.w3.org/1999/02/22-rdf-syntax-ns>
>>>     xmlns:xsd= " <http://www.w3.org/2001/XMLSchema>
>>> http://www.w3.org/2001/XMLSchema #" <http://www.w3.org/2001/XMLSchema>
>>>     xmlns:rdfs= " <http://www.w3.org/2000/01/rdf-schema>
>>> http://www.w3.org/2000/01/rdf-schema #"
>>> <http://www.w3.org/2000/01/rdf-schema>
>>>     xmlns:owl= " <http://www.w3.org/2002/07/owl>
>>> http://www.w3.org/2002/07/owl #" <http://www.w3.org/2002/07/owl>
>>>     xmlns="urn:nir:stato:decreto.legislativo:2003-06-30#"
>>>   xml:base= "urn:nir:stato:decreto.legislativo:2003-06-30">
>>>   <owl:Ontology
>>> rdf:about="urn:nir:stato:decreto.legislativo:2003-06-30"/>
>>>   <owl:Class rdf:ID="OneConcept"/>
>>> </rdf:RDF>
>>>
>>> <!-- Created with Protege (with OWL Plugin 2.2, Build 311)
>>> http://protege.stanford.edu -->
>>
>>
>>
>> <including_urn_screenshot.JPG>
>

-------------------------------------------------------------------------
To unsubscribe go to http://protege.stanford.edu/community/subscribe.html