I'm seeing the following error in a web2py 2.14.6 app @ pythonanywhere

OperationalError: (1553, "Cannot drop index 'f_User__idx': needed in a 
foreign key constraint")

This is an app that is using MySQL.  I have not changed any models, and all 
migrations are disabled, either of which not being true is what I might 
think could trigger this kind of error.  I do notice that everything in the 
compiled folder seems to have the same very recent timestamp, as if they 
were all touched recently.

I realize this is thin on details, but any ideas as to how I can a) track 
down the problem and more importantly b) solve it?

Here's the full traceback:

Traceback (most recent call last):
  File "/home/ukitms/web2py/gluon/restricted.py", line 227, in restricted
    exec ccode in environment
  File "/home/ukitms/web2py/applications/init/compiled/models.db.py", line 
164, in <module>
  File "/home/ukitms/web2py/gluon/packages/dal/pydal/base.py", line 834, in 
define_table
    table = self.lazy_define_table(tablename,*fields,**args)
  File "/home/ukitms/web2py/gluon/packages/dal/pydal/base.py", line 873, in 
lazy_define_table
    polymodel=polymodel)
  File "/home/ukitms/web2py/gluon/packages/dal/pydal/adapters/base.py", 
line 510, in create_table
    fake_migrate=fake_migrate
  File "/home/ukitms/web2py/gluon/packages/dal/pydal/adapters/base.py", 
line 623, in migrate_table
    self.execute(sub_query)
  File "/home/ukitms/web2py/gluon/packages/dal/pydal/adapters/base.py", 
line 1388, in execute
    return self.log_execute(*a, **b)
  File "/home/ukitms/web2py/gluon/packages/dal/pydal/adapters/base.py", 
line 1382, in log_execute
    ret = self.get_cursor().execute(command, *a[1:], **b)
  File "/usr/local/lib/python2.7/dist-packages/MySQLdb/cursors.py", line 
205, in execute
    self.errorhandler(self, exc, value)
  File "/usr/local/lib/python2.7/dist-packages/MySQLdb/connections.py", 
line 36, in defaulterrorhandler
    raise errorclass, errorvalue


- Scott




-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to