refactor: remove unused python2 code, optimize imports
This commit is contained in:
@@ -1,6 +1,3 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
|
||||
class FiasException(Exception):
|
||||
def __str__(self):
|
||||
return repr(self.args[0])
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
import re
|
||||
|
||||
import Levenshtein
|
||||
import re
|
||||
|
||||
|
||||
def violet_ratio(pattern, candidate):
|
||||
@@ -21,7 +19,7 @@ def violet_ratio(pattern, candidate):
|
||||
max_ratio = ratio
|
||||
max_j = j
|
||||
|
||||
result.append(max_j*abs(max_ratio))
|
||||
result.append(max_j * abs(max_ratio))
|
||||
|
||||
if max_j > -1:
|
||||
del allowed_nums[max_j]
|
||||
|
||||
@@ -1,8 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
import logging
|
||||
import os
|
||||
|
||||
from bottle import template
|
||||
|
||||
from aore.config import Folders, DatabaseConfig, SphinxConfig
|
||||
|
||||
@@ -1,8 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
|
||||
def trigram(inp):
|
||||
inp = u"__"+inp+u"__"
|
||||
inp = u"__" + inp + u"__"
|
||||
output = []
|
||||
|
||||
for i in range(0, len(inp) - 2):
|
||||
|
||||
Reference in New Issue
Block a user