Permalink
Browse files

don't explode if a file has been removed from the repo but remains re…

…ferenced in the search backend -- fixes http://trac-hacks.org/ticket/9791
  • Loading branch information...
ejucovy committed Jan 11, 2013
1 parent e899915 commit 148a9ccb95d1d09ab83990fd5443ad09c5ff0285
Showing with 5 additions and 1 deletion.
  1. +5 −1 multireposearch/search.py
@@ -93,7 +93,11 @@ def get_search_results(self, req, query, filters):
if repo is None:
# @@TODO: log it? ask the search backend to remove the reference?
continue
- node = repo.get_node(filename)
+ try:
+ node = repo.get_node(filename)
+ except NoSuchNode, e:
+ # @@TODO: log it!
+ continue
if node.kind == Node.DIRECTORY:
yield (self.env.href.browser(reponame, filename),

0 comments on commit 148a9cc

Please sign in to comment.