Python Plugin Using PyXPCOM

I would like to develop a plugin for Zotero using Python. Because Zotero was developed on the Mozilla Platform, I studied the MDN Documentation and discovered that Mozilla provides a Python bridge called PyXPCOM for this purpose. Unfortunately, I cannot get it to compile.

I know that Zotero was made using PyXPCOM. What is the best way to build it? The mozilla instructions do not appear to work for MS Windows. I will try their Linux instructions as well. However, is there another way to write a python program that interfaces with Zotero?
  • Zotero uses XPCOM only to store a central globally accessible object. It doesn't define any XPCOM interfaces. So what you're trying to do won't work.

    The next major version of Zotero will mirror some portions of the web API in the local client. Until then, your options are really to use JS, read the local SQLite database directly, or use the web API.

    (For other technical questions, it's best to post to zotero-dev.)
  • Depending on what you want to do, you may find qnotero a useful point of departure: https://github.com/smathot/qnotero
    It's a display only program, so reading directly from the sqlite works well for its purposes, and it's written almost entirely in python.
  • @Dan Stillman The next major version of Zotero will mirror some portions of the web API in the local client.

    next major release would mean 5.0 ?

    The background of my question is that I am planing to write some entity (tag, authors, journals, periods …) visualization tools. I think aorund the question for some time now if should use the python/mysql or python/javascript-bridge/javascript-api approach. To have an API like announced by you would be the best option of cause. However, I wonder if it is reasonable to wait or not.

    Thus, about what time frame we are talking about more or less?
Sign In or Register to comment.