[GeoNode-devel] Non ISO Metadata Topic Categories and Geonode Behavior

Patrick Dufour pjdufour.dev at gmail.com
Wed Dec 30 13:43:13 PST 2015

I agree that multiple categories set for a resourcebase object should be

Yes, with batch metadata editing, fixing by hand shouldn't be difficult.

For the flag, how will GeoNode "know" the categories are ISO.  It's
implied, since they are the only ones there by default, but the flag
wouldn't trigger an ISO check.  It would just check that the category
currently exists or not.  Otherwise, we'd probably need another field in
the Category model to say whether each is ISO or not.  Either option is

On Dec 30, 2015 10:37 AM, "Eduardo Castanho" <eduardo.castanho at ipma.pt>

> Hi! Patrick
> In last day of the code sprint in Turin,  we talked about  the lack of
> fields in Geonode metatada, comparing with ISO 19115 profile.
> One of those fields was Topic Category, that isn't fully supported by
> Geonode, because it only accepts one, more specifically  the first  topic
> category  value on the metadata file.
> Your  suggestion seems fine to me, but it implies that if you start with
> the flag on False and then change it  to True, the data that you have in
> Geonode will be inconsistent, for example, the TopicCategory Model/Table
> will have non ISO entries.
> Some sort of solution to minimize this can be implemented, but in my
> opinion it only will bring an overload to the Geonode and this can be
> easily managed by "hand".
> May be the name for the FLAG  can be more explicit like
> Regards,
> Eduardo Castanho
> Instituto Português do Mar e da Atmosfera
> Lisboa Portugal
> On 29-12-2015 22:30, Patrick Dufour wrote:
>> Good afternoon, Eduardo.
>> Could you briefly recap the relevant discussion during the sprint?  I
>> missed that conversation.
>> That is the expected behavior.  We wanted to be sure that if you
>> imported data from a source that isn't following that ISO standard
>> closely that the import will work rather than throwing an error.
>> GeoNode will match an existing category if possible and will create a
>> new category if needed.
>> I think my preference is to maintain that existing "default" behavior.
>> However, I think a flag in settings like "CATEGORIES_STRICT=False"
>> would work.  If CATEGORIES_STRICT is true, then if a category doesn't
>> match on upload/import an error is thrown.  If CATEGORIES_STRICT is
>> false, then the existing behavior goes.
>> Regards,
>> Patrick
>> On 12/29/15, Eduardo Castanho <eduardo.castanho at ipma.pt> wrote:
>>> Hi!! to all
>>> I'm trying to implement multiple Topic Categories in Geonode, so that
>>> the metadata is more according to ISO 19115, as was discussed in this
>>> year code sprint.
>>> But I have a doubt about  the correct  behavior in the upload of
>>> metadata that contains Topic Categories that doesn't  belong to ISO
>>> CodeList.
>>> Currently, Geonode creates a new  category  :
>>>                       elif key == 'topic_category':
>>>                                   value, created =
>>>                  TopicCategory.objects*.get_or_create*(
>>>                                       identifier=value.lower(),
>>>                                       defaults={'description': '',
>>>                  'gn_description': value})
>>>                                   key = 'category'
>>>                                   defaults[key] = value
>>> @ geonode/geonode/layers/utils.py (line 442)/****/
>>> Is this the expected behavior?
>>> If we have multiple categories imported from metatada files,  the number
>>> of new categories will raise a lot (including spelling errors), can this
>>> be bad ?
>>> with best regards,
>>> Eduardo Castanho
>>> IPMA
>>> Instituto Português do Mar e da Atmosfera
>>> Lisboa Portugal
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geonode-devel/attachments/20151230/6dd9f87d/attachment.html>

More information about the geonode-devel mailing list