worldcompany / djangoembed

rich media consuming and providing with django
http://djangoembed.readthedocs.org
MIT License
138 stars 38 forks source link

Getting IntegrityError when trying to hit an endpoint for the first time #17

Closed dryan closed 12 years ago

dryan commented 13 years ago

http://dpaste.com/537543/ is the traceback

coleifer commented 13 years ago

I'm not sure what that could be...are you able to run tests?

dryan commented 13 years ago

Tests are failing. It looks like I might have data corruption on my drive. I'll post back after I run some tests on that.

dryan commented 13 years ago

Gotten the drive back to normal.

Testing fails (and not just in oembed): https://gist.github.com/949947 This is on OS X 10.6 running MySQL 5.5 and on Ubuntu running MySQL 5.1.

The error occurs when a StoredOEmbed is created without a content_type set, even though that is set to allow null values. It appears to be caused by the Foreign Key constraint placed on the content_type field. (If I manually remove the constraint then everything works as expected.)

coleifer commented 12 years ago

Are you missing the django.contrib.sites app?