""" This function makes sure the user enters a valid block device in /etc/fstab """ import os import re import os.path as osp def validate(userIn): pdb.set_trace() devices = os.listdir('/dev') if osp.split(userIn)[1] in devices: return True return False