I am using django iOS notification module and everything works fine but today I tried to add one device to this and it gives me error of column "token" specified more than once As I have used the module and didn't edit this so there no chance that I have defined any extra col. for this.
Error :
ProgrammingError at /admin/ios_notifications/device/add/
column "token" specified more than once
LINE 1: ...otified_at", "platform", "display", "os_version", "token") V...
Environment:
Request Method: POST
Request URL: admin/ios_notifications/device/add/
Django Version: 1.6.2
Python Version: 2.7.3
Installed Applications:
('grappelli',
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'accounts',
'social.apps.django_app.default',
'south',
'mem',
'ios_notifications',
'social_services',
'chat',
'notification',
'django_crontab',
'log')
Installed Middleware:
('django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
'django.middleware.locale.LocaleMiddleware',
'config.lang.SessionBasedLocaleMiddleware')
Traceback:
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/core/handlers/base.py" in get_response
114. response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/contrib/admin/options.py" in wrapper
432. return self.admin_site.admin_view(view)(*args, **kwargs)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/utils/decorators.py" in _wrapped_view
99. response = view_func(request, *args, **kwargs)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/views/decorators/cache.py" in _wrapped_view_func
52. response = view_func(request, *args, **kwargs)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/contrib/admin/sites.py" in inner
198. return view(request, *args, **kwargs)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/utils/decorators.py" in _wrapper
29. return bound_func(*args, **kwargs)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/utils/decorators.py" in _wrapped_view
99. response = view_func(request, *args, **kwargs)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/utils/decorators.py" in bound_func
25. return func(self, *args2, **kwargs2)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/transaction.py" in inner
339. return func(*args, **kwargs)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/contrib/admin/options.py" in add_view
1131. self.save_model(request, new_object, form, False)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/contrib/admin/options.py" in save_model
860. obj.save()
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/models/base.py" in save
545. force_update=force_update, update_fields=update_fields)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/models/base.py" in save_base
573. updated = self._save_table(raw, cls, force_insert, force_update, using, update_fields)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/models/base.py" in _save_table
654. result = self._do_insert(cls._base_manager, using, fields, update_pk, raw)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/models/base.py" in _do_insert
687. using=using, raw=raw)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/models/manager.py" in _insert
232. return insert_query(self.model, objs, fields, **kwargs)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/models/query.py" in insert_query
1511. return query.get_compiler(using=using).execute_sql(return_id)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/models/sql/compiler.py" in execute_sql
899. cursor.execute(sql, params)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/backends/util.py" in execute
69. return super(CursorDebugWrapper, self).execute(sql, params)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/backends/util.py" in execute
53. return self.cursor.execute(sql, params)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/utils.py" in __exit__
99. six.reraise(dj_exc_type, dj_exc_value, traceback)
File "/home/ghrix/MEM/local/lib/python2.7/site-packages/django/db/backends/util.py" in execute
53. return self.cursor.execute(sql, params)
Exception Type: ProgrammingError at /admin/ios_notifications/device/add/
Exception Value: column "token" specified more than once
LINE 1: ...otified_at", "platform", "display", "os_version", "token") V...
^
I am using django iOS notification module and everything works fine but today I tried to add one device to this and it gives me error of column "token" specified more than once As I have used the module and didn't edit this so there no chance that I have defined any extra col. for this.
Error :