To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=113507
                 Issue #|113507
                 Summary|Cannot call Python macro from Basic macro when running
                        | headless
               Component|framework
                 Version|OOO320m18
                Platform|Unknown
                     URL|
              OS/Version|All
                  Status|UNCONFIRMED
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P3
            Subcomponent|scripting
             Assigned to|ab
             Reported by|shrib





------- Additional comments from sh...@openoffice.org Wed Jul 28 23:24:29 +0000 
2010 -------
I have a text document t.odt with both a Basic macro (CallFoo) and a Python
macro (foo). The Basic macro calls the Python macro as such:

Sub CallFoo
    Set dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")
    Set frame = ThisComponent.CurrentController.Frame
    Call dispatcher.executeDispatch( _
        frame, _
        "vnd.sun.star.script:stub.py$foo?language=Python&location=document", _
        "", _
        0, _
        Array())
End Sub

When I run the Basic macro from the UI, it does successfully call the Python 
macro. 

When I run the Basic macro from the command line by specifying an argument of
"macro://t/Standard.Module1.CallFoo", I get prompted for whether I want to
Enable or Disable macros. If I click "Enable", the Python macro gets called.

What does not work is if I specify "macro://t/Standard.Module1.CallFoo" on the
command line and also "-headless". In that case, OOo just hangs. The backtraces
of all the threads is shown below. The reason I do not specify the Python macro
on the command line is that it is not supported (bug 113481). 

Is there any workaround to using Python macros in an automated pipeline?

PS: I dont see a way to attach a file to the issue. Ctrl-F in my browser also
did not find the word "attach", so it does not seem like I am just not seeing 
it.

-----------------------------------------------------

(gdb) thread apply all bt

Thread 6 (Thread 0x41bf9950 (LWP 8561)):
#0  0x00007f29cd790e1d in pthread_cond_timedwait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
#1  0x00007f29d4c385c0 in ?? () from
/opt/openoffice.org3/program/../basis-link/ure-link/lib/libuno_sal.so.3
#2  0x00007f29cd78c3f7 in start_thread () from /lib/libpthread.so.0
#3  0x00007f29cdc7dbbd in clone () from /lib/libc.so.6
#4  0x0000000000000000 in ?? ()

Thread 5 (Thread 0x4089b950 (LWP 8574)):
#0  0x00007f29cd790e1d in pthread_cond_timedwait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
#1  0x00007f29d4c0f0f7 in osl_waitCondition ()
   from /opt/openoffice.org3/program/../basis-link/ure-link/lib/libuno_sal.so.3
#2  0x00007f29ce8c0582 in vos::OTimerManager::run() ()
   from /opt/openoffice.org3/program/../basis-link/program/libvos3gcc3.so
#3  0x00007f29ce8be8ba in vos::threadWorkerFunction_impl(void*) ()
   from /opt/openoffice.org3/program/../basis-link/program/libvos3gcc3.so
#4  0x00007f29d4c12568 in ?? () from
/opt/openoffice.org3/program/../basis-link/ure-link/lib/libuno_sal.so.3
#5  0x00007f29cd78c3f7 in start_thread () from /lib/libpthread.so.0
#6  0x00007f29cdc7dbbd in clone () from /lib/libc.so.6
#7  0x0000000000000000 in ?? ()

Thread 4 (Thread 0x423fa950 (LWP 8575)):
#0  0x00007f29cdc7e72b in accept () from /lib/libc.so.6
#1  0x00007f29d4c19452 in osl_acceptPipe ()
   from /opt/openoffice.org3/program/../basis-link/ure-link/lib/libuno_sal.so.3
#2  0x00007f29ce8c38ca in vos::OPipe::accept(vos::OStreamPipe&) ()
   from /opt/openoffice.org3/program/../basis-link/program/libvos3gcc3.so
#3  0x00007f29d49be6b1 in ?? () from
/opt/openoffice.org3/program/../basis-link/program/libsofficeapp.so
#4  0x00007f29ce8be8ba in vos::threadWorkerFunction_impl(void*) ()
   from /opt/openoffice.org3/program/../basis-link/program/libvos3gcc3.so
#5  0x00007f29d4c12568 in ?? () from
/opt/openoffice.org3/program/../basis-link/ure-link/lib/libuno_sal.so.3
#6  0x00007f29cd78c3f7 in start_thread () from /lib/libpthread.so.0
#7  0x00007f29cdc7dbbd in clone () from /lib/libc.so.6
#8  0x0000000000000000 in ?? ()

Thread 3 (Thread 0x42bfb950 (LWP 8576)):
#0  0x00007f29cdc74cf6 in poll () from /lib/libc.so.6
#1  0x00007f29c933072a in ?? () from
/opt/openoffice.org/basis3.2/program/libvclplug_genlx.so
#2  0x00007f29d4c12568 in ?? () from
/opt/openoffice.org3/program/../basis-link/ure-link/lib/libuno_sal.so.3
#3  0x00007f29cd78c3f7 in start_thread () from /lib/libpthread.so.0
#4  0x00007f29cdc7dbbd in clone () from /lib/libc.so.6
#5  0x0000000000000000 in ?? ()

Thread 2 (Thread 0x433fc950 (LWP 8580)):
#0  0x00007f29cdc74cf6 in poll () from /lib/libc.so.6
#1  0x00007f29c92c98f7 in x11::SelectionManager::dispatchEvent(int) ()
   from /opt/openoffice.org/basis3.2/program/libvclplug_genlx.so
#2  0x00007f29c92c9a56 in x11::SelectionManager::run(void*) ()
   from /opt/openoffice.org/basis3.2/program/libvclplug_genlx.so
#3  0x00007f29d4c12568 in ?? () from
/opt/openoffice.org3/program/../basis-link/ure-link/lib/libuno_sal.so.3
#4  0x00007f29cd78c3f7 in start_thread () from /lib/libpthread.so.0
#5  0x00007f29cdc7dbbd in clone () from /lib/libc.so.6
#6  0x0000000000000000 in ?? ()

Thread 1 (Thread 0x7f29d51ca6f0 (LWP 8560)):
#0  0x00007f29cdc74cf6 in poll () from /lib/libc.so.6
#1  0x00007f29c95a44f2 in ?? () from /usr/lib/libglib-2.0.so.0
#2  0x00007f29c95a4b7b in g_main_context_iteration () from 
/usr/lib/libglib-2.0.so.0
#3  0x00007f29cc04a66f in ?? () from
/opt/openoffice.org/basis3.2/program/libvclplug_gtklx.so
#4  0x00007f29d1b546ee in Application::Yield(bool) ()
   from /opt/openoffice.org3/program/../basis-link/program/libvcllx.so
#5  0x00007f29d1b547c7 in Application::Execute() () from
/opt/openoffice.org3/program/../basis-link/program/libvcllx.so
#6  0x00007f29d498b494 in ?? () from
/opt/openoffice.org3/program/../basis-link/program/libsofficeapp.so
#7  0x00007f29d1b59f26 in ?? () from
/opt/openoffice.org3/program/../basis-link/program/libvcllx.so
#8  0x00007f29d1b5a015 in SVMain() () from
/opt/openoffice.org3/program/../basis-link/program/libvcllx.so
#9  0x00007f29d49c740c in soffice_main () from
/opt/openoffice.org3/program/../basis-link/program/libsofficeapp.so
#10 0x000000000040118b in main ()

---------------------------------------------------------------------
Please do not reply to this automatically generated notification from
Issue Tracker. Please log onto the website and enter your comments.
http://qa.openoffice.org/issue_handling/project_issues.html#notification

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@framework.openoffice.org
For additional commands, e-mail: issues-h...@framework.openoffice.org


---------------------------------------------------------------------
To unsubscribe, e-mail: allbugs-unsubscr...@openoffice.org
For additional commands, e-mail: allbugs-h...@openoffice.org

Reply via email to