Merge pull request #2392 from coreos-inc/search-optimization
Optimize repository search by changing our lookup strategy
This commit is contained in:
commit
432b2d3fe8
9 changed files with 123 additions and 123 deletions
6
util/itertoolrecipes.py
Normal file
6
util/itertoolrecipes.py
Normal file
|
@ -0,0 +1,6 @@
|
|||
from itertools import islice
|
||||
|
||||
# From: https://docs.python.org/2/library/itertools.html
|
||||
def take(n, iterable):
|
||||
""" Return first n items of the iterable as a list """
|
||||
return list(islice(iterable, n))
|
Reference in a new issue