Hi,

I installed the ISBN2node module and set the database to openlibrary. When I searched for ISBNs, none of them were found. I tried ISBN-10 and ISBN-13 with and without dashes for books that already existed on the openlibrary site. I actually followed the API link and inserted the ISBN manually on the link to the openlibrary json file to confirm that the file exists. Any help?

- Jon

Comments

vertikal.dk’s picture

Jon,

Sorry for the late reply. Wondering what is happening with your installation. I use ISBN2node on a regular basis for my own book database and it works as intended. Just tested it seconds ago and it found a book based on the ISBN in OpenLibrary.

Of course if the direct link works, so should the module's lookup. Have you tried other ISBN's? Would you mind sharing the ISBN you tried and I will try to look into it.

Martin

geek-merlin’s picture

Title: ISBN search does not work with any ISBN » openlibrary ISBN search does not work with any ISBN
Assigned: JonCohen » Unassigned
Category: support » bug

tried isbn 9780553280401
which i got from
http://openlibrary.org/works/OL16040604W/The_walking_drum

vertikal.dk’s picture

StatusFileSize
new69.65 KB

Axel,

I just tried that very ISBN in my own install, and it worked like a charm as you can see on my screen dump below.
I have no idea what's happening in your install...

Martin

geek-merlin’s picture

hmm, i realized that the git repo looks a bit screwed up here.
sure you run the same version that is tagged 1.3 here?

jwalz’s picture

Status: Active » Needs review
StatusFileSize
new1.53 KB

I think I did this patch generation correctly, not 100% sure though.

I also had this issue. It was that the fetch function only returned success if there was more than one result not at least one result.

bartlantz’s picture

I can confirm that on a clean install, ISBN lookups to openlibrary.org are not working either on a bulk import or single ISBN import:

here's the ISBNs I looked up for bulk:
0321385179
0072472278

Here's an isbn I looked up individually:
9780743400503

all of these were in the openlibrary database, but failed when I tried to import them with the module.

I'll test out the patch from comment #5 and see if that fixes the issue.

Thanks!

bartlantz’s picture

Status: Needs review » Reviewed & tested by the community

Thanks jwalz!

The patch from comment #5 fixed the issue for me. I am now able to successfully add isbn from the openlibrary.org database.

(Both via single import and bulk import.)

Thanks,
Bart

Edited to add:

Actually, there was a bit of a problem with the patch. It failed at first, so I patched the files manually. Attached is an updated version of the original patch.

I just removed some white space and it now works with either:
patch -p1 < ISBN2node-openlibrary-isbn-1370940.patch

or with
git apply ISBN2node-openlibrary-isbn-1370940.patch

Thanks,
Bart

bartlantz’s picture

Status: Reviewed & tested by the community » Needs review
StatusFileSize
new1.52 KB

Okay, so the form wouldn't allow me to add an attachment when I was editing a response. So, here's the updated patch that worked for me (I'm using linux on my server.)

It should work with either:
patch -p1 < ISBN2node-fix_import_openlibrary_isbn-1370940-8.patch

or with
git apply ISBN2node-fix_import_openlibrary_isbn-1370940-8.patch

Also I am changing the status back to needs review since this rerolled patch should be tested again.

Thanks,
Bart

demirors’s picture

Issue summary: View changes
Status: Needs review » Reviewed & tested by the community

I can confirmed that the patch in #8 works. Please commit it.