diff -r 675a925b556d -r 373749982924 mercurial/upgrade.py --- a/mercurial/upgrade.py Fri Sep 27 21:32:56 2019 +0200 +++ b/mercurial/upgrade.py Fri Sep 27 19:59:53 2019 +0200 @@ -561,12 +561,15 @@ pass # create all the directories util.copyfile(oldindex, newindex) - if oldrl.opener.exists(oldrl.datafile): + copydata = oldrl.opener.exists(oldrl.datafile) + if copydata: util.copyfile(olddata, newdata) if not (unencodedname.endswith('00changelog.i') or unencodedname.endswith('00manifest.i')): destrepo.svfs.fncache.add(unencodedname) + if copydata: + destrepo.svfs.fncache.add(unencodedname[:-2] + '.d') UPGRADE_CHANGELOG = object() UPGRADE_MANIFEST = object()