Opened 19 years ago

Closed 19 years ago

Last modified 18 years ago

#1093 closed defect (fixed)

django-admin.py inspectdb syntax error, new from changeset 1688

Reported by: Steve Steiner Owned by: Adrian Holovaty
Component: Database layer (models, ORM) Version: dev
Severity: critical Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

# This is an auto-generated Django model module.
# You'll have to do the following manually to clean this up:
# * Rearrange models' order
# * Add primary_key=True to one field in each model.
# Feel free to rename the models, but don't rename db_table values or field names.
#
# Also note: You'll have to insert the output of 'django-admin.py sqlinitialdata [appname]'
# into your database.

from django.core import meta

class AuthGroup(meta.Model):
Traceback (most recent call last):

File "/usr/local/bin/django-admin", line 5, in ?

pkg_resources.run_script('Django==0.90', 'django-admin.py')

File "/usr/local/lib/python2.4/site-packages/setuptools-0.6a8-py2.4.egg/pkg_resources.py", line 407, in run_script

self.require(requires)[0].run_script(script_name, ns)

File "/usr/local/lib/python2.4/site-packages/setuptools-0.6a8-py2.4.egg/pkg_resources.py", line 920, in run_script

execfile(script_filename, namespace, namespace)

File "/usr/local/lib/python2.4/site-packages/Django-0.90-py2.4.egg/EGG-INFO/scripts/django-admin.py", line 5, in ?

management.execute_from_command_line()

File "/usr/local/lib/python2.4/site-packages/Django-0.90-py2.4.egg/django/core/management.py", line 917, in execute_from_command_line

for line in action_mapping[action](param):

File "/usr/local/lib/python2.4/site-packages/Django-0.90-py2.4.egg/django/core/management.py", line 583, in inspectdb

for i, row in enumerate(db.get_table_description(cursor, table_name)):

File "/usr/local/lib/python2.4/site-packages/Django-0.90-py2.4.egg/django/core/db/backends/mysql.py", line 129, in get_table_description

cursor.execute("SELECT * FROM %s LIMIT 1" % DatabaseWrapper.quote_name(table_name))

TypeError: unbound method quote_name() must be called with DatabaseWrapper instance as first argument (got str instance instead)

Change History (1)

comment:1 by Adrian Holovaty, 19 years ago

Resolution: fixed
Status: newclosed

(In [1744]) Fixed #1093 -- Fixed error in inspectdb from [1688]

Note: See TracTickets for help on using tickets.
Back to Top