Extension development with PyUNO for LibreOffice Calc

Dave DrBluesman at yahoo.com
Sun Mar 22 12:28:59 PDT 2015


Hi all,

I'm developing a LO Calc extension in Python 
(http://extensions.libreoffice.org/extension-center/smf-extension). The 
new advfn module I am working on is returning only '#VALUE!' in LO 
despite working in a Python3 shell.  Debugging steps I have taken so far:

--I set DEBUG_LOGLEVEL = 1 in pythonloader.py, which shows that the 
pyuno bridge allocates memory for my script, but not much else.
--I re-wrote based on a Python core module (html.parser) and verified 
that it is included in the Python that is distributed with LO.
--I verified that the type that I pass back to LO is a standard float or 
string
--I verified that the pyuno bridge is executing the code by calling a 
known exception state (datacode out of range) and observing expected 
behavior (populates cell with "Invalid Datacode")

The code for the new advfn module, as well as the rest of the extension, 
can be found at 
http://github.com/madsailor/SMF-Extension/blob/master/src/advfn.py. 
Testing in the python3 shell is done with src/smftest.py, and the .oxt 
extension is compiled with compile.sh.  I'm unsure how to proceed with 
debugging, and would appreciate any helpful suggestions.

Thanks


More information about the LibreOffice mailing list