首页 > 解决方案 > TypeError:initial() 得到了一个意外的关键字参数“超时”

问题描述

我想使用此代码将数据从 csv 加载到 BigQuery。

df.to_gbq(table_for_uploading, upload_table, project_id=project_id, if_exists='replace', table_schema = [{'name':'execution_date','type': 'DATE'}])

我收到了这个错误

TypeError: initiate() got an unexpected keyword argument 'timeout'

任何人都可以帮助为什么?

标签: pythongoogle-bigquery

解决方案


我怀疑安装 google-resumable-media==0.6 可能会解决您的问题。

pip uninstall google-resumable-media
pip uninstall google-cloud-storage
pip install google-resumable-media==0.6.0
pip install google-cloud-storage==1.30.0

你可以试试。


推荐阅读