python API s.close()时报错误 undef table 'TMP_TBL_8ab853c7' got an exception:

s.close()报的错,不需要手动关闭吗

undef table 'TMP_TBL_8ab853c7' got an exception: 

<Exception> in run: Couldn't send script/function to the remote host because the connection has been closed

请先 登录 后评论

1 个回答

haaha

是因为close之前没有取消本地变量对server端对象的引用,如tb=s.loadTable("day","dfs://day"),close()之前让tb = None,取消本地变量对server端对象的引用,就可以了

请参考pythonapi上传的数据表的生命周期

https://gitee.com/dolphindb/api_python3#23-%E4%B8%8A%E4%BC%A0%E7%9A%84%E6%95%B0%E6%8D%AE%E8%A1%A8%E7%9A%84%E7%94%9F%E5%91%BD%E5%91%A8%E6%9C%9F

请先 登录 后评论