Debugging Python Code

Hi @Jorge_Villarroel
Sorry I missed this msg!
Yes, you can use rpw’s console in pycharm just as you would with an embedded script:

import sys
rpw_path = r"C:\Users\gtalarico\AppData\Roaming\Dynamo\Dynamo Revit\1.2\packages\RevitPythonWrapper\extra\rpw.zip"
# Or any location where rpw.zip is stored. This one ^ was installed with the package manager
# but you can also download it form github
sys.path.append(rpw_path)
OUT = 'Test'
import rpw
from rpw.ui.forms import Console
#
#
for i in range(10):
    if i == 5:
        Console(context=locals())

You can read more about it here:
http://revitpythonwrapper.readthedocs.io/en/latest/forms.html#console

3 Likes