Add some automated tests for 979 ISBNs

Bug #1857060 reported by Jane Sandberg on 2019-12-19
This bug affects 17 people
Affects Status Importance Assigned to Milestone

Bug Description

In early 2020, libraries will start seeing a bunch more ISBN-13s that start with 979, rather than the classic 978 ISBN-13s. See this announcement:

From a brief spin through our code, it doesn't look like many changes will be needed. Most of the Perl code uses Business:ISBN, which has supported 979 ISBNs since back in 2002.

However, the 979 ISBNs don't have an equivalent ISBN-10. It looks like there are a few places in our business logic where we could be more careful about running as_isbn10, and certainly some more unit tests that we could add.

I'll be able to share a branch soon.

Revision history for this message
Jane Sandberg (sandbej) wrote :

Here is a branch: user/sandbergja/lp1857060_tests_for_979_isbns

Not adding the pullrequest tag just yet, because I'd like to run it by the new developers group in January.

Revision history for this message
Jane Sandberg (sandbej) wrote :

Just a note that this branch is ready to go.

And also, from my analysis, there was hardly any code that did not accept 979 ISBNs. This branch just fixes one piece of Perl (Amazon Added Content), and adds a few unit tests.

If there are 979 ISBN issues that I missed, let me know!

tags: added: pullrequest
Changed in evergreen:
assignee: Jane Sandberg (sandbej) → nobody
Michele Morgan (mmorgan) on 2020-07-31
Changed in evergreen:
milestone: none → 3.6-beta
Changed in evergreen:
importance: Undecided → Medium
milestone: 3.6-beta → 3.6-beta2
Galen Charlton (gmc) on 2020-09-30
Changed in evergreen:
milestone: 3.6-beta2 → 3.6-rc
Galen Charlton (gmc) on 2020-10-07
Changed in evergreen:
milestone: 3.6-rc → 3.6.1
Changed in evergreen:
milestone: 3.6.1 → 3.6.2
Revision history for this message
Elaine Hardy (ehardy) wrote :


Can you give specifics about what needs to be tested for the 979 ISBNs?

I am assuming it should be a legitimate ISBN so I am trying to find real ones. Locating books with the prefix has not been productive. I found one, 9791843123391, but it also has a 978 prefix 020-- which of course I can remove from the record for testing purposes. I don't have access to Books in Print....

I checked new releases up to April of 2021 and so far all have 9780 or 9781. If they have started assigning 9798 to US books, it hasn't been to many yet!

Revision history for this message
Chrisy Schroth (cschroth) wrote :

Elaine, first I found a self published one from November 2020 on Amazon with a 979-8 ISBN, but it wasn't in OCLC.

Believe it or not, I then tried WorldCat with ISBN: 979-8* and got lots of records, and did quickly spot a legit, English language book in there, a self-published novel with ISBN 9798671981742, OCLC number *1194875103.

Then I spotted one that said held by my library (didn't think to check THERE, LOL) ISBN 9798646193330 OCLC *1169783013. It's also self-published.

Also, 9798640423686 OCLC *1156966368, from Bregdan Publishing, we cataloged it in October.

Jane, these 2 in our catalog (Evergreen 3-4-5) seem to be working fine? What are we looking for here?

Revision history for this message
Elaine Hardy (ehardy) wrote :

I have never used the wild card * in an OCLC search (aging myself since I learned OCLC searching when when they didn't allow such things, nor keyword searching!) and didn't even think of using it for an ISBN search. THanks for the tip!

Very, Very interesting that they are self-published. I wonder of publishers purchase enough ISBNs in advance tht they don't yet need the 9798s.

Revision history for this message
Chrisy Schroth (cschroth) wrote :

Elaine, I agree, and I wouldn't have tried it in Connexion, but we have a link to search WorldCat just through a web browser, and after I looked the first book that I found on Amazon without success, I wondered what it would do if I tried the wildcard there. I was actually shocked that it worked, then even more shocked that it brought up hits in my own library.

Revision history for this message
Elaine Hardy (ehardy) wrote :

Ahh-- I never think of that

Tried 9798* as an ISBN search in Connexion client and got lots of hits. Most are self-published.

Lots of examples to test when we hear what we need to test.

Jane Sandberg (sandbej) on 2021-02-11
summary: - A few changes needed to accomodate 979 ISBNs
+ Add some automated tests for 979 ISBNs
Revision history for this message
Jane Sandberg (sandbej) wrote :

Changed the name of this ticket to be a bit more accurate. My branch is mainly just automated tests to make sure that we don't introduce any future logic that wouldn't work with 979 ISBNs. I don't believe there is any part of the interface (except possibly Amazon added content) that, say, would display an error on a 979 ISBN. More of a preventative/quality assurance type measure.

So, a testing procedure for somebody with command line access to an Evergreen system would probably just be:

1) Run the Perl Unit Tests (
2) Run the pgtap tests (

Changed in evergreen:
milestone: 3.6.2 → 3.6.3
Changed in evergreen:
milestone: 3.6.3 → 3.6.4
Revision history for this message
Jason Boyer (jboyer) wrote :

Thanks for putting this together Jane. I ran the tests and things looked good to me. Signoff is here:;a=shortlog;h=refs/heads/user/jboyer/lp1857060_signoff / working/user/jboyer/lp1857060_signoff

tags: added: signedoff
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers