Search code examples
pythongoogle-sheetsgspread

gspread spreadsheet not loading, no errors


I am writing a python script using gspread. Here is the code:

json_key = json.load(open('<path to json>'))
scope = ['https://spreadsheets.google.com/feeds']
credentials = SignedJwtAssertionCredentials(json_key['client_email'], json_key['private_key'], scope)
gc = gspread.authorize(credentials)

print "0"
worksheet = gc.open("<name of sheet>").get_worksheet(2)
print "1"

The 0 is printed so that means the credentials and everything are loading. But, when I try to load the actual sheet, with the actual name where it says "name of sheet", it doesn't actually work. Nothing happens, and there are no errors, and it never prints 1. Am I doing something wrong? I don't think I am cause I have used this exact code for weeks, and I am suddenly having a problem.


Solution

  • gdata spreadsheets API is hanging

    https://code.google.com/a/google.com/p/apps-api-issues/issues/detail?id=3939

    https://github.com/burnash/gspread/issues/278

    The api is down right now.