I have a git repository for django code. Python version 2.6 and django version 1.4. Today accidentally from my home computer I tried to start the django app with python 2.7.3 and something strange happened. I have lost all the data from my data tables. I am not sure if the clash of versions is the cause or something else. How can I find out why the tables are empty? could it be a mysql problem? what would be the best strategy to debug this? The data is not that important but I would not like this to happen again.
Share
The only way I can see short of thoroughly debugging the Django installation would be to set MySQL to logging everything, through the
logfacility inmy.cnf:then restoring the data, then restarting MySQL so that the logging is in effect, and attempting again with Python 2.7.4. The data should disappear again, but this time you’ll see what commands where issued in the log file.
Armed with those commands, you can try and see where they are in the Django code.
A complete disappearance looks like a recreation of the Model structure, which means that somehow the system did not recognize the data as being there. I am not aware of any Python or Django issues to cause this.
Are you sure you didn’t just issue a flush/reset command?