whenever running the below code the variable dictionary and therefore dictionary2 gets assigned old data.
import pymysql dictionary2 = [] charSet = "utf8mb