Upgrading to 1.9 - Any Easy Guide ?

472 views
Skip to first unread message

Vibhu Rishi

unread,
Jan 11, 2016, 11:37:52 AM1/11/16
to django...@googlegroups.com
Hi

I work on a hobby project on and off which is based on django. After a long gap, I picked up the work again. In the meantime, it seems that django has been evolving faster than I have been working. I am currently on 1.6 (which I think i had upgraded from 1.4 or 1.3 as my starting base). However, the current new version of Django is 1.9

I created a new virtual environment and used pip to get the latest version of django.

Now I am getting a lot of errors.

Is there an easy way to upgrade django ? Or a howto for best practices ?

Thanks
V.

--
Simplicity is the ultimate sophistication. - Leonardo da Vinci
Life is really simple, but we insist on making it complicated. - Confucius

Tom Evans

unread,
Jan 11, 2016, 1:15:57 PM1/11/16
to django...@googlegroups.com
On Mon, Jan 11, 2016 at 4:36 PM, Vibhu Rishi <vibhu...@gmail.com> wrote:
> Hi
>
> I work on a hobby project on and off which is based on django. After a long
> gap, I picked up the work again. In the meantime, it seems that django has
> been evolving faster than I have been working. I am currently on 1.6 (which
> I think i had upgraded from 1.4 or 1.3 as my starting base). However, the
> current new version of Django is 1.9
>
> I created a new virtual environment and used pip to get the latest version
> of django.
>
> Now I am getting a lot of errors.

That is the hard way.

>
> Is there an easy way to upgrade django ? Or a howto for best practices ?
>

(Releases have version components: "1.9.1" is major release 1, minor
release 9, minor-minor release 1)

If you are on release 1.N, update to release 1.N+1.Y (with Y being the
highest released minor-minor version), and step through its release
notes dealing with all the things which have changed or been
deprecated, and update them accordingly. Run your test suite to
determine if anything has been broken (pro tip: tests are useful - you
might want to write some if you don't already test your most common
features)

Then, do the next minor release until you reach the latest release.

A more complete process would be to update to 1.N+1, ensure tests pass
and deprecated behaviour handled, THEN subsequently to 1.N+1.Y, ensure
tests pass and only then go to the next minor version. That can be a
bit paranoid, as (deliberately) not much functionality or breaking
changes are added in minor-minor releases of django.

Release notes are here:
https://docs.djangoproject.com/en/1.9/releases/

Cheers

Tom

PS: Best practices are not to fall that far behind!

Vibhu Rishi

unread,
Jan 12, 2016, 7:36:28 AM1/12/16
to django...@googlegroups.com

Hi Tom

So essentially you are saying to go with upgrade to 1.7 - fix issues and then to 1.8 etc ?

V.

--
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...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAFHbX1LiKM3pzb1bAFTk88iLmbJKWpEaa3NTMdsVw3WJ%2BRwbdw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

André Jarussi

unread,
Jan 12, 2016, 8:34:41 AM1/12/16
to Django users
Hello,

I recently had to upgrade from Django 1.4 to 1.8 (not quite ready for 1.9) ... I made the upgrade with the minor realeases .. I didn't had much trouble with the patches ..

basically .. 1.4 to 1.5 .. deploy .. see whats wrong .. 1.5 to 1.6 .. deploy .. see whats wrong ..  until you reach the version you wanna stay.

It's a lot less painfull .. and boring.

Read the release notes before starting any upgrade. It really helps you have an understading on what's changing and how that affects you.



Good luck!!

Vibhu Rishi

unread,
Jan 14, 2016, 10:43:19 PM1/14/16
to django...@googlegroups.com
Thanks Andre!


For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages