在过去一个月左右的时间里,我每天都使用以下代码来提取SP列表并连接到另一个数据源
from shareplum import Site
from shareplum import Office365
import pandas as pd
authcookie = Office365('https://COMPANY.sharepoint.com', username='SharePointAdmin@COMPANY.com', password='ADMINPW').GetCookies()
. . .
然而,它似乎自发地损坏了,现在我得到了错误:
Exception: Check username/password and rootsite
我没有足够的Python或sharepoint知识来理解这个错误到底是谁造成的。似乎是一个身份验证问题,但它工作得很好,我们的SP人员说什么都没有改变。
发布于 2020-05-12 12:36:35
连接到Office 365时,请添加以下参数:
authcookie = Office365(base_path, username=username, password=password).GetCookies()
site = Site('https://my.sharepoint.com/sites/sbdev',version=Version.v365, authcookie=authcookie)这里有一个演示,你可以参考一下:downloadfile.py
https://stackoverflow.com/questions/61733758
复制相似问题