jaketothepast / Surveyor

Django Application for expiring survey links! Make data collection easy
0 stars 0 forks source link

Specify Django version <2.0 or update code for 2.0 changes #11

Closed danielhones closed 6 years ago

danielhones commented 6 years ago

Running docker-compose up gave the following error when it ran the migrations, which I believe is due to the change in Django 2.0 requiring on_delete for a ForeignKey field and the fact that requirements.txt doesn't specify a Django version.:

web_1    |   File "/code/surveyor/models.py", line 15, in <module>
web_1    |     class Answer(models.Model):
web_1    |   File "/code/surveyor/models.py", line 16, in Answer
web_1    |     question = models.ForeignKey("Question")
web_1    | TypeError: __init__() missing 1 required positional argument: 'on_delete'