Sunday, February 2, 2020

Re: Upgrading django from 1.8 to 2.2.0

i dont know why any time i run my django website with opra_mini browser it always bring source code

‪On Sun, Feb 2, 2020 at 7:49 AM ‫אורי‬‎ <uri@speedy.net> wrote:‬
By the way, each time upgrade to the latest release of each version. So it's 2.2.9 you should use. And all the latest versions on https://www.djangoproject.com/download/ (1.9.13 etc.)


On Fri, Jan 31, 2020 at 12:53 PM Santhosh sridhar <santhosh.sri27@gmail.com> wrote:
Hi, 
Im upgrading my django project from 1.8 to 2.2.0. I have done the below changes.

1. Added on_delete to all the Foreign Key fields
2. Changed the url reverse import as from django.urls import reverse
3. Included path/re_path instead of url in all the app's url files.
4. Changed the MIDDLEWARE_CLASSES import in settings files to MIDDLEWARE = {}

I tried to run the server, still it says "TypeError: __init__() missing 1 required positional argument: 'on_delete' and it is pointing to /usr2/santhosh/myproject/myapp/migrations/0002_abc.py

What should I do now? Do I need to delete all the migration files and re-run python manage.py migrate or what?? Help me you are aware.

Regards,
Santhosh

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/b907f25b-ffd3-462b-b3e9-5d87a20dd942%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CABD5YeF8LODtbNr1GHc6ZDObCcrep5HgrWmVZTpvrOdsFhvRTA%40mail.gmail.com.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CA%2B48qrGeD7uBHF45F44ZcqPADfEcVaRfXuKm9dyggbUo%2BjtsHw%40mail.gmail.com.

No comments:

Post a Comment