Extracts a file from a bytes_io zip. Returns bytes

def extract_file_from_zip(bytes_io, expected_file):
    """Extracts a file from a bytes_io zip. Returns bytes"""
    zipf = zipfile.ZipFile(bytes_io) 
    return zipf.read(expected_file)