> Den 6. sep. 2016 kl. 10.20 skrev Lekan Wahab <
olam...@gmail.com>:
>
> Good morning guys.
> I was handed a project at work which was written as far back as 2012.
> Quiet a lot of the packages used in the project are either no longer being maintained.
> Rebuilding the project from scratch is not option.
> There are way too many moving parts and way too many apps to rebuild it.
> Here are my questions:
>
> 1. In the scenario i am in, what would be the best approach to update this project or at least get it set up locally?
First, get the project to run on your local machine with the exact same package versions as was specified originally. You may have to look in lib/pythonx.x/site-packages on wherever it was running before, for the exact versions used, if there is no requirements file. Run the test-suite for your project and make sure everything is working.
Second, write more tests! You need lots of tests to verify any future changes you make to your own and external packages.
Third, either upgrade external packages to the newest versions, find alternatives if they are no longer maintained, or maintain the external package yourself from now on (assuming the license permits, of course). If the packages depend Django, you may have to do this gradually, as the newest package versions may no longer support Django 1.4 (see below).
> 2. Quite a lot of changes have been made between django 1.4 (which was originally used) and the current version(1.10), what would be the best version for me to update the project to.
> I mostly use 1.8 anyway.
Take one minor Django version at a time, reading the upgrade notes along the way. Update your code to the new way of doing things, and move on to the next version. That's the supported and recommended way. Even though that's six versions to upgrade to, it will probably save you time in the long run instead of upgrading from 1.4 -> 1.10 in one go.
Happy coding!
Erik