Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 21 Sep 2021 18:18:56 +0200] rev 47889
manifestlog: also monitor `00manifest.n` when applicable
This let the locarepo's file cache detect outdated nodemap docket and reload the
manifestlog after `localrepo.invalidate` when applicable.
The same problem than issue6554 could affect the Manifest too.
Differential Revision: https://phab.mercurial-scm.org/D11483
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 21 Sep 2021 18:03:37 +0200] rev 47888
changelog: also monitor `00changelog.n` when applicable (issue6554)
This let the locarepo's file cache detect outdated nodemap docket and reload the
changelog after `localrepo.invalidate` when applicable.
Differential Revision: https://phab.mercurial-scm.org/D11482
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 21 Sep 2021 21:18:50 +0200] rev 47887
persistent-nodemap: introduce a test to highlight possible race
Weakness in the current file caching of the changelog means that a writer can
end up using an outdated docket. This might result in "committed"
persistent-nodemap data from a previous writer to be overwritten by a later
writer. This break the strong "append only" assumption of the persistent nodemap
and can result in confused reader.
The race windows are quite narrow. See the test documentation for details.
The issues is fixed in the next changeset.
Differential Revision: https://phab.mercurial-scm.org/D11481
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 21 Sep 2021 21:18:44 +0200] rev 47886
test: enable share-safe in test-persistent-nodemap
We will use some share in this test and I would rather have them safe.
Differential Revision: https://phab.mercurial-scm.org/D11480
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 21 Sep 2021 18:02:07 +0200] rev 47885
filecache: abstract the fetching of the list of tracked file
We will need it for a coming fix that will requires to check a variable list of
file for the changelog.
Differential Revision: https://phab.mercurial-scm.org/D11479
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 20 Sep 2021 18:18:15 +0200] rev 47884
persistent-nodemap: use quiet upgrade in tests
This make them less verbose while keeping the important information in the
checked output.
Differential Revision: https://phab.mercurial-scm.org/D11478
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 20 Sep 2021 18:08:46 +0200] rev 47883
persistent-nodemap: fix a typo in a test comment
oops.
Differential Revision: https://phab.mercurial-scm.org/D11477
Raphaël Gomès <rgomes@octobus.net> [Mon, 20 Sep 2021 15:16:10 +0200] rev 47882
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
Raphaël Gomès <rgomes@octobus.net> [Thu, 09 Sep 2021 10:42:28 +0200] rev 47881
pep-517: remove the `build-backend` key to allow for users to build extensions
PEP 517 changed how projects should define their build dependencies.
The presence of a `pyproject.toml` file changes the behavior of `pip` to
conform to PEP 517.
Since we haven't updated the `setup.py` file yet (I'm not even sure we're not
an edge case which would make it harder/impossible, I have not tried yet), this
is a workaround to issue6589: it allows users to pass `--no-use-pep517` to pip
to revert to the legacy installer. The build backend is simply assumed to be
the `build_meta:__legacy__` one.
Differential Revision: https://phab.mercurial-scm.org/D11393
Pierre-Yves David <pierre-yves.david@octobus.net> [Fri, 17 Sep 2021 21:04:21 +0200] rev 47880
tests: make removeemptydirs more portable
The behavior of pwd change from one system (i.e. default shell/sh) from one
system to another so we use fuzzy matching for the output we do not care and we
use narrower command call to highlight what we are trying to test here.
Differential Revision: https://phab.mercurial-scm.org/D11449