ESCOMP / CCPPStandardNames

Repository for community-accepted CCPP Standard Names and search tools
Other
3 stars 16 forks source link

Fix invalid standard names, add standard name checking script and github action #52

Closed mkavulich closed 7 months ago

mkavulich commented 8 months ago

Description

This PR introduces a Github Action to automatically check the validity of Standard Names against the list of criteria specified by the CF conventions: Must only contain lowercase letters, numerals, or underscores, and the first character must be a letter. This is achieved with a new script (tools/check_name_rules.py) that parses the given standard names xml file, and checks each name against these rules, returning an error if any invalid names are found. This action will run on all branches for any new commits to ensure any new names follow these rules.

This new script revealed several existing invalid names; those have been corrected as part of this PR.

Issue addressed

42

mkavulich commented 7 months ago

@nusbaume Thanks for the great review! I applied most of your suggestions, and also applied the analogous improvements to tools/check_xml_unique.py.

Regarding the CI run rules, I thought it would be useful to always check the names so problems get caught at an early stage, but you're right that does impose a lot on users with forks. I changed the rule to pull-request-only, and since we already have a file for pull-request CI, I combined the new rule into the existing file.

Now, for some reason after all these updates the markdown check CI test is failing. I can't figure out what's going on here, as there's no difference locally between the two files.