

@internationalizeDocstring
def levenshtein(self, irc, msg, args, s1, s2):
    '<string1> <string2>\n\n        Returns the levenshtein distance (also known as the "edit distance"\n        between <string1> and <string2>)\n        '
    max = self.registryValue('levenshtein.max')
    if ((len(s1) > max) or (len(s2) > max)):
        irc.error(_('Levenshtein distance is a complicated algorithm, try it with some smaller inputs.'))
    else:
        irc.reply(str(utils.str.distance(s1, s2)))

dataset/ETHPy150Open ProgVal/Limnoria/plugins/String/plugin.py String.levenshtein/original