我创建了一个Alteryx工作流,在python notebook中运行代码,从web API中提取数据,将API pull的输出存储为dataframe,并尝试通过锚点1将其写入excel文件。当我运行该工作流时,我得到了以下错误:
Jupyter :缓存数据不可用--运行工作流以使输入数据在FileNotFoundError notebook (.\Alteryx_Automation\dsd_runner\jupyterPipes.json)中可用
我是Alteryx的新手,非常感谢您的指导/建议
Here is code that replicates the error and has similar structure to what I have in my notebook
``from ayx import Alteryx
class DataExtract():
def __init__(self):
self.url = 'https://raw.githubusercontent.com/owid/covid-19-data/master/public/data/owid-covid-data.csv'
self.data = dict()
def get_data(self):
self.data['owid'] = pd.read_csv(self.url)
de = DataExtract()
de.get_data()
temp = de.data['owid']
Alteryx.write(temp,1)``发布于 2020-09-02 08:01:48
解决了这个问题,我在python笔记本中发出了一个os.chdir()命令,我的工作目录被更改为一个我没有写权限的目录。解决方法是跟踪当前目录( orig_dir = os.getcwd() ),然后在脚本末尾发出os.chdir(orig_dir)。此外,对class属性进行深拷贝也有助于解决这个问题。
https://stackoverflow.com/questions/63618567
复制相似问题