paleobot / pbot-dev

Codebase and initial design documents for pbot client
MIT License
2 stars 2 forks source link

ORCID - got stuck in a not valid orcid #178

Closed doricon closed 5 months ago

doricon commented 11 months ago

I entered a person and accidentally tabbed into the ORCID field, but I don't have an orcid for that person and not I cannot submit because of a "not valid orcid" error message.

I will have to clear the form and start over :(

doricon commented 11 months ago

Of course this is not a big deal, just an annoying thing, if we can address it later sometime

aazaff commented 11 months ago

For all fields requiring validation, but are not required this effect will happen.

NoisyFlowers commented 5 months ago

I wish that were true. However, this problem is an artifact of how I handle orcid validation specifically. This validation is complicated because 1) I add the url prefix automatically 2) I validate the format of the input 3) I run a checksum validation as defined by orcid (https://support.orcid.org/hc/en-us/articles/360006897674-Structure-of-the-ORCID-Identifier)

Fix is to clear that prefix if user clears field and to only run validation if there is a value.

This is in paleobot/pbot-client@30772e5e905f545ac604c845dd7642e2657a304a paleobot/pbot-client@a12bd4fb5b8ac8f5ab42e526371dbda81518992d

merged to master and running on dev and stage