FS#16636 - [go-openoffice] python uno broken
Attached to Project:
Arch Linux
Opened by Francisco Pina (Stunts) - Wednesday, 14 October 2009, 08:11 GMT
Last edited by Andreas Radke (AndyRTR) - Thursday, 13 May 2010, 10:19 GMT
Opened by Francisco Pina (Stunts) - Wednesday, 14 October 2009, 08:11 GMT
Last edited by Andreas Radke (AndyRTR) - Thursday, 13 May 2010, 10:19 GMT
|
Details
Description:
Python-uno seems to be broken on go-openoffice. I have found out about this issue using bibus, which can be found in AUR (http://aur.archlinux.org/packages.php?ID=8069). Initially I tought the problem was in Bibus itself, and submitted a bug in Sourceforge. However, after attempting several thing with the help of the author it seems that the problem is in go-oo itself. You can follow the bug report here: http://sourceforge.net/tracker/?func=detail&atid=657832&aid=2824340&group_id=110943 . It seems to be working just fine in Ubuntu's go-oo. Additional info: * package version(s) At least since version 3.1.0.98, but current version is still affected (3.1.1.3-1). I have tested in both x86_64 and i686. Steps to reproduce: As in the Sourceforge bug report: $export PYTHONPATH=/usr/lib/go-openoffice/basis-link/program $export LD_LIBRARY_PATH=/usr/lib/go-openoffice/basis-link/program:/usr/lib/go-openoffice/basis-link/ure-link/lib $export URE_BOOTSTRAP=file:///usr/lib/go-openoffice/program/fundamentalrc $python >>> import uno >>> from com.sun.star.util import URL (1st error) >>> uno.getClass("com.sun.star.util.URL") (error again) Thanks in advance. |
This task depends upon
I'll dig a bit into it and see what I can find.
Thanks for your feedback anyway, but please don't close this just yet.
I think it might be http://packages.ubuntu.com/source/karmic/openoffice-python
but I'm not experienced enough to be sure or make it work on Arch...
Any chance you could please look into it? Thanks.
I will just do something first - download and compile the vanilla go-oo and see if python uno also fails there (they will probably ask me to do it anyway).
I will repost back once I've done that (I am already downloading it).
Thank you for your time.
https://bugzilla.novell.com/show_bug.cgi?id=561162
Let's see where it goes from here.
Upstream seems to believe that it's a packaging issue...
Where do we go from here?
in vanilla OOo the ./configure has a line that reads: "--with-system-python\".
This is missing from the go-oo PKGBUILD. I have also noticed that the go-oo PKGBUILD is much more spartan then vanilla OOo, so this might just be an unnecessary step in the go-oo PKGBUILD.
Do you thing this could be related to it?
The problem remains, so that is not it...
and most distro build ooptions are hidden and preset in go-oo:
http://cgit.freedesktop.org/ooo-build/ooo-build/tree/distro-configs/ArchLinux.conf.in?id=OOO_BUILD_3_1_1_5
you can change them or overwrite in configure. i still have no clue if it fails because go-oo is built using a different system lib and the vanilla against one internal. if not i assume a bug present only in go-oo code.
Do I just pass the option --disable-system-python to ./configure?
I've checked the link you provided and I have found an interesting pattern:
Neither Ubuntu nor Suse use the option "--with-system-python", like it is present in Arch.
So I'm guessing this is a likely culprit. How can I override the option? What arguments should I pass to ./configure in the PKGBUILD in order to revert to using internal python?
Got any more tips? At least some resource I can research myself. Your last link (despite providing me with lots of info regarding the building of go-oo) was not enough for me to be able to figure it out (or maybe I'm just too inexperienced in building stuff from source). Can you think of anywhere I can start searching, so this bug can finally get closed?
Thanks again.
"checking which python to use... internal"
Good luck and a lot of cpu cycles ;)
I'm working on it right now.
I'll post back the results.
configure: WARNING: unrecognized options: --with-build-version, --with-dict, --disable-ldap, --enable-lockdown, --with-system-boost, --with-system-cairo, --enable-crashdump, --without-gpc, --enable-opengl, --enable-minimizer, --enable-presenter-console, --enable-pdfimport, --enable-wiki-publisher, --enable-ogltrans, --with-ant-home, --with-system-saxon, --with-saxon-jar, --with-system-beanshell, --with-system-vigra, --with-system-altlinuxhyph, --with-system-lpsolve, --without-system-python, --without-stlport.
And I don't see "checking which python to use... internal" anywhere. Not even a line with "checking which python to use... system".
What am I doing wrong?
It's still happily going on. I'll probably leave it at it all night.
I got the exact same error.
I have found a workaround tough. It's really very crude and I don't like using it, but it does get the job done.
I have traced back the python error and it comes down to setting the URE_BOOTSTRAP variable. Thus, I just went to /usr/lib/go-openoffice/basis-link/program/uno.py and commented out line 36, replacing it with a '' not to break the indentation in the "if" condition.
Fact is that it's now working. But I don't know what else I might have broken...
So, any more suggestions on the build options?
If I run go-oo's python, I also get an error, here's how:
$/usr/lib/go-openoffice/program/python
>>>import uno
>>> from com.sun.star.util import URL
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/go-openoffice/basis-link/program/uno.py", line 301, in _uno_import
raise ImportError( "type "+ name + "." +x + " is unknown" )
ImportError: type com.sun.star.util.URL is unknown
This of course, after resetting "/usr/lib/go-openoffice/basis-link/program/uno.py" back to the original.
This means that it's not python's fault, since using go-oo's python I get the error too.
Before I go to issuezilla, just to be sure I don't get an answer like Novell's, do you suspect any other culprit?
http://qa.openoffice.org/issues/show_bug.cgi?id=109024
Hope it gets sorted out this time.
I'll do some research on builds, patches, etc, and see what I can come up with...
open oowriter -> Tools -> Macros -> Run Macro -> OpenOffice.Org Macros -> pythonSamples -> TableSample -> createTable -> Run
This will run /usr/lib/go-openoffice/basis3.2/share/Scripts/python/pythonSamples/TableSample.py with no problems.
I just tried the test case in the new Ubuntu 10.04 and it's also there! (they are using version 3.2.0 of go-oo)
However, in there, Bibus works "out of the box".
It is strange that the guys form Novell told me they had no issues with it...
So... Now what?
I guess it's safe to close this one. Thanks for your support.
I must add that I have learned a lot with this bug report nevertheless.