Modify

Ticket #1132 (closed defect: invalid)

Opened 22 months ago

Last modified 22 months ago

south crush with modify MyISAM table without InnoDB support

Reported by: vladka@… Owned by: andrew
Priority: critical Milestone:
Component: commands Version: 0.7.3
Keywords: innodb, table engine Cc:

Description

Debian GNU/Linux wheezy/sid \n \l
mysql - 5.1.49-3

south version - version = "0.7.3"

I did't not have InnoDB support in mysql, and for all tables i'm using MyISAM.
however, when i turn on south in my project, create first fake migration, and that want to apply second migration, south complains that i did not have InnoDB support.

Code highlighting:

./manage.py migrate website
Running migrations for website:
 - Migrating forwards to 0002_auto__add_field_site_domain__add_field_site_contact_email.
 > website:0002_auto__add_field_site_domain__add_field_site_contact_email
Traceback (most recent call last):
  File "./manage.py", line 14, in <module>
    execute_manager(settings)
  File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 438, in execute_manager
    utility.execute()
  File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 379, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 191, in run_from_argv
    self.execute(*args, **options.__dict__)
  File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 220, in execute
    output = self.handle(*args, **options)
  File "/usr/local/lib/python2.7/dist-packages/south/management/commands/migrate.py", line 105, in handle
    ignore_ghosts = ignore_ghosts,
  File "/usr/local/lib/python2.7/dist-packages/south/migration/__init__.py", line 191, in migrate_app
    success = migrator.migrate_many(target, workplan, database)
  File "/usr/local/lib/python2.7/dist-packages/south/migration/migrators.py", line 221, in migrate_many
    result = migrator.__class__.migrate_many(migrator, target, migrations, database)
  File "/usr/local/lib/python2.7/dist-packages/south/migration/migrators.py", line 292, in migrate_many
    result = self.migrate(migration, database)
  File "/usr/local/lib/python2.7/dist-packages/south/migration/migrators.py", line 125, in migrate
    result = self.run(migration)
  File "/usr/local/lib/python2.7/dist-packages/south/migration/migrators.py", line 99, in run
    return self.run_migration(migration)
  File "/usr/local/lib/python2.7/dist-packages/south/migration/migrators.py", line 86, in run_migration
    print self.run_migration_error(migration)
  File "/usr/local/lib/python2.7/dist-packages/south/migration/migrators.py", line 286, in run_migration_error
    (self.format_backwards(migration), extra_info))
  File "/usr/local/lib/python2.7/dist-packages/south/migration/migrators.py", line 273, in format_backwards
    self.backwards(migration)()
  File "/usr/local/lib/python2.7/dist-packages/south/migration/migrators.py", line 57, in <lambda>
    return (lambda: direction(orm))
  File "/home/vladka/PycharmProjects/builder/../builder/website/migrations/0002_auto__add_field_site_domain__add_field_site_contact_email.py", line 21, in backwards
    db.delete_column('website_site', 'domain')
  File "/usr/local/lib/python2.7/dist-packages/south/db/mysql.py", line 90, in delete_column
    result = cursor.execute(get_fkeyname_query % (db_name, table_name, name))
  File "/usr/local/lib/python2.7/dist-packages/django/db/backends/util.py", line 34, in execute
    return self.cursor.execute(sql, params)
  File "/usr/local/lib/python2.7/dist-packages/django/db/backends/mysql/base.py", line 86, in execute
    return self.cursor.execute(query, args)
  File "/usr/lib/python2.7/dist-packages/MySQLdb/cursors.py", line 176, in execute
    if not self._defer_warnings: self._warning_check()
  File "/usr/lib/python2.7/dist-packages/MySQLdb/cursors.py", line 92, in _warning_check
    warn(w[-1], self.Warning, 3)
_mysql_exceptions.Warning: Unknown table engine 'InnoDB'


Attachments

0002_auto__add_field_site_domain__add_field_site_contact_email.py (3.0 KB) - added by anonymous 22 months ago.
migration script

Change History

Changed 22 months ago by anonymous

migration script

comment:1 Changed 22 months ago by andrew

  • Status changed from new to closed
  • Resolution set to invalid

You're using a very old version of South, and the MySQL module has changed significantly since then. Please re-test with the latest South and re-open if it happens, with the new traceback.

View

Add a comment

Modify Ticket

Action
as closed
The resolution will be deleted. Next status will be 'reopened'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.