gkarsay / parlatype

GNOME audio player for transcription
https://www.parlatype.xyz
GNU General Public License v3.0
168 stars 20 forks source link

LibreOffice helpers still not working #60

Closed amicalmant closed 5 years ago

amicalmant commented 5 years ago

Installation and version

I installed Parlatype first from the Linux Mint repository and, later, from the Ubuntu PPA (https://launchpad.net/~gabor-karsay/+archive/ubuntu/parlatype), both version 1.5.6.

My desktop environment

Issue

The keyboard controls from within Parlatype work fine but the LibreOffice PlayPause and JumpBack macros triggers this error every time I try to use them:

A scripting structure error occurred while running scriptvnd.sun.star.script:Parlatype.py$PlayPause?language=Python&location=share in Python.

Message : <class 'ImportError'>: No module named 'dbus' File "/opt/libreoffice6.1/program/pythonscript.py", line 1047, in getScript mod = self.provCtx.getModuleByUrl( fileUri ) File "/opt/libreoffice6.1/program/pythonscript.py", line 484, in getModuleByUrl exec(code, entry.module.dict) File "/opt/libreoffice6.1/share/Scripts/python/Parlatype.py", line 22, in import dbus File "/opt/libreoffice6.1/program/uno.py", line 347, in _uno_import return _builtin_import(name, *optargs, **kwargs)

Other information

Did it work in the past?

I don't know since I just installed the package yesterday with this configuration.

Other noticeable modules installed:

How to reproduce:

gkarsay commented 5 years ago

First of all I'm sorry for the late answer. I saw it, but your setup is different to mine and I still don't have a clue. Anyway, thank you for the detailed description.

I have to guess: Maybe you need python3-dbus. Is it installed? If no, does sudo apt-get install python3-dbus change anything?

amicalmant commented 5 years ago

I have to guess: Maybe you need python3-dbus. Is it installed? If no, does sudo apt-get install python3-dbus change anything?

Yes it was installed (version 1.2.6-1). In the meantime, I have upgraded to LibreOffice 6.1.4.2, uninstalled and reinstalled Parlatype and its LO macro package. Still crashes and the error message is the same.

Anyway, thank you for the detailed description.

You're welcome. If you cannot reproduce, let's just forget it. I will try again in a couple of years. :-)

gkarsay commented 5 years ago

I could reproduce this on Ubuntu 18.04. Not with LibreOffice from the main archive nor from PPA (https://launchpad.net/~libreoffice/+archive/ubuntu/ppa) but with the deb packages offered by The Document Foundation at https://www.libreoffice.org/download/download/?type=deb-x86_64.

This seems to be the one you used because it's also installed in /opt. Or have you built it from source? The main archive and PPA seem to use the default system python interpreter while this one uses its own shipped python interpreter with a small set of modules. Obviously it doesn't have the dbus module needed. I don't know how to a) make it use the system python interpreter with all its modules or how to b) add a module to the shipped python interpreter.

I'm closing this because I can't support this kind of installation, only the default installation (no matter which distribution). Just for reference, the built-in python interpreter is at /opt/libreoffice6.2/program/python-core-3.5.5. I guess you would have to do something with lib/site.py in that folder to add a module.

amicalmant commented 5 years ago

Sorry, I did not see this earlier. I really appreciate the efforts you made in order to investigate this.

You are right: I don't use the PPA version of LO which is always outdated but the fresh deb version offered by the Foundation.

I am a little deceived that this config is not supported but I don't blame you at all. Thanks for your open source commitment and much appreciated follow up.