When finding a solution to a problem by exploratory programming in a REPL I find it very useful to use print statements to build a log and provide insights into application state and flow.
Unfortunately ArcMap's Python Console seems to go silent after calling some of the geoprocessing tools.
>>> print("test 1") ... arcpy.ExcelToTable_conversion(source_path, target_sheet, source_sheet) ... print("test 2") ... test 1 >>>
While if I remove the call to the Excel To Table tool:
>>> print("test 1") ... pass ... print("test 2") ... test 1 test 2
How can I reliably print to the console or otherwise work around this issue?
I am running:
- ArcGIS Desktop 10.3.1.4959
I have read the following QAs on print or messaging in ArcPy but haven't found one that matches the use case of using the Python Console: