import gspread
from oauth2client.service_account import ServiceAccountCredentials
scope = ['https://www.googleapis.com/auth/spreadsheets.readonly']
creds =
ServiceAccountCredentials.from_json_keyfile_name('creds.json',scope)
client = gspread.authorize(creds)
print(client)
我能够创建一个客户端对象但是当我尝试读取任何工作表时,我得到了这个无用的错误
gspread.exceptions.RequestError:(401,' 401:b \' \ n \ n提示无效 - AuthSub令牌的范围错误\ n \ n \ n
令牌无效 - AuthSub令牌的范围错误
\ n错误401
\ n \ n \ n \'')