# HG changeset patch # User David Schleimer # Date 1365789102 25200 # Node ID 117b3b42129401e89e1695603579a56d30a6ba33 # Parent 26aa0172725b3325a6ea6379174f2c72b5bc4335 buildmeta: verify uuid when passed explicit url 2c87bdc43d3c changed buildmeta to read the uuid from local disk, if it's available. As a side effect, it disabled the validation of the uuid we've recorded locall in the commits against the uuid of the repo we are building against. This is probably reasonable when someone runs a bare updatemeta or rebuildmeta. I think it's a worthwhile sanity check when someone passes an explicit repository url to rebuild/updatemeta. This restores the validation in that case, and fixes a failing test in the process. diff --git a/hgsubversion/svncommands.py b/hgsubversion/svncommands.py --- a/hgsubversion/svncommands.py +++ b/hgsubversion/svncommands.py @@ -61,8 +61,10 @@ def _buildmeta(ui, repo, args, partial=F " here (.hg not found)") dest = None + validateuuid = False if len(args) == 1: dest = args[0] + validateuuid = True elif len(args) > 1: raise hgutil.Abort('rebuildmeta takes 1 or no arguments') url = repo.ui.expandpath(dest or repo.ui.config('paths', 'default-push') or @@ -206,7 +208,8 @@ def _buildmeta(ui, repo, args, partial=F ' defect in replay') # write repository uuid if required - if uuid is None: + if uuid is None or validateuuid: + validateuuid = False uuid = convinfo[4:40] if not skipuuid: if svn is None: