python - Django Incorrect integer value: 'True' for column 'is_superuser' at row 1 -


I have used the library to implement history tracking in one of my Django projects and I have not changed To start transferring my project to the Google application engine with Cloud SQL, now the Boolean field with the following warning appears to be unsuccessful:

  / admin / at the wrong integer value Warning: 'is_s in line 1 'True' line 1 for uperuser ''  

Below this code, there is a problem in the simple_history / models.py file, which breaks into model if there is no boolean field in the model Is:

  Def create_historical_record (self, example, type): history_user = getattr (e.g., '_history_user', none) manager = getattr (e.g., auto.management_name) attrs = {} example In the field for. _meta.fields: attrs [field.attname] = Getattr (example, field.attname) manager.create (history_type = type, history_user = history_user, ** attrs)  

on my machine Works but Google app engine breaks please suggest.

Update: Resolved

The MySQLdb library was optimized in my case. Commenting on the "Boolean type: Bull 2 ​​STR" line, the bullion was removed from the integer conversion in the converwer-skip.

As far as I know that Google Cloud Django was supporting version 1.4, this is the reason Maybe, after the Django 1.5 boolean, the field has been changed to 0 on the right / wrong.

Let me suggest you to change your local DJ edition to 1.4 and try.


Comments

Popular posts from this blog

java - Can't add JTree to JPanel of a JInternalFrame -

javascript - data.match(var) not working it seems -

javascript - How can I pause a jQuery .each() loop, while waiting for user input? -