{"action":"opened","issue":{"url":"https://api.github.com/repos/coleifer/wtf-peewee/issues/26","labels_url":"https://api.github.com/repos/coleifer/wtf-peewee/issues/26/labels{/name}","comments_url":"https://api.github.com/repos/coleifer/wtf-peewee/issues/26/comments","events_url":"https://api.github.com/repos/coleifer/wtf-peewee/issues/26/events","html_url":"https://github.com/coleifer/wtf-peewee/issues/26","id":58321205,"number":26,"title":"Default value","user":{"login":"ak04nv","id":73960,"avatar_url":"https://avatars.githubusercontent.com/u/73960?v=3","gravatar_id":"","url":"https://api.github.com/users/ak04nv","html_url":"https://github.com/ak04nv","followers_url":"https://api.github.com/users/ak04nv/followers","following_url":"https://api.github.com/users/ak04nv/following{/other_user}","gists_url":"https://api.github.com/users/ak04nv/gists{/gist_id}","starred_url":"https://api.github.com/users/ak04nv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ak04nv/subscriptions","organizations_url":"https://api.github.com/users/ak04nv/orgs","repos_url":"https://api.github.com/users/ak04nv/repos","events_url":"https://api.github.com/users/ak04nv/events{/privacy}","received_events_url":"https://api.github.com/users/ak04nv/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-02-20T08:11:02Z","updated_at":"2015-02-20T08:11:02Z","closed_at":null,"body":"I use wtf-peewee in my flask application and I found nice issue. Actually this is not a bug.\r\n```python\r\n    form = ModelForm(request.form)\r\n    if form.validate():\r\n        obj = Model(**form.data)\r\n        obj.active = True  # WTForms issue?\r\n        obj.save()\r\n```\r\nIn my case POST data form hasn't `active` field and the `validate()` method of the `form` sets the `False` value to the same attribute of object. But in my peewee model this field has a `True` value as default in database schema.\r\nKeep it in mind ;-)"}}