【发布时间】:2020-09-21 11:42:38
【问题描述】:
有什么方法可以在您的转换代码中引入调试语句,以便您稍后可以在驱动程序日志中看到它们?还是引发异常是唯一的方法?
【问题讨论】:
标签: palantir-foundry foundry-code-repositories
有什么方法可以在您的转换代码中引入调试语句,以便您稍后可以在驱动程序日志中看到它们?还是引发异常是唯一的方法?
【问题讨论】:
标签: palantir-foundry foundry-code-repositories
是的,从 transforms-python 1.9.0 驱动程序日志写入事务开始,这是可能的。您可以使用python logging 写入日志。 例如:
import logging
log = logging.getLogger(__name__)
def my_transform(input):
log.info("Testing logging")
return input
【讨论】: