def compare_version(v1, v2):
    s1 = StrictVersion(v1)
    s2 = StrictVersion(v2)
    if s1 == s2:
        return 0
    elif s1 > s2:
        return -1
    else:
        return 1
Setups django-webtest authorization
dataset/ETHPy150Open docker/docker-py/docker/utils/utils.py/compare_version--crossover with--dataset/ETHPy150Open django-webtest/django-webtest/django_webtest/__init__.py/WebTestMixin._setup_auth