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

ISBN from DOI #30

Closed
Phyks opened this issue Dec 27, 2015 · 4 comments
Closed

ISBN from DOI #30

Phyks opened this issue Dec 27, 2015 · 4 comments

Comments

@Phyks
Copy link

Phyks commented Dec 27, 2015

Hi,

In this lib, there is a doi(isbn) function. It would be useful to have the reverse function, that is isbn(doi).

Not sure if it can be done reliably and easily?

Thanks

@xlcnd
Copy link
Owner

xlcnd commented Dec 27, 2015

Yes you can do it, it is something like:

def doi2isbn(doi):
    return "".join(c for c in doi[2:] if c in "0123456789xX")

@Phyks
Copy link
Author

Phyks commented Dec 27, 2015

Thanks! Any plan to include it in the API?

@Phyks Phyks closed this as completed Dec 27, 2015
@xlcnd
Copy link
Owner

xlcnd commented Dec 27, 2015

It can stay in the "wishlist" but I can't promise it will make it!

@Phyks
Copy link
Author

Phyks commented Dec 27, 2015

Ok, I will use your snippet in my code, and if it bumps into the official API in a future version, I will update my code to use it :)

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

No branches or pull requests

2 participants