Opening BibTeX file instead of importing

With Zotero 1.0.10, when I select a BibTeX file for importing, the file is presented for opening/download, but not imported.

First, a popup window with a progress bar appears. And a collection for the import is created. But then the download dialog is presented, the progress bar stays open forever and not items actuall get imported.
  • Hello,

    I have exactly the same problem since the update to 1.0.10. It is a big issue not to be able to import bib files anymore.

    configuration
    windows XP
    firefox 3.0
    zotero 1.0.10
  • I’m a bit surprised that this not-so-small issue did’t get any attention. Is this being worked on? Is there a workaround that I’m not aware of?

    Since many bibliography management tools speak BibTeX, this is probably one of the most important exchange formats between Zotero and other tools.
  • Works fine for me. Tested with Firefox 3.0.10 and Zotero 1.0.10 on OS X and Windows XP.

    Does this happen if you pick a random item in Zotero, export to BibTeX, and re-import? If not, can you isolate a particular record or set of records in the BibTeX file that causes the problem? (Cut it by halves, repeating with the failing half each time.)
  • You’re right, Zotero can actually import bibtex files it created itself. But a bibtex file exported from JabRef fails.

    I tried to strip off anything that I could imagine that could cause troubles, like umlauts, non-standard bibtex fields, uppercase spelling, etc. Zotero still fails. I even ran bibclean on the file, still doesn’t work.

    I post the content here, maybe someone has any clue why this fails:


    @incollection{ilyin06,
    author = {Ilyin, Vladimir},
    title = {Religiositat als Faktor fur die Immigrationspraxis ethnischer Deutscher
    in die Bundesrepublik Deutschland},
    booktitle = {Zuhause fremd - Russlanddeutsche zwischen Russland und Deutschland},
    publisher = {transcript Verlag},
    year = {2006},
    editor = {Kaiser, Markus},
    pages = {275-304},
    address = {Bielefeld},
    }
  • That record works for me with Firefox 3.0.10 and Zotero 1.0.10 on OS X.
  • I had tested on Firefox 3.0.10 w/ the Zotero 2 beta on Linux & also received the file open dialog that felwert describes. I haven't debugged this much; the import does work from the clipboard import on Zotero 2.
  • For whatever reason, felwert's snippet triggers a hidden browser & this intercepts the BibTeX file from Zotero:zotero(4): Translate: Parsing code for BibTeX

    zotero(4): Translate: Setting configure option dataMode to block

    zotero(4): Translate: Setting display option exportCharset to UTF-8

    zotero(3): created hidden browser (2)

    GCJ PLUGIN: thread 0x621db0: NP_GetMIMEDescription
    GCJ PLUGIN: thread 0x621db0: NP_GetMIMEDescription return
    GCJ PLUGIN: thread 0x621db0: NP_GetValue
    GCJ PLUGIN: thread 0x621db0: NP_GetValue: returning plugin name.
    GCJ PLUGIN: thread 0x621db0: NP_GetValue return
    GCJ PLUGIN: thread 0x621db0: NP_GetValue
    GCJ PLUGIN: thread 0x621db0: NP_GetValue: returning plugin description.
    GCJ PLUGIN: thread 0x621db0: NP_GetValue return
    A random Zotero-exported .bib did not spawn a hidden window.
  • edited June 9, 2009
    This seems to be related to the character/mime encoding of the BibTeX file. Zotero produces UTF-8 files & can import them without spawning a new window:
    $ file Exported\ Items.bib
    Exported Items.bib: Unicode text, UTF-8
    $ file -i Exported\ Items.bib
    Exported Items.bib: text/plain; charset=utf-8
    But not so with ascii files:$ file broken.bib
    broken.bib: BibTeX text file
    $ file -i broken.bib
    broken.bib: text/plain; charset=us-ascii
    Changing the file to UTF-8 w/ BOM:$ uconv --add-signature broken.bib >fixed.bib && file fixed.bib
    fixed.bib: Unicode text, UTF-8
    $ file -i fixed.bib
    fixed.bib: text/plain; charset=utf-8
    leads to successful import (as does importing from the clipboard).
  • I can confirm noksagts workaround. Thanks for investigating!
  • I had the same problem, and the encoding change worked for me too. Since the BibTeX import previously worked, and I suspect this problem might be caused by a recent Zotero update, I strongly suggest to announce this solution more prominently.
  • I think the right way would not be to promote this solution (a.k.a. workaround), but to fix the import in Zotero. BibTeX import is quite crucial, so I think this issue could need some attention. (But as alway, I’m of course biased in thinking the bug I hit is the most important one.)
  • We're still working on a fix, but note that another (perhaps easier) workaround in Zotero 2.0 is to change the Import Character Encoding in Zotero's Advanced preferences from "(auto detect)" to the appropriate encoding.
  • Thanks, Dan, for the correct topic. Here is my post if it can help anyone to detect the bug/reason:

    I have got a trouble while importing a bib-file to Zotero 2.0b6 on Firefox 3.0.11. I was playing with Firefox action on opening bib-files from web pages hoping that Zotero catches them and automatically import. However, it is not the case.
    Moreover, Zotero has stopped to import bib-files from my hard disk -- after import progress window shows up, a standard dialog appears asking to save(!) bib-file or to open it by a program. The progress window is hanging forever, so I need to restart Firefox to close it.

    I have tried to reinstall Zotero, but it didn't help. I guess it is a problem of Firefox reaction on bib-files -- after I have tried to open a bib-file from the web by Firefox instead of saving it to hard disk, a Zotero setting has been removed. Now I have no idea how I can find the setting to fix it.


    PS.
    It must be simple, and the developers know how they set up the extension and Firefox to import bib-files (smth like intercepting them... or whatever). After one changes file-type setting, that rule is lost. So the question is -- how to put it back (preferably automatically).

    Before it get fixed, I have to import my bib-files via clipboard -- not much difficult, though.
  • thanks for sending me this way, Dan. Only trouble is that the workaround offered by noksagt didn't work for me. After using uconv, the file still remained ascii. tried it on several machines and it didn't work.
  • edited October 20, 2009
    mandersald: If you can't get uconv to work, there are two other workarounds offered in this thread: Import from Clipboard and changing the Import Character Encoding setting (now in the Export pane of the prefs rather than Advanced).
  • I'm sorry for not being able to figure this out. I should have specified that I'm using zotero version 1.0.10. (IT guys prefer the most stable versions). So the import from clipboard function or import character encoding setting functions don't exist? Must say I'm quite frustrated and close to giving up.
  • @Dan Stillman: I think it doesn't even have to be the "appropriate" encoding. It is possible to correctly import Unicode (e.g. Japanese) characters even if the import encoding in Zotero is set to ISO 8859-1 or IBM 850 or other limited encodings. It seems any import encoding setting will do, as long as it's not "auto detect".
  • This issue should be fixed in 2.0b7.5, now available.

    (iglesia: That'd be a separate issue—and suggest that the import setting wasn't actually working properly for non-Unicode character sets. If that's the case, please start a new thread.)
Sign In or Register to comment.