comparison mercurial/branchmap.py @ 51483:0ddc34330d41

branchcache: do not accept "empty update" This currently does not happens and it will be simpler that is remains that way. If all update do something, we will be able to simply declare, in a later changesets, that all update to result in a dirty branchcache.
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Fri, 08 Mar 2024 15:06:54 +0100
parents 4188a0570ba1
children 1a9bdd0e1c44
comparison
equal deleted inserted replaced
51482:2b5f4013f79f 51483:0ddc34330d41
300 newbranches.setdefault(branch, []).append(r) 300 newbranches.setdefault(branch, []).append(r)
301 if closesbranch: 301 if closesbranch:
302 self._closednodes.add(cl.node(r)) 302 self._closednodes.add(cl.node(r))
303 max_rev = max(max_rev, r) 303 max_rev = max(max_rev, r)
304 if max_rev < 0: 304 if max_rev < 0:
305 max_rev = None 305 msg = "running branchcache.update without revision to update"
306 raise error.ProgrammingError(msg)
306 307
307 # Delay fetching the topological heads until they are needed. 308 # Delay fetching the topological heads until they are needed.
308 # A repository without non-continous branches can skip this part. 309 # A repository without non-continous branches can skip this part.
309 topoheads = None 310 topoheads = None
310 311