Project

General

Profile

Bug #5201

relation "django_journal_tag" does not exist

Added by Jérôme Schneider over 9 years ago. Updated over 9 years ago.

Status:
Rejeté
Priority:
Normal
Assignee:
Target version:
-
Start date:
22 July 2014
Due date:
% Done:

0%

Estimated time:
Patch proposed:
No
Planning:

Description

Lorsqu'on essai de sauvegarder le dossier patient ou dans cette example le PatientAddress on a cette erreur :

DatabaseError at /cmpp/dossiers/17860/address/new
relation "django_journal_tag" does not exist
LINE 1: ...urnal_tag"."id", "django_journal_tag"."name" FROM "django_jo...
                                                             ^

Request Method: POST
Request URL: http://127.0.0.1:8000/cmpp/dossiers/17860/address/new

Traceback:
File "/usr/lib/python2.7/dist-packages/django/core/handlers/base.py" in get_response
  113.                         response = callback(request, *callback_args, **callback_kwargs)
File "/usr/lib/python2.7/dist-packages/django/contrib/auth/decorators.py" in _wrapped_view
  25.                 return view_func(request, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/django/views/generic/base.py" in view
  68.             return self.dispatch(request, *args, **kwargs)
File "/home/jschneider/apps/calebasse/calebasse/cbv.py" in dispatch
  57.         result = super(ServiceViewMixin, self).dispatch(request, **kwargs)
File "/usr/lib/python2.7/dist-packages/django/views/generic/base.py" in dispatch
  86.         return handler(request, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/django/views/generic/edit.py" in post
  199.         return super(BaseCreateView, self).post(request, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/django/views/generic/edit.py" in post
  165.             return self.form_valid(form)
File "/home/jschneider/apps/calebasse/calebasse/dossiers/views.py" in form_valid
  132.         patientaddress = form.save()
File "/usr/lib/python2.7/dist-packages/django/forms/models.py" in save
  370.                              fail_message, commit, construct=False)
File "/usr/lib/python2.7/dist-packages/django/forms/models.py" in save_instance
  87.         instance.save()
File "/home/jschneider/apps/calebasse/calebasse/dossiers/models.py" in save
  296.         super(PatientAddress, self).save(**kwargs)
File "/usr/lib/python2.7/dist-packages/django/db/models/base.py" in save
  546.                        force_update=force_update, update_fields=update_fields)
File "/usr/lib/python2.7/dist-packages/django/db/models/base.py" in save_base
  664.                                    update_fields=update_fields, raw=raw, using=using)
File "/usr/lib/python2.7/dist-packages/django/dispatch/dispatcher.py" in send
  170.             response = receiver(signal=self, sender=sender, **named)
File "/home/jschneider/apps/calebasse/calebasse/common/models.py" in object_save
  22.         get_request().record(tag, log, obj=obj)
File "/home/jschneider/venvs/calebasse/local/lib/python2.7/site-packages/django_journal/middleware.py" in record
  18.             django_journal.record(tag, template, using=using,**kwargs)
File "/home/jschneider/venvs/calebasse/local/lib/python2.7/site-packages/django_journal/decorator.py" in wrapper
  43.                     return func(*args, **kwargs)
File "/home/jschneider/venvs/calebasse/local/lib/python2.7/site-packages/django_journal/__init__.py" in record
  33.     tag = Tag.objects.using(using).get_cached(name=tag)
File "/home/jschneider/venvs/calebasse/local/lib/python2.7/site-packages/django_journal/managers.py" in get_cached
  9.         instance, created = self.get_or_create(**kwargs)
File "/usr/lib/python2.7/dist-packages/django/db/models/query.py" in get_or_create
  484.             return self.get(**lookup), False
File "/usr/lib/python2.7/dist-packages/django/db/models/query.py" in get
  398.         num = len(clone)
File "/usr/lib/python2.7/dist-packages/django/db/models/query.py" in __len__
  106.                 self._result_cache = list(self.iterator())
File "/usr/lib/python2.7/dist-packages/django/db/models/query.py" in iterator
  317.         for row in compiler.results_iter():
File "/usr/lib/python2.7/dist-packages/django/db/models/sql/compiler.py" in results_iter
  775.         for rows in self.execute_sql(MULTI):
File "/usr/lib/python2.7/dist-packages/django/db/models/sql/compiler.py" in execute_sql
  846.         cursor.execute(sql, params)
File "/usr/lib/python2.7/dist-packages/django/db/backends/util.py" in execute
  41.             return self.cursor.execute(sql, params)
File "/usr/lib/python2.7/dist-packages/django/db/backends/postgresql_psycopg2/base.py" in execute
  58.             six.reraise(utils.DatabaseError, utils.DatabaseError(*tuple(e.args)), sys.exc_info()[2])
File "/usr/lib/python2.7/dist-packages/django/db/backends/postgresql_psycopg2/base.py" in execute
  54.             return self.cursor.execute(query, args)

Exception Type: DatabaseError at /cmpp/dossiers/17860/address/new
Exception Value: relation "django_journal_tag" does not exist
LINE 1: ...urnal_tag"."id", "django_journal_tag"."name" FROM "django_jo...
                                                             ^

History

#1

Updated by Serghei Mihai over 9 years ago

python manage.py syncdb && python manage.py migrate

#2

Updated by Jérôme Schneider over 9 years ago

  • Status changed from Nouveau to Rejeté

J'étais persuadé d'avoir fait un syncdb mais visiblement non. C'est étrange.

Also available in: Atom PDF