ioos/compliance-checker

ioos:1.2 attribution: NERC url not recognized as as contributor_role_vocabulary

Closed this issue · 8 comments

(note this could be an IOOS Metadata Profile issue.)

Using version 4.3.3rc2+54.gb086b57, during ioos:1.2 check,
contributor_role_vocabulary = “https://vocab.nerc.ac.uk/collection/G04/current/”
generates a warning that
"* contributor_role_vocabulary should be one of NERC or NOAA-NCEI"

However the IOOS Metadata Profile 1.2 lists this url as a valid CI_RoleCode vocabulary.

example files,
http://gyre.umeoce.maine.edu/ncei/neracoos/test/test_contrib_role_vocab_nerc.nc
and
http://gyre.umeoce.maine.edu/ncei/neracoos/test/test_contrib_role_vocab_noaa1.nc
differ only in contributor_role_vocabulary attribute.

@ancillary What you have in that file is very close, but I think it replaces an 0 with an O, and that may be causing the issue. Correct URL: https://vocab.nerc.ac.uk/collection/G04/current/.

We should probably provide the expected NOAA-NCEI URL as an example in the profile as well. I'm not sure offhand what CC accepts based on the information we have in our profile doc.

ouch, thanks, and consider this issue withdrawn.... apologies, should have caught that.

No worries! Thats what the compliance checker is here for

well, actually, even after fixing the typo, it looks like the NERC URL is still not recognized.
example file corrected
http://gyre.umeoce.maine.edu/ncei/neracoos/test/test_contrib_role_vocab_nerc.nc

@ancillary @daltonkell

I found the relevant code I think:

https://github.com/ioos/compliance-checker/blob/master/compliance_checker/ioos.py#L716-L719

It looks like we'll have to make this particular test a little more robust, or maybe more permissive, to prevent issues like this.

I think the reason this file is being flagged is because it uses HTTPS rather than HTTP for the NERC URL. Let's at least change this test to accept either protocol for each of these URLs.

Also, I think we resolved this issue by changing NCEI URls, so this comment should be removed at the same time:

https://github.com/ioos/compliance-checker/blob/master/compliance_checker/ioos.py#L678-L679

@ancillary If you can pull the latest commits from master and test this again, hopefully this issue is resolved with the latest fix:

ae50efb