Replace calls to django.utils.hashcompat by hashlib