我可以使用 gspread 成功创建 sheet 数据,但 notify/email 用户的功能不再有效。这里的错误在哪里?

I can successfully create a sheet with gspread with the data but the functionality to notify/email the users no longer works. Where's the error here?

通知用户传播sheet创建的功能不工作。它曾经有效,我在文档中注意到它已于 2019 年 9 月 24 日更新,所以这可能是版本问题?

我已经根据文档在通知部分尝试了 True/yes 的变体:https://buildmedia.readthedocs.org/media/pdf/gspread-pandas/latest/gspread-pandas.pdf - 第 13 页

my_test_spread = Spread("My_sheet_"+date_format, create_spread=True, scope=['openid', 'https://www.googleapis.com/auth/drive', 'https://www.googleapis.com/auth/userinfo.email', 'https://www.googleapis.com/auth/spreadsheets'], creds=credentials,  permissions=["bob@test.co.uk|writer|True","roger@test.co.uk|writer|True","emily@test.co.uk|writer|True" ])

my_test_spread.df_to_sheet(control, index=False, sheet='Control', start='A1', replace=True)

我希望用户 roger、bob 和 emily 收到有关创建 sheet

的电子邮件

编辑

我也在 gspread-pandas 包装器之外尝试过这个,只是 gspread。 我尝试了下面的 share 方法和 insert_permission 方法。都没有工作!

gc = gspread.authorize(credentials2)
sh = gc.open("My_sheet_"+date_format)
sh.share("bob@test.co.uk" ,perm_type="user" , role="writer",notify="True" ,email_message ="Here is this weeks list")
gc.insert_permission(sh.id, "bob@test.co.uk", perm_type="user", role="writer", notify=True, email_message="Here is this weeks list")

所以我什么也没做,现在可以用了。我假设包更新或什么? 我收到了三封电子邮件,因此每个单独的方法:shareinsert_permissionSpread 的默认方法现在都可以使用了!