2021-02-07 22:36:13 -06:00
|
|
|
|
2021-02-07 22:51:44 -06:00
|
|
|
For debug
|
|
|
|
^^^^^^^^^
|
2021-02-07 22:36:13 -06:00
|
|
|
|
|
|
|
**INFO_DEBUG**
|
|
|
|
^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
Show info debug, show in message box.
|
|
|
|
|
|
|
|
.. code-block:: python
|
|
|
|
|
|
|
|
import easymacro as app
|
|
|
|
|
|
|
|
def info():
|
|
|
|
app.msgbox(INFO_DEBUG)
|
|
|
|
return
|
|
|
|
|
|
|
|
Show in shell.
|
|
|
|
|
|
|
|
.. code-block:: python
|
|
|
|
|
|
|
|
import easymacro as app
|
|
|
|
|
|
|
|
def info():
|
|
|
|
app.debug(INFO_DEBUG)
|
|
|
|
return
|
2021-02-07 22:43:49 -06:00
|
|
|
|
|
|
|
|
|
|
|
**Log error**
|
|
|
|
^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
Show error message in shell.
|
|
|
|
|
|
|
|
.. code-block:: python
|
|
|
|
|
|
|
|
import easymacro as app
|
|
|
|
|
|
|
|
def error():
|
|
|
|
msg = 'My error 500'
|
|
|
|
app.error(msg)
|
|
|
|
return
|
|
|
|
|
|
|
|
|
|
|
|
**Log debug**
|
|
|
|
^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
Show debug message in shell.
|
|
|
|
|
|
|
|
.. code-block:: python
|
|
|
|
|
|
|
|
import easymacro as app
|
|
|
|
|
|
|
|
def error():
|
|
|
|
msg = 'Verify this data...'
|
|
|
|
app.debug(msg)
|
|
|
|
return
|
|
|
|
|
|
|
|
|
|
|
|
**Log info**
|
|
|
|
^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
Show info message in shell.
|
|
|
|
|
|
|
|
.. code-block:: python
|
|
|
|
|
|
|
|
import easymacro as app
|
|
|
|
|
|
|
|
def error():
|
|
|
|
msg = 'Start process...'
|
|
|
|
app.info(msg)
|
|
|
|
return
|
2021-02-07 22:51:44 -06:00
|
|
|
|
|
|
|
|
|
|
|
**Call MRI**
|
|
|
|
^^^^^^^^^^^^
|
|
|
|
|
|
|
|
`MRI`_ is the better extension for debug any object in LibreOffice.
|
|
|
|
|
|
|
|
|
|
|
|
.. code-block:: python
|
|
|
|
|
|
|
|
import easymacro as app
|
|
|
|
|
|
|
|
def error():
|
|
|
|
obj = app.active
|
|
|
|
app.mri(obj)
|
|
|
|
return
|
|
|
|
|
|
|
|
|
|
|
|
.. _MRI: https://github.com/hanya/MRI
|