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

dashes in isbns cause problem in normal level #107

Closed
C7DAFBB7 opened this issue Aug 31, 2022 · 1 comment
Closed

dashes in isbns cause problem in normal level #107

C7DAFBB7 opened this issue Aug 31, 2022 · 1 comment
Assignees
Labels

Comments

@C7DAFBB7
Copy link

Whenever a string contains '-97' get_isbnlike() returns wonky results in normal level.

For example for "Fashion 101 - A Crash Course in Clothing"

isbnlib.get_isbnlike('978-0-9790173-4-6', level='normal') => ['9790173-4-6']

which should return ['978-0-9790173-4-6'] or possibly ['978-0-9790173-4-6', '9790173-4-6']

for 'Superbritánico and the Queen's Birthday'

isnblib.getisbnlike(''978-9788461784') => ['9788461784']

The problem seems to be caused by this bit of code introduced to solve issue #60

    text = text.replace('-97', '- 97')

Thank you

@xlcnd xlcnd self-assigned this Sep 1, 2022
@xlcnd xlcnd added the bug label Sep 1, 2022
xlcnd added a commit that referenced this issue Sep 1, 2022
xlcnd added a commit that referenced this issue Sep 1, 2022
xlcnd added a commit that referenced this issue Sep 1, 2022
xlcnd added a commit that referenced this issue Sep 2, 2022
xlcnd added a commit that referenced this issue Sep 2, 2022
@xlcnd
Copy link
Owner

xlcnd commented Sep 2, 2022

Thanks! It is 'fixed'!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants