##// END OF EJS Templates
convert: make sure mercurial_source has a local hg repo
Alexis S. L. Carvalho -
r5522:f5345a2d default
parent child Browse files
Show More
@@ -187,10 +187,11 b' class mercurial_source(converter_source)'
187 self.repo = hg.repository(self.ui, path)
187 self.repo = hg.repository(self.ui, path)
188 # try to provoke an exception if this isn't really a hg
188 # try to provoke an exception if this isn't really a hg
189 # repo, but some other bogus compatible-looking url
189 # repo, but some other bogus compatible-looking url
190 self.repo.heads()
190 if not self.repo.local():
191 raise hg.RepoError()
191 except hg.RepoError:
192 except hg.RepoError:
192 ui.print_exc()
193 ui.print_exc()
193 raise NoRepo("%s does not look like a Mercurial repo" % path)
194 raise NoRepo("%s is not a local Mercurial repo" % path)
194 self.lastrev = None
195 self.lastrev = None
195 self.lastctx = None
196 self.lastctx = None
196 self._changescache = None
197 self._changescache = None
General Comments 0
You need to be logged in to leave comments. Login now