I think the better pattern here is to just log the helpful message, then reraise the original exception, e.g.

    import logging
    logger = logging.getLogger(__name__)
    ...
    try:
        ...
    except:
        logger.error("'data must be QuerySet-like (have count and '
            'order_by) or support list(data) -- %s has '
            'neither' % type(data).__name__)
        raise