twython-django
twython-django copied to clipboard
#17: Python3 and Django 3.1 migration
Hi
Seems like there is on_delete field missing in twython_django_oauth/models.py:
File "/home/brezerk/develop/example/.venv/lib/python3.6/site-packages/twython_django_oauth/models.py", line 5, in <module>
class TwitterProfile(models.Model):
File "/home/brezerk/develop/example/.venv/lib/python3.6/site-packages/twython_django_oauth/models.py", line 11, in TwitterProfile
user = models.OneToOneField(User)
TypeError: __init__() missing 1 required positional argument: 'on_delete'
https://docs.djangoproject.com/en/3.1/ref/models/fields/#django.db.models.ForeignKey.on_delete
Addresses: https://github.com/ryanmcgrath/twython-django/issues/17
More fixes:
Django 3.1 migration
- Fixed: ImportError: Django ImportError: cannot import name 'render_to_response' from 'django.shortcuts'
- Fixed: ImportError: No module named 'django.core.urlresolvers'