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

add email and sha1 identifiers #96

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

add email and sha1 identifiers #96

wants to merge 4 commits into from

Conversation

dfdan
Copy link
Member

@dfdan dfdan commented Dec 15, 2023

❤️ Thank you for your contribution!

Description

This adds support for email and sha1 identifiers.

I was interested to learn that WADM (and possibly other W3C standards) allow the sha1 of an email address as a personal identifier for a creator to allow identification without revealing email addresses.

https://www.w3.org/TR/annotation-model/#agents

Checklist

Ticks in all boxes and 🟢 on all GitHub actions status checks are required to merge:

Third-party code

If you've added third-party code (copy/pasted or new dependencies), please reach out to an architect.

Reminder

By using GitHub, you have already agreed to the GitHub’s Terms of Service including that:

  1. You license your contribution under the same terms as the current repository’s license.
  2. You agree that you have the right to license your contribution under the current repository’s license.

@dfdan
Copy link
Member Author

dfdan commented Dec 15, 2023

I note that a new version of black (>24) has caused tests to fail on an existing line. Happy to fix the line length - or should we pin black?

@utnapischtim
Copy link
Contributor

i think this PR changed the behavior with long lines in dict's.

we had the problem of different rules in newer black versions already and as i know already used the new style.

@dfdan
Copy link
Member Author

dfdan commented Dec 18, 2023

This is an issue that's going to affect all packages... I'll wait and see what happens elsewhere :)
I assume this change would produce backward-compatible dicts so it might be easiest just to fix...

@utnapischtim
Copy link
Contributor

i also think that the easiest would be to just fix it and adopt the new style.

@dfdan
Copy link
Member Author

dfdan commented Dec 18, 2023

Done, does this otherwise seem sensible?

@utnapischtim
Copy link
Contributor

yes it does, although i am not sure where you will use it.

@dfdan
Copy link
Member Author

dfdan commented Dec 18, 2023

The (in my view overlooked) use case is any Invenio instance where you want to associate one or more email addresses with a creatibutor (in addition / as an alternative to ORCID, GND etc). We have instances doing this, and others have asked the question on Discord.

The email_sha1 is specifically for planned work on WADM based annotation.

The DataCite schema accepts any scheme + URI as a nameIdentifier, so these additions are compatible with DataCite.

Copy link
Contributor

@fenekku fenekku left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mostly the hexadecimal thing to double-check, but otherwise LGTM.

idutils/__init__.py Show resolved Hide resolved
idutils/__init__.py Outdated Show resolved Hide resolved
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.

3 participants