I have the following lines of code:
sql = \"source C:\\\\My Dropbox\\\\workspace\\\\projects\\\\hosted_inv\\\\create_site_db.sql\"
cursor.execute (sql)
As others said, you cannot use the command source in MySQLdb Python API
So, instead of running that, load the file and execute it
Lets say your .sql file has
create database test;
Read the content like
sql=open("test.sql").read()
And then execute it
cursor.execute(sql);
You will get new database "test"