check for built css as well in data-files lookup

avoids serving incomplete files
This commit is contained in:
Min RK
2017-11-07 11:36:05 +01:00
parent 8a95066b2e
commit b953ac295b

View File

@@ -13,7 +13,8 @@ def get_data_files():
# walk up, looking for prefix/share/jupyter # walk up, looking for prefix/share/jupyter
while path != '/': while path != '/':
share_jupyter = join(path, 'share', 'jupyter', 'hub') share_jupyter = join(path, 'share', 'jupyter', 'hub')
if exists(join(share_jupyter, 'static', 'components')): static = join(share_jupyter, 'static')
if all(exists(join(static, f)) for f in ['components', 'css']):
return share_jupyter return share_jupyter
path, _ = split(path) path, _ = split(path)
# didn't find it, give up # didn't find it, give up