Mercurial > public > mercurial-scm > hg
comparison mercurial/upgrade.py @ 48472:a4d8de93023c
pytype: stop excluding upgrade.py
The sole failure here was this, which is fixed by simply creating a set like the
caller, instead of a dict:
File "/mnt/c/Users/Matt/hg/mercurial/upgrade.py", line 73, in upgraderepo:
No attribute 'discard' on Dict[nothing, nothing] [attribute-error]
In Union[Any, Dict[nothing, nothing]]
Differential Revision: https://phab.mercurial-scm.org/D11911
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Sun, 12 Dec 2021 20:01:05 -0500 |
parents | 9dd151a39950 |
children | 17eaeb06562c |
comparison
equal
deleted
inserted
replaced
48471:b005d07ded7d | 48472:a4d8de93023c |
---|---|
40 changelog=None, | 40 changelog=None, |
41 filelogs=None, | 41 filelogs=None, |
42 ): | 42 ): |
43 """Upgrade a repository in place.""" | 43 """Upgrade a repository in place.""" |
44 if optimize is None: | 44 if optimize is None: |
45 optimize = {} | 45 optimize = set() |
46 repo = repo.unfiltered() | 46 repo = repo.unfiltered() |
47 | 47 |
48 specified_revlogs = {} | 48 specified_revlogs = {} |
49 if changelog is not None: | 49 if changelog is not None: |
50 specified_revlogs[upgrade_engine.UPGRADE_CHANGELOG] = changelog | 50 specified_revlogs[upgrade_engine.UPGRADE_CHANGELOG] = changelog |