Cannot instantiate SlideRenderer service from python script

Hi!

I'm trying to automate the rendering of presentation slides from a python
script, but stumbling upon a cryptic message "null process service factory".

Here is the server invocation command:

And here is a minimal python script:

As stated above, the script crashes on the last line with a
DeploymentException: "null process service factory"

What am I missing?

Thanks!
Thomas

PS: I'm also trying with the GraphicExportFilter, facing other problems (see
separate message)

Forgot to mention I'm using LibreOffice 4.0.4 from CentOS repositories.

Hi,

Can you please upload the 2 files you attached and leave a quick mail with the links to it? I can't help, but it makes things lots easier for other :slight_smile:

Liebe Grüße, / Yours,
Florian Reisinger

Hi,

Well, I don't really see how it makes things any easier, but for folks who
prefer downloading to copy/pasting, here are the links :slight_smile:

invoke-server (shell script)
<https://drive.google.com/file/d/0By-h0KPo01P2Mk51SU9pTHlvRFE/edit?usp=sharing>
test-sliderenderer.py
<https://drive.google.com/file/d/0By-h0KPo01P2bTcxNkgxZ19FcUk/edit?usp=sharing>

Thanks again
Thomas

Hi!

Just to let everybody know that I have finally spotted the mistake.

Instead of

I should have written

i.e. using the remote context instead of the local one.

Thomas

Hi :slight_smile:
Many thanks for posting the answer back to this mailing-list. That is
likely to greatly improve the chances of people finding the fix for it when
it crops up again.

Oddly the coding brackets meant that my emailing system just left great big
empty gaps so it was only when i used Nabble that i was able to see the
answer. So i am going to try pasting the post into this email to see if
that fixes it for other people using the same system as me;

"Hi!

Just to let everybody know that I have finally spotted the mistake.

Instead of

renderer =
localContext.ServiceManager.createInstanceWithContext("com.sun.star.drawing.SlideRenderer",
localContext)

I should have written

renderer =
context.ServiceManager.createInstanceWithContext("com.sun.star.drawing.SlideRenderer",
context)

i.e. using the remote context instead of the local one.

Thomas"

Congrats and regards from
Tom :slight_smile: