Compute Questions
Software Questions
Data Questions
Why aren’t directories showing up in JupyterHub?
There have been issues on ZFS where directories don’t show up in JupyterHub - particularily in /zfs/projects/faculty
and /zfs/projects/students
. We’re looking for a permanent fix, but for now, we’ve found some options to resolve this issue.
Option 1: Using jupyterlist
We’ve added a helpful command line tool to fix this. If you open up a terminal in JupyterHub, and execute the command jupyterlist
, it should show the directories for you.
Option 2: Adding an ipython
startup script
You can add .py
scripts to run before any iPython kernels start - we can use this functionality to show all directories.
- First, navigate to
~/.ipython/profile_default/startup/
- Next, open up your favorite file editor, and create a
.py
file with the following code:
import os
dirs = ["/zfs/projects/faculty/"+dir for dir in os.listdir("/zfs/projects/faculty/")] + ["/zfs/projects/students/"+dir for dir in os.listdir("/zfs/projects/students/")]
for directory in dirs:
try:
os.listdir(directory)
except:
print("oh no")
- Save this file - the filename doesn’t matter, so long as it ends in
.py
. - When you start JupyterHub, open a kernel (a notebook or a console), and the directories should appear!
Connect with us