localpdb/plugins/Plugin.py
def find_closest_historical_version(version, versions):
        """
        Finds closest historical version in list of versions.
        @param version: specified version.
        @param versions: list of versions.
        @return: closest historical version.
        """
        diffs = {ver - version: ver for ver in versions if ver - version <= 0}
        return diffs[max(diffs, key=lambda key: diffs[key])] if len(diffs) > 0 else None

        Finds closest historical version in list of versions.
        @param version: specified version.
        @param versions: list of versions.
        @return: closest historical version.
        
Finds closest historical version in list of versions.
Finds closest historical version in list of versions .
def find_closest_historical_version(version, versions):
        diffs = {ver - version: ver for ver in versions if ver - version <= 0}
        return diffs[max(diffs, key=lambda key: diffs[key])] if len(diffs) > 0 else None
def find_closest_historical_version ( version , versions ) : diffs = { ver - version : ver for ver in versions if ver - version <= 0 } return diffs [ max ( diffs , key = lambda key : diffs [ key ] ) ] if len ( diffs ) > 0 else None
Finds closest historical version in list of versions.
Finds closest historical version in list of versions .
"""
        Finds closest historical version in list of versions.
        @param version: specified version.
        @param versions: list of versions.
        @return: closest historical version.
        """
closest historical version.
closest historical version .
version
None
versions
list of versions.
list of versions .