Mon, 20 Sep 2021 19:59:09 +0200 debugstate: Always call dirstatemap.debug_iter()
Simon Sapin <simon.sapin@octobus.net> [Mon, 20 Sep 2021 19:59:09 +0200] rev 48023
debugstate: Always call dirstatemap.debug_iter() … passing it a new `all` argument for the `--all` CLI option, instead of conditionally calling `.debug_iter()` or `.items()` This prepares for the next commit. Differential Revision: https://phab.mercurial-scm.org/D11462
Fri, 17 Sep 2021 13:33:45 +0200 rust: Make the fields of DirstateEntry private
Simon Sapin <simon.sapin@octobus.net> [Fri, 17 Sep 2021 13:33:45 +0200] rev 48022
rust: Make the fields of DirstateEntry private This is a first step toward making its internal structure equivalent to Python’s DirstateItem. Differential Revision: https://phab.mercurial-scm.org/D11461
Mon, 20 Sep 2021 13:16:36 +0200 rust: Remove support for passing a dict to the Rust pathutil.dirs()
Simon Sapin <simon.sapin@octobus.net> [Mon, 20 Sep 2021 13:16:36 +0200] rev 48021
rust: Remove support for passing a dict to the Rust pathutil.dirs() That is only used by the Python dirstatemap, which not used when Rust is enabled. This allows removing the private `extract_dirstate` function which creates `DirstateEntry` values. This in turn will make easier upcoming changes to `DirstateEntry`. Differential Revision: https://phab.mercurial-scm.org/D11460
Mon, 20 Sep 2021 12:52:32 +0200 rust: Remove the `rustext.parsers` module
Simon Sapin <simon.sapin@octobus.net> [Mon, 20 Sep 2021 12:52:32 +0200] rev 48020
rust: Remove the `rustext.parsers` module It only exported Rust implementations of the parse_dirstate and pack_dirtate functions, which are only used (anymore) when Rust is not enabled. fakedirstatewritetime.py was detecting the presence of `rustext.parsers` but what it really wants to know is whether the Rust implementation of `dirstatemap` is used. This changes it to detect `rustext.dirstate` instead. Differential Revision: https://phab.mercurial-scm.org/D11459
Fri, 17 Sep 2021 14:36:54 +0200 dirstate: remove now-unused .directories() method
Simon Sapin <simon.sapin@octobus.net> [Fri, 17 Sep 2021 14:36:54 +0200] rev 48019
dirstate: remove now-unused .directories() method It calls _rustmap.directories() which was already removed Differential Revision: https://phab.mercurial-scm.org/D11458
Fri, 17 Sep 2021 12:42:24 +0200 rust: Move DirstateEntry to its own module
Simon Sapin <simon.sapin@octobus.net> [Fri, 17 Sep 2021 12:42:24 +0200] rev 48018
rust: Move DirstateEntry to its own module … and RawEntry to the dirstate::parsers module, the only one that uses it. Differential Revision: https://phab.mercurial-scm.org/D11457
Mon, 20 Sep 2021 15:16:10 +0200 patchbomb: fix traceback on outgoing when not specifying revisions stable
Raphaël Gomès <rgomes@octobus.net> [Mon, 20 Sep 2021 15:16:10 +0200] rev 48017
patchbomb: fix traceback on outgoing when not specifying revisions A user reported that `hg email -n -o` raised with the following traceback: ``` ** unknown exception encountered, please report by visiting ** https://mercurial-scm.org/wiki/BugTracker ** Python 3.8.12 (default, Sep 13 2021, 22:12:54) [GCC 7.5.0] ** Mercurial Distributed SCM (version 5.9.1) ** Extensions loaded: patchbomb Traceback (most recent call last): File "/usr/pkg/bin/hg", line 61, in <module> dispatch.run() File "/usr/pkg/lib/python3.8/site-packages/mercurial/dispatch.py", line 144, in run status = dispatch(req) File "/usr/pkg/lib/python3.8/site-packages/mercurial/dispatch.py", line 250, in dispatch status = _rundispatch(req) File "/usr/pkg/lib/python3.8/site-packages/mercurial/dispatch.py", line 294, in _rundispatch ret = _runcatch(req) or 0 File "/usr/pkg/lib/python3.8/site-packages/mercurial/dispatch.py", line 470, in _runcatch return _callcatch(ui, _runcatchfunc) File "/usr/pkg/lib/python3.8/site-packages/mercurial/dispatch.py", line 480, in _callcatch return scmutil.callcatch(ui, func) File "/usr/pkg/lib/python3.8/site-packages/mercurial/scmutil.py", line 153, in callcatch return func() File "/usr/pkg/lib/python3.8/site-packages/mercurial/dispatch.py", line 460, in _runcatchfunc return _dispatch(req) File "/usr/pkg/lib/python3.8/site-packages/mercurial/dispatch.py", line 1273, in _dispatch return runcommand( File "/usr/pkg/lib/python3.8/site-packages/mercurial/dispatch.py", line 918, in runcommand ret = _runcommand(ui, options, cmd, d) File "/usr/pkg/lib/python3.8/site-packages/mercurial/dispatch.py", line 1285, in _runcommand return cmdfunc() File "/usr/pkg/lib/python3.8/site-packages/mercurial/dispatch.py", line 1271, in <lambda> d = lambda: util.checksignature(func)(ui, *args, **strcmdopt) File "/usr/pkg/lib/python3.8/site-packages/mercurial/util.py", line 1886, in check return func(*args, **kwargs) File "/usr/pkg/lib/python3.8/site-packages/hgext/patchbomb.py", line 817, in email revs = _getoutgoing(repo, dest, revs) File "/usr/pkg/lib/python3.8/site-packages/hgext/patchbomb.py", line 537, in _getoutgoing safe_paths = [urlutil.hidepassword(p.rawloc) for p in paths] File "/usr/pkg/lib/python3.8/site-packages/hgext/patchbomb.py", line 537, in <listcomp> safe_paths = [urlutil.hidepassword(p.rawloc) for p in paths] File "/usr/pkg/lib/python3.8/site-packages/mercurial/utils/urlutil.py", line 501, in get_push_paths msg %= dest TypeError: %b requires a bytes-like object, or an object that implements __bytes__, not 'NoneType' ``` This is due to patchbomb passing `[None]` in the `dests` parameter of the multi-paths outgoing function, we fix this in this change and add a non-regression test. Differential Revision: https://phab.mercurial-scm.org/D11456
Mon, 20 Sep 2021 14:21:18 -0400 extensions: prevent a crash on py3 with a `minimumhgversion` str value
Matt Harbison <matt_harbison@yahoo.com> [Mon, 20 Sep 2021 14:21:18 -0400] rev 48016
extensions: prevent a crash on py3 with a `minimumhgversion` str value The expectation is that this field is bytes, but unported extensions are a thing and it shouldn't explode on a bad value. We already do this transformation in the version reporting mechanism. Differential Revision: https://phab.mercurial-scm.org/D11476
Mon, 20 Sep 2021 14:16:10 -0400 extensions: prevent a crash on py3 when testing a bad extension minimum
Matt Harbison <matt_harbison@yahoo.com> [Mon, 20 Sep 2021 14:16:10 -0400] rev 48015
extensions: prevent a crash on py3 when testing a bad extension minimum A `None` placeholder is populated for each missing component by `util.versiontuple()`, which could safely be used with `>` on py2, but not py3. I guess there's another hole here where if the string is entirely bogus (i.e no numbers), it will be treated as 0.0, and always load. But that's always been the case. Differential Revision: https://phab.mercurial-scm.org/D11475
Mon, 20 Sep 2021 11:22:27 -0400 typing: drop annotations on `mercurial/logcmdutil.walkopts` attributes
Matt Harbison <matt_harbison@yahoo.com> [Mon, 20 Sep 2021 11:22:27 -0400] rev 48014
typing: drop annotations on `mercurial/logcmdutil.walkopts` attributes Pytype 2021-09-09 must have learned some things about `@attr`, because while these were presumably required to help it before (c1d0f83d62c4::9a26fea2b518 and c11099cc1de4::224c786f4fce), these instances now get flagged as an assignment mismatch: File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 717, in walkopts: Type annotation for pats does not match type of assignment [annotation-type-mismatch] Annotation: List[bytes] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 718, in walkopts: Type annotation for opts does not match type of assignment [annotation-type-mismatch] Annotation: Dict[bytes, Any] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 722, in walkopts: Type annotation for revspec does not match type of assignment [annotation-type-mismatch] Annotation: List[bytes] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 725, in walkopts: Type annotation for bookmarks does not match type of assignment [annotation-type-mismatch] Annotation: List[bytes] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 726, in walkopts: Type annotation for branches does not match type of assignment [annotation-type-mismatch] Annotation: List[bytes] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 727, in walkopts: Type annotation for date does not match type of assignment [annotation-type-mismatch] Annotation: Optional[bytes] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 728, in walkopts: Type annotation for keywords does not match type of assignment [annotation-type-mismatch] Annotation: List[bytes] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 729, in walkopts: Type annotation for no_merges does not match type of assignment [annotation-type-mismatch] Annotation: bool Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 730, in walkopts: Type annotation for only_merges does not match type of assignment [annotation-type-mismatch] Annotation: bool Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 731, in walkopts: Type annotation for prune_ancestors does not match type of assignment [annotation-type-mismatch] Annotation: List[bytes] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 732, in walkopts: Type annotation for users does not match type of assignment [annotation-type-mismatch] Annotation: List[bytes] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 735, in walkopts: Type annotation for include_pats does not match type of assignment [annotation-type-mismatch] Annotation: List[bytes] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 736, in walkopts: Type annotation for exclude_pats does not match type of assignment [annotation-type-mismatch] Annotation: List[bytes] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 739, in walkopts: Type annotation for follow does not match type of assignment [annotation-type-mismatch] Annotation: int Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 743, in walkopts: Type annotation for force_changelog_traversal does not match type of assignment [annotation-type-mismatch] Annotation: bool Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 747, in walkopts: Type annotation for filter_revisions_by_pats does not match type of assignment [annotation-type-mismatch] Annotation: bool Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 750, in walkopts: Type annotation for sort_revisions does not match type of assignment [annotation-type-mismatch] Annotation: Optional[bytes] Assignment: mercurial.thirdparty.attr._make._CountingAttr File "/mnt/c/Users/Matt/hg/mercurial/logcmdutil.py", line 753, in walkopts: Type annotation for limit does not match type of assignment [annotation-type-mismatch] Annotation: Optional[int] Assignment: mercurial.thirdparty.attr._make._CountingAttr Differential Revision: https://phab.mercurial-scm.org/D11474
(0) -30000 -10000 -3000 -1000 -300 -100 -10 +10 +100 +300 +1000 +3000 tip