Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix regular expressions containing redundant prefix and update local identifier validation #213

Merged
merged 17 commits into from
Nov 1, 2021

Conversation

cthoyt
Copy link
Member

@cthoyt cthoyt commented Oct 11, 2021

Closes #191

This PR does two things:

  1. It uses the "cleaned identifiers" (which will hopefully get a better name later) for regex checking. This means that rather than adding a redundant namespace in LUI before doing the regex check, it explicitly removes them
  2. Update regex patterns that include namespace in LUI to no longer include the namespace. Keep in mind these are only written this way likely because of a deep confusion between local unique identifiers and CURIEs held by the MIRIAM database curators almost 10 years ago that has never been fixed. See Confused about how Namespace in Pattern works #191 (comment) for a more thorough explanation.

This PR will not be merged until there is a consensus on this. I will bring it up in discussion at the Fall 2021 Workshop on Prefixes, CURIEs, and IRIs which is on October 29th, then give everyone about a week to give feedback.

See also #214 where the web UI is updated to better convey the difference between a regular expression pattern that's for a local identifier versus for a compact URI (i.e., CURIE), which must, by definition, contain the prefix.

@cthoyt cthoyt changed the title Update identifier validation to rely on shortened identifiers Fix regular expressions containing redunant prefix and update local identifier validation Oct 11, 2021
@cthoyt cthoyt changed the title Fix regular expressions containing redunant prefix and update local identifier validation Fix regular expressions containing redundant prefix and update local identifier validation Nov 1, 2021
@cthoyt cthoyt marked this pull request as ready for review November 1, 2021 16:05
@cthoyt cthoyt merged commit 75cd462 into main Nov 1, 2021
@cthoyt cthoyt deleted the update-validation branch November 1, 2021 16:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Confused about how Namespace in Pattern works
1 participant