Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/hgweb/hgwebdir_mod.py @ 13796:6337149fc07c
hgwebdir: handle IOErrors from localrepo while enumerating
Repository() raises a number of IOErrors in addition to RepoErrors.
these are just as uninteresting as RepoErrors and should be ignored
The easiest case of this is a repo whose .hg/ directory is -rx
author | timeless@gmail.com |
---|---|
date | Tue, 29 Mar 2011 16:33:10 +0000 |
parents | 8cbb59124e67 |
children | a35aff48d577 |
comparison
equal
deleted
inserted
replaced
13795:43b5fe18ea6c | 13796:6337149fc07c |
---|---|
249 url = re.sub(r'/+', '/', '/'.join(parts) + '/') | 249 url = re.sub(r'/+', '/', '/'.join(parts) + '/') |
250 | 250 |
251 # update time with local timezone | 251 # update time with local timezone |
252 try: | 252 try: |
253 r = hg.repository(self.ui, path) | 253 r = hg.repository(self.ui, path) |
254 except IOError: | |
255 u.warn(_('error accessing repository at %s\n') % path) | |
256 continue | |
254 except error.RepoError: | 257 except error.RepoError: |
255 u.warn(_('error accessing repository at %s\n') % path) | 258 u.warn(_('error accessing repository at %s\n') % path) |
256 continue | 259 continue |
257 try: | 260 try: |
258 d = (get_mtime(r.spath), util.makedate()[1]) | 261 d = (get_mtime(r.spath), util.makedate()[1]) |