liuyang1520 / django-command-extensions

Automatically exported from code.google.com/p/django-command-extensions
MIT License
0 stars 0 forks source link

sqldiff broken with 1.0-alpha2 #41

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. run manage.py sqldiff on latest trunk

Expected: 
printed sqldiffs

Output:

  File
"D:\Python25\Scripts\g\..\g\apps\django_extensions\management\commands\sqldiff.p
y",
line 53, in handle_diff

    from django.db import models, connection, get_introspection_module
ImportError: cannot import name get_introspection_module

After deleting import get_introspection_module and changing
get_introspection_module to connection.introspection see
http://code.djangoproject.com/changeset/8296 or
http://code.djangoproject.com/wiki/BackwardsIncompatibleChanges

I've got next problem:

  File
"D:\Python25\Scripts\g\..\g\apps\django_extensions\management\commands\sqldiff.p
y",
line 62, in handle_diff

    django_tables =
_sql.django_table_list(only_existing=options.get('only_existing', True))
AttributeError: 'module' object has no attribute 'django_table_list'

What version of the product are you using? On what operating system?
Python 2.5 on Windows XP SP3, Django latest trunk 1.0-alpha_2-SVN-unknown

Original issue reported on code.google.com by nick...@gmail.com on 14 Aug 2008 at 8:36

GoogleCodeExporter commented 8 years ago

Original comment by v.oostv...@gmail.com on 15 Aug 2008 at 7:26

GoogleCodeExporter commented 8 years ago
thanks for the report.

Haven't updated to latest trunk myself, but sqldiff does certainly use a lot of 
the
darker Django internals.

Patching this up to be compatible with both Django-trunk as well as older Django
versions will probably also be hairy (to say the least)

I'll try to get a fix for this as soon as possible.

Original comment by v.oostv...@gmail.com on 15 Aug 2008 at 7:28

GoogleCodeExporter commented 8 years ago
fix is in svn.
should be backwardscompatible for now :)

i'm planning to remove all backwards compatibility hacks when 1.0 lands 

Original comment by v.oostv...@gmail.com on 15 Aug 2008 at 4:17