Hi!
I’m having trouble using ASANA API on a PythonAnywhere website, this works perfectly locally, and on their python 3.7 shell.
but, when Ran on the server I can use my API key, and confirm authentication - after that it halts.
import asana
@action('index', method=['GET', 'POST'])
def index():
user = auth.get_user()
message = T("Hello {first_name}".format(**user))
key = "MYKEY"
asana_api = asana.Client.access_token(key)
print("asana_api, ",asana_api)
print(asana_api.session.authorized)
me = asana_api.users.me() #halts on this line, or any use of the asana_api
return dict(message=message)
my console logs are
2021-02-08 22:24:37 asana_api, <asana.client.Client object at 0x7f536c5f0750>
2021-02-08 22:24:37 True
and the webpage stalls until it eventually times out.
This will also time out,
for workspace in asana_api.workspaces.find_all():
print ("workspace, ",workspace)
workspace_gid = workspace.get('gid')
pretty much any ASANA API call except for the ones shown above will time out…
Thanks so much! Willing to provide any other necessary details