Details
Details
- Reviewers
durin42 - Group Reviewers
hg-reviewers - Commits
- rHGa4d41ba4ad23: verify: don't reimplement any()
Diff Detail
Diff Detail
- Repository
- rHG Mercurial
- Lint
Lint Skipped - Unit
Unit Tests Skipped
| durin42 |
| hg-reviewers |
| Lint Skipped |
| Unit Tests Skipped |
| Path | Packages | |||
|---|---|---|---|---|
| M | mercurial/verify.py (7 lines) |
| Status | Author | Revision | |
|---|---|---|---|
| Closed | martinvonz | ||
| Closed | martinvonz | ||
| Closed | martinvonz | ||
| Closed | martinvonz | ||
| Closed | martinvonz | ||
| Closed | martinvonz |
| except Exception as inst: | except Exception as inst: | ||||
| self.exc(lr, _("unpacking %s") % short(n), inst, f) | self.exc(lr, _("unpacking %s") % short(n), inst, f) | ||||
| # check renames | # check renames | ||||
| try: | try: | ||||
| if rp: | if rp: | ||||
| if lr is not None and ui.verbose: | if lr is not None and ui.verbose: | ||||
| ctx = lrugetctx(lr) | ctx = lrugetctx(lr) | ||||
| found = False | if not any(rp[0] in pctx for pctx in ctx.parents()): | ||||
| for pctx in ctx.parents(): | |||||
| if rp[0] in pctx: | |||||
| found = True | |||||
| break | |||||
| if not found: | |||||
| self.warn(_("warning: copy source of '%s' not" | self.warn(_("warning: copy source of '%s' not" | ||||
| " in parents of %s") % (f, ctx)) | " in parents of %s") % (f, ctx)) | ||||
| fl2 = repo.file(rp[0]) | fl2 = repo.file(rp[0]) | ||||
| if not len(fl2): | if not len(fl2): | ||||
| self.err(lr, _("empty or missing copy source " | self.err(lr, _("empty or missing copy source " | ||||
| "revlog %s:%s") % (rp[0], short(rp[1])), f) | "revlog %s:%s") % (rp[0], short(rp[1])), f) | ||||
| elif rp[1] == nullid: | elif rp[1] == nullid: | ||||
| ui.note(_("warning: %s@%s: copy source" | ui.note(_("warning: %s@%s: copy source" | ||||