[OPEN-ILS-DEV] Making Zotero work again in 1.6

Dan Scott dan at coffeecode.net
Mon Sep 28 12:24:45 EDT 2009


It looks like Zotero integration isn't working as of around 1.6; Zotero
fires off a "Can't save record" error without much more specifics, but
the Zotero forum provided a good lead at
http://forums.zotero.org/discussion/8118/error-capturing-record-in-zotero-1010-via-unapi-mods-and-evergreen-16/.

Zotero seems to expect MODS version 3 based on the name "mods" in the
unAPI listed formats, and we serve up MODS version 2 from that name; but
dev.gapines.org seems to do that, and it works, while Zotero is very
disturbed by acq.open-ils.org that does the same thing (albeit with a
longer list of formats). It would be nice if Zotero read the schema
definitions from the unAPI formats list and picked the correct MODS
version to match its own transform (as MODS v3 varies from point release
to point release and that can affect the record capture), but for now we
have to dance with the one that brought us.

If you manipulate O:A:SuperCat to turn "mods" into "mods2" and "mods3"
into "mods", then you hit the second problem in that the namespace on
the record set by O:W:SuperCat:Feed is now "http://www.loc.gov/mods/"
instead of "http://www.loc.gov/mods/v3". And Zotero again fails to save
the record.

When I then modified O:W:SuperCat:Feed to force the namespace for
OpenILS::WWW::SuperCat::Feed::mods to "http://www.loc.gov/mods/v3" so
that "mods" was serving up a MODS 3 record with a MODS 3 namespace,
Zotero became happy.

I haven't committed any changes yet, because they felt like a bit of a
hack _and_ I wanted to ensure that both changes were necessary _and_ I
worry that there may be some further consequences of mucking around at
this level (ergo, good to bring up for discussion). I was considering
the approach of making MODS3 (or MODS32?) the result from
OpenILS::WWW::SuperCat::Feed::mods and then creating a corresponding
OpenILS::WWW::SuperCat::Feed::mods2 feed for whatever might possibly
want to generate a MODS v2 record.

Thoughts?





More information about the Open-ils-dev mailing list