#18297: Reverse generic relation to a model inheriting from the model defining a
generic relation confuses flush
-------------------------------------+-------------------------------------
Reporter: pronik | Owner: nobody
Type: Bug | Status: new
Component: Core (Management | Version: 1.3
commands) | Resolution:
Severity: Normal | Triage Stage: Accepted
Keywords: | Needs documentation: 0
Has patch: 0 | Patch needs improvement: 0
Needs tests: 0 | UI/UX: 0
Easy pickings: 0 |
-------------------------------------+-------------------------------------
Changes (by aaugustin):
* component: Uncategorized => Core (Management commands)
* stage: Unreviewed => Accepted
Comment:
In addition to configuring a database, you'll have to add
`'django.contrib.comments'` to `INSTALLED_APPS` for the provided project
to work.
Here's the traceback:
{{{
(django-dev)myk@mYk djangobug % python manage.py syncdb
Creating tables ...
Creating table auth_permission
Creating table auth_group_permissions
Creating table auth_group
Creating table auth_user_user_permissions
Creating table auth_user_groups
Creating table auth_user
Creating table django_comments
Creating table django_comment_flags
Creating table django_content_type
Creating table django_session
Creating table django_site
Creating table my_comments_othercomment
Creating table my_comments_somethingcommented
You just installed Django's auth system, which means you don't have any
superusers defined.
Would you like to create one now? (yes/no): no
Installing custom SQL ...
Installing indexes ...
Installed 0 object(s) from 0 fixture(s)
}}}
{{{
(django-dev)myk@mYk djangobug % python manage.py flush --traceback
You have requested a flush of the database.
This will IRREVERSIBLY DESTROY all data currently in the 'throwaway'
database,
and return each table to the state it was in after syncdb.
Are you sure you want to do this?
Type 'yes' to continue, or 'no' to cancel: yes
Traceback (most recent call last):
File "/Users/myk/Documents/dev/django-
trunk/django/core/management/base.py", line 222, in run_from_argv
self.execute(*args, **options.__dict__)
File "/Users/myk/Documents/dev/django-
trunk/django/core/management/base.py", line 252, in execute
output = self.handle(*args, **options)
File "/Users/myk/Documents/dev/django-
trunk/django/core/management/base.py", line 382, in handle
return self.handle_noargs(**options)
File "/Users/myk/Documents/dev/django-
trunk/django/core/management/commands/flush.py", line 67, in handle_noargs
The full error: %s""" % (connection.settings_dict['NAME'], e))
CommandError: Database throwaway couldn't be flushed. Possible reasons:
* The database isn't running or isn't configured correctly.
* At least one of the expected database tables doesn't exist.
* The SQL was invalid.
Hint: Look at the output of 'django-admin.py sqlflush'. That's the SQL
this command wasn't able to run.
The full error: column "id" of relation "my_comments_othercomment" does
not exist
CommandError: Database throwaway couldn't be flushed. Possible reasons:
* The database isn't running or isn't configured correctly.
* At least one of the expected database tables doesn't exist.
* The SQL was invalid.
Hint: Look at the output of 'django-admin.py sqlflush'. That's the SQL
this command wasn't able to run.
The full error: column "id" of relation "my_comments_othercomment" does
not exist
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/18297#comment:2>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en.