Error (or empty file) when exporting standalone notes

I'm trying to export my standalone notes, but with some selected formats (e.g. TEI) I get an error.

For other formats (e.g. CSV) I just get an empty file.

Can anyone help me figure out what I'm doing wrong.

Many thanks.
  • What are you exporting for?

    If you just want your standalone notes in a file, you can just select them and drag them to a text editor.

    Most export formats are geared towards bibliographic data and don't support standalone notes.
  • Well, I can imagine doing any thing I might otherwise would with structured data.

    I could auto generate a blog from my notes. Or I could convert them to LaTeX and make a printed book for my students. Or I might be interested in created an online annotated bibliography use the Zotero API.

    Interestingly enough, as I write, I see that I can access the notes (both free standing and attached) via the Zotero API.

    So for example: in this collection https://api.zotero.org/groups/555244/collections/P7EEKAK7/items?format=json.

    "key": "3PFKG32I", with the value "Test Note in Wodeham Collection"

    Thus, I wonder why I could't export from the Zotero Desktop client with JSON or any other format, since it is clearly possible via the API.

    At least I found a way to do it, if I need to.

    But extracting my notes via the API seems like unnecessary work around.

    Note Also: that I can only do this in the JSON format.
    https://api.zotero.org/groups/555244/collections/P7EEKAK7/items?format=tei

    Requesting the collection TEI format gives me an error.

    See https://api.zotero.org/groups/555244/collections/P7EEKAK7/items?format=tei

    Any reason why I can't access my collection in TEI? Should I make a new post/ticket for this?

  • edited May 12, 2020
    Well, I can imagine doing any thing I might otherwise would with structured data.

    I could auto generate a blog from my notes. Or I could convert them to LaTeX and make a printed book for my students. Or I might be interested in created an online annotated bibliography use the Zotero API.
    As dstillman suggests, Zotero's export formats have specific purposes. They're not all meant to be for everything (otherwise we'd only need one). In many formats, standalone notes simply aren't meaningful. I would argue that includes Zotero's TEI implementation, which creates TEI listBibl, i.e. citation lists. If there's a actual use cases we could consider adding standalone as <note> in there, but we'd want to hear from folks using Zotero's TEI in production for that.


    If you want a local export that is comprehensive, use Zotero RDF. I think the Better Bibtex extension also has a complete JSON export format if you prefer that.

    Edit: or maybe I misread. If you're asking why TEI export fails for an entire collection, that's a fair complaint; we can have it fail gracefully for Standalone notes so that doesn't happen and would take an issue on zotero/translators for that.
  • Ok, thanks @adamsmith. I think the Zotero RDF export options answers my questions and will be sufficient for my needs.

    But how about my follow up question:

    Can you help figure out why the format=tei is failing?
    https://api.zotero.org/groups/555244/collections/P7EEKAK7/items?format=tei

    I don't think it has anything to do with the presence or absence of standalone notes because it is failing with or without a standalone note.
  • Can you export the collection to TEI from your local Zotero?
    Zotero returns a 500 error which it ideally shouldn't ever due, but I think would happen when a translator error is triggered.
  • Yes, it seems to work, when I export locally to TEI.
  • @dstillman or someone else at Zotero would need to look at that
  • It's still about notes. @Geoff16W is trying to export a collection using an /items URL, which includes child items, which includes notes. From the perspective of export translators in the API, child items are just separate items, since that's how the default JSON format works, and since TEI doesn't handle standalone notes, it fails with an error. If you want to export top-level items only, you'd want to use /items/top. (We currently support the equivalent of "Export Notes" in export translators via the API, so this will just exclude child notes.)

    It still might make sense to fix TEI to just skip notes, which is how other translators work (e.g., RIS and BibTeX, which won't fail if swapped in in the above URL).
Sign In or Register to comment.