oplus/compatibility/util.py
def get_value_by_version(d):
    """
    Finds the value depending in current eplus version.


    Parameters
    ----------
    d: dict
        {(0, 0): value, (x, x): value, ...}
        for current version (cv), current value is the value of version v such as v <= cv < v+1
    """
    from oplus import CONF  # touchy import

    cv = CONF.eplus_version[:2]
    for v, value in sorted(d.items(), reverse=True):
        if cv >= v:
            return value
def get_value_by_version(d):
    from oplus import CONF  # touchy import

    cv = CONF.eplus_version[:2]
    for v, value in sorted(d.items(), reverse=True):
        if cv >= v:
            return value
def get_value_by_version ( d ) : from oplus import CONF # touchy import cv = CONF . eplus_version [ : 2 ] for v , value in sorted ( d . items ( ) , reverse = True ) : if cv >= v : return value
Finds the value depending in current eplus version.


    Parameters
    ----------
    d: dict
        {(0, 0): value, (x, x): value, ...}
        for current version (cv), current value is the value of version v such as v <= cv < v+1
Finds the value depending in current eplus version .