On Sat, Jun 8, 2013 at 2:13 AM, Brooks, Phil wrote:
> Hi,
>
> I am trying to figure out how to install Pyclewn so that it will
> work with an embedded Python interpreter in an application.  The
> specific tool I am trying to install it with is Sage - the open
> source math analysis tool (www.sagemath.org).  It builds its own
> Python interpreter and the application itself consists of a large
> number of math extensions to Python.  I would like to be able to run
> Pyclewn on the Sage Python interpreter as it runs its Python
> scripts.


Hi Phil,

The following page describes how to debug a sage script with pdb:

http://www.sagemath.org/doc/reference/cmd/sage/misc/trace.html

According to this, you run your script through pexpect after having
inserted "import pdb; pdb.set_trace()". If this works, then you should
be able to use pyclewn by inserting instead
    import clewn.vim as vim; vim.pdb()
and attaching to the pexpect process with ":Pyclewn pdb" as described
in pyclewn documentation.

Note: if the pyclewn installation is local, insert

    import sys, os; sys.path.append(os.path.join(os.environ['HOME'],
'lib/python'))
    import clewn.vim as vim; vim.pdb()


-- 
Xavier

Les Chemins de Lokoti: http://lokoti.alwaysdata.net

------------------------------------------------------------------------------
How ServiceNow helps IT people transform IT departments:
1. A cloud service to automate IT design, transition and operations
2. Dashboards that offer high-level views of enterprise services
3. A single system of record for all IT processes
http://p.sf.net/sfu/servicenow-d2d-j
_______________________________________________
Pyclewn-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/pyclewn-general

Reply via email to