Best open source CMS for developers to customize and add dynamic pages and content
If you are comfortable with hands-on programming, use Drupal.  It is one of the, if not the most powerful, configurable and tested CMS around.
There are lots of CMSs' available out there and most of them are good also but the three that always stand out are Drupal, Joomla and Wordpress.  Joomla and wordpress are easier to configure but not as customizable as Drupal is.
I want to build websites for multiple customers and want to take advantage of features that come with typical CMSs. But on top of that I need to do lots of customization like:

Writing my own templates on top of any existing templates to show the data in a form more suitable for these sites.
Extract some of the data from existing data sources which will be updated by different processes.
Implement my own login/auth mechanisms.
Do some of the SEO optimizations of the site myself and add some dynamic pages to the sites.

Which CMSs can handle these types of requirements or am I better off using something like Django. I am comfortable with both python and php but prefer python.