def is_block_device(filepath):
    mode = os.stat(filepath).st_mode
    return stat.S_ISBLK(mode)
Check whether `filepath` is a block device.
dataset/ETHPy150Open openstack/bareon/bareon/utils/hardware.py/is_block_device