Python Flask, SQLIte, and CSV: How To Perform Transformation Function on Data In Column of CSV When Reading From CSV

Solution
insert_records = "INSERT INTO Users(email, password) VALUES(?, ?)"

with open('data/Users.csv') as file:
    contents = csv.reader(file)
    next(contents) # skip header row

    # LIST OF TUPLES WITH HASH CONVERSION ON SECOND ITEM
    params = [(row[0], hashlib.md5(row[1].encode())) for row in contents]
    cursor.executemany(insert_records, params)