Setting up the database worked just fine. However, when I run the server and try to access the site, I get:

Quit the server with CONTROL-C.
Traceback (most recent call last):
  File "/usr/local/lib/python2.6/dist-packages/Django-1.1-py2.6.egg/django/core/servers/basehttp.py", line 279, in run
    self.result = application(self.environ, self.start_response)
  File "/usr/local/lib/python2.6/dist-packages/Django-1.1-py2.6.egg/django/core/servers/basehttp.py", line 651, in __call__
    return self.application(environ, start_response)
  File "/usr/local/lib/python2.6/dist-packages/Django-1.1-py2.6.egg/django/core/handlers/wsgi.py", line 230, in __call__
    self.load_middleware()
  File "/usr/local/lib/python2.6/dist-packages/Django-1.1-py2.6.egg/django/core/handlers/base.py", line 40, in load_middleware
    mod = import_module(mw_module)
  File "/usr/local/lib/python2.6/dist-packages/Django-1.1-py2.6.egg/django/utils/importlib.py", line 35, in import_module
    __import__(name)
  File "/home/jb/workspace/python/songinsight/forum/middleware/extended_user.py", line 4, in <module>
    from forum.views.auth import forward_suspended_user
  File "/home/jb/workspace/python/songinsight/forum/views/__init__.py", line 5, in <module>
    import meta
  File "/home/jb/workspace/python/songinsight/forum/views/meta.py", line 15, in <module>
    from forum.badges.base import BadgesMeta
  File "/home/jb/workspace/python/songinsight/forum/badges/__init__.py", line 5, in <module>
    from base import BadgesMeta
  File "/home/jb/workspace/python/songinsight/forum/badges/base.py", line 12, in <module>
    installed = dict([(b.cls, b) for b in Badge.objects.all()])
  File "/usr/local/lib/python2.6/dist-packages/Django-1.1-py2.6.egg/django/db/models/query.py", line 106, in _result_iter
    self._fill_cache()
  File "/usr/local/lib/python2.6/dist-packages/Django-1.1-py2.6.egg/django/db/models/query.py", line 692, in _fill_cache
    self._result_cache.append(self._iter.next())
  File "/usr/local/lib/python2.6/dist-packages/Django-1.1-py2.6.egg/django/db/models/query.py", line 238, in iterator
    for row in self.query.results_iter():
  File "/usr/local/lib/python2.6/dist-packages/Django-1.1-py2.6.egg/django/db/models/sql/query.py", line 287, in results_iter
    for rows in self.execute_sql(MULTI):
  File "/usr/local/lib/python2.6/dist-packages/Django-1.1-py2.6.egg/django/db/models/sql/query.py", line 2369, in execute_sql
    cursor.execute(sql, params)
InternalError: current transaction is aborted, commands ignored until end of transaction block

I found another question that had the same problem on syncdb and stated that removing the debug toolbar fixed it. However, I set DEBUG = False in the config, yet the error persists.

Can anyone help?

Thanks!

asked 06 Jul '10, 21:12

jbwiv's gravatar image

jbwiv
61229
accept rate: 25%

postgresql-8.4

python 2.6.5-0ubuntu1

python-psycopg2 2.0.13-2ubuntu2

(06 Jul '10, 21:18) jbwiv

Please take a look at the postgres logs, usually under /var/log/postgres/postgres.log or something very close to that :) Those will have the full error.

(06 Jul '10, 21:20) Hernani Cerq... ♦♦

Yes, you're right. I neglected stupidly to include --all when syncdb ran, so not all tables were loaded. Everything is fine now. Thanks!

(06 Jul '10, 21:26) jbwiv

Forgot to include --all when running syncdb, so not all tables were loaded. Recreating properly fixed it.

link

answered 06 Jul '10, 21:27

jbwiv's gravatar image

jbwiv
61229
accept rate: 25%

Is this something that perhaps we could default somewhere? It seems like a silly thing to not be defaulted to.

(06 Jul '10, 21:29) matt ♦♦
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×156
×62
×19

Asked: 06 Jul '10, 21:12

Seen: 609 times

Last updated: 06 Jul '10, 21:29

powered by OSQA