Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 15 May 2023 08:56:40 +0200] rev 50506
store: introduce a EntryFile object to actually access file info
For now a StoreEntry match a single file, but the goal is to eventually combine
multiple file in a higher level Entry, so we need to introduce this distinction
and use it first.
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 15 May 2023 08:56:23 +0200] rev 50505
store: use a StoreEntry object instead of tuple for store files
We want to make the store return more semantic information instead of a stream
of file path. To achieve this, we start with adding a simple object that hold
the same information as the tuple it replace, and do a simple update to the
user code to fetch and use the same information.
From there, we will be able to iteratively upgrade the codebase toward better
objects.
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 15 May 2023 08:56:08 +0200] rev 50504
store: no longer explicitly mark the splitted index as ignored
Since the fncache is going to automatically recognised it as non "normal"
revlog file, we don't need to explicitly make it ignored.
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 15 May 2023 08:55:52 +0200] rev 50503
store: cleanup what is recognized as a revlog file
The temporary file from `censor` are not relevant to the store as they are just
temporary. So let `fncache` and `datafiles` forget about them.
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 15 May 2023 08:55:34 +0200] rev 50502
store: only inclure revlog related file in `datafiles`
This is a "reading" equivalent of the previous patches (see that patch for
details).
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 15 May 2023 08:55:19 +0200] rev 50501
store: do not record file that are not part of a revlog in fncache
The fncache exist to list file to copy/stream when cloning a repository, it
should only contains file that are relevant for a revlog in such case. For
example, temporary file are not relevant.
So we now skip the addiction of non-relevant file to the fn-cache in the first place.
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 15 May 2023 08:55:02 +0200] rev 50500
revlog-split: expand the some test to cover the success case too
It seems useful to double check the case of a transaction successfully
committed before trying the one with transaction abort.
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 15 May 2023 08:54:47 +0200] rev 50499
transaction: use a ".bck" extension for all backup file
There are too much code in Mercurial that assume file function from extension.
Keeping the original extension when doing backup is just creating confusion
(for exemple, backup of revlog's confused with new version revlogs).
So we change the backup name from now on to be explicilty backup file and
prevent this kind of problem.
(note that repository using fncache is less affected (but still affected) by
this kind of problem as the backup are not listed in the fncache).
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 15 May 2023 08:54:33 +0200] rev 50498
repair-issue6528: remove a now useless continue
The condition for that continue have been excplicly filtered out of the `files`
list a handful of line earlier.
Raphaël Gomès <rgomes@octobus.net> [Tue, 09 May 2023 11:35:50 +0200] rev 50497
branching: merge stable into default
pacien <pacien.trangirard@pacien.net> [Fri, 28 Apr 2023 12:12:42 +0200] rev 50496
stabletailgraph: clarify omission of linear parts in test sorts
Those are not interesting and are collapsed using globs.
Only the tagged nodes are interesting.
pacien <pacien.trangirard@pacien.net> [Fri, 28 Apr 2023 11:50:49 +0200] rev 50495
stabletailgraph: omit uninteresting linear parts in test log
The test uses tags for the nodes of interest.
There is no need to print the linear parts which exist only to force the rank.
pacien <pacien.trangirard@pacien.net> [Sun, 16 Apr 2023 22:49:42 +0200] rev 50494
stabletailgraph: fix typo in test
pacien <pacien.trangirard@pacien.net> [Sun, 16 Apr 2023 22:17:30 +0200] rev 50493
stabletailgraph: fix terminology in doc
Pierre-Yves David <pierre-yves.david@octobus.net> [Fri, 28 Apr 2023 16:28:43 +0200] rev 50492
perf: introduce a `perf::stream-locked-section` command
This command benchmark the initial part of a stream clone, where the repository
is locked.
Anton Shestakov <av6@dwimlabs.net> [Wed, 03 May 2023 18:17:32 -0300] rev 50491
transaction: tr._names are actually bytes, use byte string to join them
Looks like this is never checked in the tests? But trying e.g. `print(tr)` by
hand before this change would give:
TypeError: sequence item 0: expected str instance, bytes found
Looks like tr._names are always bytes (although this isn't actually enforced,
but maybe at some point it will at least be type checked e.g. by pytype).
pacien <pacien.trangirard@pacien.net> [Mon, 17 Apr 2023 00:27:46 +0200] rev 50490
nix: add nix-defined package and devel env (flake)
This adds a Nix Flake which defines:
- package recipies to build and run Mercurial (C, C+Rust variants),
- a meta package to run the test suite in an isolated sandbox,
- a development environment with some tools
(notably Python and the Black formatter, pinned to match the CI).
Python is pinned to the recommended version.
The Rust toolchain is a fairly recent one provided by the Nixpkgs channel.
It is not yet pinned to the same version as the "reference" Debian package,
but this does not seem to cause any issue.
Example usage of local commands are provided in the `flake.nix` file.
Once merged, it should also be possible to pull and run directly from the
source repository directly with something like:
`nix run hg+https://foss.heptapod.net/mercurial/mercurial-devel?ref=TOPIC&dir=contrib/nix' -- version`
pacien <pacien.trangirard@pacien.net> [Thu, 20 Apr 2023 16:55:19 +0200] rev 50489
hgignore: ignore nix result symlink
pacien <pacien.trangirard@pacien.net> [Sun, 16 Apr 2023 23:48:24 +0200] rev 50488
tests: add test ignore list for nix
Some tests cannot run properly in the nix sandbox.
This adds a list of tests to ignore when running in that context.
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 21 Mar 2023 14:29:35 +0000] rev 50487
ui: keep the progress bar around when writing if stdout is not a tty
Arseniy Alekseyev <aalekseyev@janestreet.com> [Fri, 10 Mar 2023 11:20:18 +0000] rev 50486
tests: in filterpyflakes, tolerate non-ascii file contents
Arseniy Alekseyev <aalekseyev@janestreet.com> [Mon, 30 Jan 2023 13:37:48 +0000] rev 50485
comments: fix spelling
Axel Prel <axel.prel@xcg-consulting.fr> [Fri, 07 Apr 2023 14:23:12 +0200] rev 50484
heptapod-ci: display python version
it will be useful to debug in the CI
Raphaël Gomès <rgomes@octobus.net> [Tue, 18 Apr 2023 11:55:23 +0200] rev 50483
branching: merge stable into default
Sevan Janiyan <venture37@geeklan.co.uk> [Fri, 14 Apr 2023 19:59:44 +0100] rev 50482
sha1dc: Make sure SHA1DC_BIGENDIAN is set on Darwin/PowerPC
__BYTE_ORDER__ is not defined on old toolchains so sha1dc gets
built in little endian mode on a big endian platform, hilarity
ensues. Tested on Mac OS X Tiger 10.4.
Manuel Jacob <me@manueljacob.de> [Sat, 13 Apr 2019 03:44:55 +0200] rev 50481
hidden: add support to explicitly access hidden changesets with SSH peers
This implements support for using --remote-hidden with an SSH server. The
remote `hg serve --stdio` call is passed the `--hidden` flag as a request to
access hidden changesets.
This approach has benefits similar to the one we used for HTTP peers. It
* works around the lack of global parameters in wire protocol v1,
* reuses the `--hidden` flag (that does not use the wireproto), and
* can be safely ignored by older client (fitting the best effort contract).
Same as for HTTP, the feature is experimental so we have all the room we needs
to update the implementation in the future if deemed necessary.
The SSH version of the `--remote-hidden` config uses the same configuration as
the HTTP support to control the access to this feature. The name of the user
running the command is used for the checking.
Test written by Pierre-Yves David.
Manuel Jacob <me@manueljacob.de> [Sat, 13 Apr 2019 03:44:47 +0200] rev 50480
hidden: support passing --hidden with `serve --stdio`
This currently has no effect since the server code will filter the repository
again. However, it is clearer to put this change in its own changeset.
This will mostly impact ssh peers, clients being now able to pass --hidden when
spawning the server.
See the next changeset for details on how this is going to be used.
Pierre-Yves David <pierre-yves.david@octobus.net> [Sat, 13 Apr 2019 01:53:59 +0200] rev 50479
hgweb: move ismember from `hgweb.common` to `scmutil`
To implement hidden access control for other protocol than http, we need code
outside of hgweb to access this logic.
Manuel Jacob <me@manueljacob.de> [Fri, 05 Apr 2019 01:17:15 +0200] rev 50478
hidden: add support for --remote-hidden to HTTP peer
Test written by Pierre-Yves David.
Manuel Jacob <me@manueljacob.de> [Sat, 13 Apr 2019 02:01:26 +0200] rev 50477
hidden: add support to explicitly access hidden changesets via HTTP
We now detect hidden access request and validate them while handling HTTP
wireprotocol command. This changeset only introduces server support. Client
support is added in a subsequent changeset.
The mechanism we use for the HTTP wireprotocol is the same as the one used to
lift filtering for hgweb. The use of the global `access-hidden` parameter in
the http url is a simple and effective approach that
* works around the lack of global parameters in wire protocol v1,
* reuses the mechanism used for hgweb (that does not use the wireproto), and
* can be safely ignored by older client (fitting the best effort contract).
The feature is still experimental, so we can easily update the implementation
details in the future. However, landing a first implementation now will help
test the feature in the wild and iterate on alternative implementations if
deemed necessary.
Manuel Jacob <me@manueljacob.de> [Sat, 13 Apr 2019 02:00:20 +0200] rev 50476
hidden: support for explicitly accessing hidden changesets in wireproto server
This installs the basic infrastructure to be able to access hidden changeset
through the wireprotocol. Each wireprotocol server still needs a way to define
how the feature is triggered.
Manuel Jacob <me@manueljacob.de> [Fri, 05 Apr 2019 12:11:52 +0200] rev 50475
hidden: add support for --remote-hidden to localpeer
Manuel Jacob <me@manueljacob.de> [Thu, 04 Apr 2019 18:07:30 +0200] rev 50474
pull: add --remote-hidden option and pass it through peer creation
This option will allow to pull changesets that are hidden on the remote. This
is useful when looking into a changeset’s evolution history, resolving
evolution instability or mirroring a repository.
The option is best effort and will only affect the pull when it can. The option
will be ignored when it cannot be honored.
Support for each type of peer is yet to be implemented. They currently all warn
about lack of support. The warning code will get removed as peers gain
support for this option.
The option is still experimental, so we will have freedom to update the UI or
implementation before it graduates out of experimental.
Based on a changeset by Pierre-Yves David, which added the option.
Pierre-Yves David <pierre-yves.david@octobus.net> [Sat, 13 Apr 2019 01:17:56 +0200] rev 50473
hgweb: add support to explicitly access hidden changesets
This changeset adds a "global" `access-hidden` argument to hgweb. This argument
lift the "hidden" filtering. This means the request has access to hidden (eg:
obsolete) changesets. Secret changesets remains filtered.
This feature has multiple applications. The first main use case is to allow the
hgweb interface to display more obsolescence related data, such as the Anton
Shestakov work to add `obslog` support to hgweb.
The second foreseen usecase is support for a `--remote-hidden` argument to `hg
pull` and `hg clone`. This flag will make it possible to retrieve hidden
(typically obsolete) changeset under some conditions. This is useful when
digging up obsolescence history or when doing full mirroring. More on this
feature coming in later changesets.
To avoid exposing information by mistake, access to this feature is currently
controlled with the `experimental.server.allow-hidden-access` config option. The
option works the same way as `web.allow-push`. The current default is to not
allow any hidden access. However we might change it before the feature stop
being experimental.
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 14 Mar 2023 05:30:34 +0100] rev 50472
clone-bundles: add an option to generate bundles in the background
This is what the "on-change" version have been doing from the start, it seems
useful to also offer this option in the command.
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 14 Mar 2023 05:09:16 +0100] rev 50471
clone-bundles: add a command to clear all bundles
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 14 Mar 2023 04:46:53 +0100] rev 50470
clone-bundles: add more test cases for automatic generation
See inline documentation for details.
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 13 Mar 2023 19:16:19 +0100] rev 50469
clone-bundles: introduce a command to refresh bundle
This command allows for a different mode than the one attached to the
transation. It might fit some hosting setup better.
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 13 Mar 2023 04:18:45 +0100] rev 50468
clone-bundles: add a configuration to control auto-generation on changes
We are about to introduce a "manual" way to deal with automatic clone management
but running a command using some internal API. The first step is to introduce a
way to control the "on changes" behavior.
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 13 Mar 2023 18:44:52 +0100] rev 50467
clone-bundles: also control automation based on absolute number of revisions
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 13 Mar 2023 20:01:42 +0100] rev 50466
clone-bundles: only regenerate the clone bundle when cached ration is low
See inline documentation for details.
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 24 Mar 2020 03:25:33 +0100] rev 50465
clone-bundles: garbage collect older bundle when generating new ones
See inline documentation for details.
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 13 Mar 2023 17:34:18 +0100] rev 50464
clone-bundles: add a basic first version of automatic bundle generation
See inline documentation for details.
Raphaël Gomès <rgomes@octobus.net> [Fri, 14 Apr 2023 10:41:40 +0200] rev 50463
branching: merge stable into default
Pierre-Yves David <pierre-yves.david@octobus.net> [Wed, 12 Apr 2023 00:57:01 +0200] rev 50462
tests: automatically glob the discovery timing information
Time is not stable in tests.
Arseniy Alekseyev <aalekseyev@janestreet.com> [Thu, 06 Apr 2023 11:41:51 +0100] rev 50461
rhg: support `status --print0`
This seems very easy to support, and useful because it makes it possible
to parse the [hg status] output even if the user creates files
with '\n' characters by accident.
pacien <pacien.trangirard@pacien.net> [Thu, 30 Mar 2023 22:22:44 +0200] rev 50460
stabletailgraph: implement stable-tail sort
This adds the computation of the "stable-tail sort", an incremental node
sorting method. It is a stepping stone for the implementation of faster
label discovery (for example for obs markers) and more caching.
Raphaël Gomès <rgomes@octobus.net> [Wed, 05 Apr 2023 16:09:08 +0200] rev 50459
heptapod: add `.gitattributes` file to improve language detection
I am fully aware of the irony.