After some additional sleuthing I realized I wasn't passing the
'Authorization' header with the contents API request. Thinking this might be
the problem I added the header, but then got the following response in the
console running jupyterhub:
[E 2017-07-22 10:05:45.125 JupyterHub web:1590] Uncaught exception GET
/hub/user/millejoh/api/contents/ (::ffff:127.0.0.1)
HTTPServerRequest(protocol='http', host='
127.0.0.1:8000', method='GET',
uri='/hub/user/millejoh/api/contents/', version='HTTP/1.1',
remote_ip='::ffff:127.0.0.1', headers={'X-Forwarded-Host': '
127.0.0.1:8000',
'X-Forwarded-Proto': 'http', 'X-Forwarded-Port': '8000', 'X-Forwarded-For':
'::ffff:127.0.0.1', 'Authorization': 'token
bb5e49ad68dc4f5abdaccd954abb8742', 'X-Xsrftoken':
'2|d136b4d2|ee8d84ef6c536241a6e09c36453a9328|1497490250', 'Cookie':
'_xsrf=2|d136b4d2|ee8d84ef6c536241a6e09c36453a9328|1497490250',
'Accept-Encoding': 'deflate, gzip', 'Accept': '*/*', 'User-Agent':
'curl/7.54.0', 'Host': '
127.0.0.1:8000', 'Connection': 'close'})
Traceback (most recent call last):
File
"/home/millejoh/miniconda3/envs/jupyterhub/lib/python3.6/site-packages/torna
do/web.py", line 1511, in _execute
result = yield result
File
"/home/millejoh/miniconda3/envs/jupyterhub/lib/python3.6/site-packages/jupyt
erhub/handlers/base.py", line 520, in get
if current_user.spawner:
AttributeError: 'User' object has no attribute 'spawner'
[E 2017-07-22 10:05:45.223 JupyterHub log:99] {
"X-Forwarded-Host": "
127.0.0.1:8000",
"X-Forwarded-Proto": "http",
"X-Forwarded-Port": "8000",
"X-Forwarded-For": "::ffff:127.0.0.1",
"Authorization": "token [secret]",
"X-Xsrftoken":
"2|d136b4d2|ee8d84ef6c536241a6e09c36453a9328|1497490250",
"Cookie":
"_xsrf=2|d136b4d2|ee8d84ef6c536241a6e09c36453a9328|1497490250",
"Accept-Encoding": "deflate, gzip",
"Accept": "*/*",
"User-Agent": "curl/7.54.0",
"Host": "
127.0.0.1:8000",
"Connection": "close"
}
[E 2017-07-22 10:05:45.225 JupyterHub log:100] 500 GET
/hub/user/millejoh/api/contents/ (millejoh@::ffff:127.0.0.1) 96.56ms