'Find the index of a particular asset in the list. This method is only functional for lists
sorted by filename. If the list is sorted on any other key, find() raises a
Returns: Index of asset, if found. None if not found.'

@contract(asset_id=AssetKey)
def find(self, asset_id):

    if (not self.filename_sort):
        raise IncorrectlySortedList()
    idx = None
    idx_left = self.bisect_left({'filename': asset_id.path})
    idx_right = self.bisect_right({'filename': asset_id.path})
    if (idx_left != idx_right):
        idx = idx_left
    return idx
