Raphaël Gomès <rgomes@octobus.net> [Tue, 01 Oct 2024 13:45:18 +0200] rev 52046
rust-cpython: add a util to get a `Repo` from a python path
I suspect this will not be the last time we need to do something like this.
Raphaël Gomès <rgomes@octobus.net> [Tue, 01 Oct 2024 13:20:40 +0200] rev 52045
rust: improve `InvalidRevision` error message
I encountered this when debugging earlier and felt like we were losing some
information along the way, which we were!
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 17:19:35 +0200] rev 52044
rust-dirstate: use a struct as arguments for the high-level `reset_state`
This makes the interface a lot clearer at the call site and prevents silly
mistakes, as an API with a bunch of booleans is prone to errors.
This refactor adds a `from_empty` parameter for a fast-path when resetting
and entry we're sure does not exist. It will be used in the upcoming update
Rust fastpath, and was not split to prevent more churn.
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 16:55:11 +0200] rev 52043
rust: implement `From<SparseConfigWarning>` for `HgError`
This will be useful in a future patch to avoid a lot of boilerplate.
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 16:04:51 +0200] rev 52042
rust-hg-cpython: add an `HgProgressBar` util
This will be the entry point for all progress bars from a Python context
in upcoming patches. Like the `Progress` trait, this is subject to change
once we have more use cases, but this is good enough for now.
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 16:02:30 +0200] rev 52041
rust: add `Progress` trait for progress bars
This will be used in the next few changes to introduce a progress bar for
the `hg update` fastpath.
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 19:15:19 +0200] rev 52040
rust-files: separate the listing of files from a revset and a revision
We won't need to parse a revset all the time, and an upcoming patch will make
use of this new util.
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 19:12:42 +0200] rev 52039
rust-files: add a `Sync` bound to the matcher
This enables us to use this code in multithreaded environements, which we
very much want to do.
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 12:10:35 +0200] rev 52038
rust-files: also return filenode and flags when listing a revision's files
This is going to be useful when implementing parts of `update` and makes it
so we don't have to fetch the manifest and each entry twice.
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 12:08:49 +0200] rev 52037
rust-manifest: encode flags as `Option<NonZeroU8>`
This makes the compiler use the niche optimization for all flags: since 0 is
not a valid representation of any flags, we can use 0 as a replacement for
`None`, which reduces memory footprint and could yield a little performance
improvement over many iterations.
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 17:46:52 +0200] rev 52036
rust-repo: add a method to set the current parents
This will be useful when we start writing an `hg update` fastpath.
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 17:46:24 +0200] rev 52035
rust-repo: add a method to get a `Node` from a `Revision` to the `Repo`
This is going to be more and more useful as we start writing higher-level code
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 17:45:10 +0200] rev 52034
rust-utils: move the `filesystem_now` function to a util
This is going to be useful for an upcoming `hg update` fastpath.
Raphaël Gomès <rgomes@octobus.net> [Mon, 30 Sep 2024 17:43:51 +0200] rev 52033
rust-dirstate: actually remember the identity
This was an oversight that likely had no influence on anything since we have
only been writing the dirstate for status. We will start writing the dirstate
for more operations now, so we'll need this fixed.
Raphaël Gomès <rgomes@octobus.net> [Wed, 21 Aug 2024 09:48:14 +0200] rev 52032
mergestate: reduce the number of attribute lookups
This code is called a lot during updates, this is a very small but also very
easy thing to do.
Raphaël Gomès <rgomes@octobus.net> [Wed, 23 Oct 2024 14:02:28 +0200] rev 52031
test-lfs-serve-access: account for output differences in Python 3.12
This test is quite noisy, but the fix was very easy.
Raphaël Gomès <rgomes@octobus.net> [Wed, 23 Oct 2024 13:49:54 +0200] rev 52030
patchbomb: don't test ambiguous address
This is a bug in Python's `email` package and shouldn't be relied on.
Python 3.12 has fixed this problemĀ¹ and raises an exception. We keep the
multiple `-t` because this is still relevant for testing.
[1] https://github.com/python/cpython/issues/102988
[2] https://docs.python.org/3/whatsnew/changelog.html
Matt Harbison <matt_harbison@yahoo.com> [Mon, 21 Oct 2024 11:48:09 -0400] rev 52029
contrib: install pip 24.2 in the Windows dependency installer script
One of the modern pythons was crying about the old version importing `distutils`.
Matt Harbison <matt_harbison@yahoo.com> [Sat, 19 Oct 2024 01:22:25 -0400] rev 52028
contrib: install the latest py 3.11-3.13 in the Windows dependency script
Note that python 3.11 adds an installer for arm64, which we ignore here because
I don't have a Windows system running arm64, and it's likely we will be dropping
support for some platforms before I get my hands on one.
Matt Harbison <matt_harbison@yahoo.com> [Sat, 19 Oct 2024 01:05:50 -0400] rev 52027
contrib: update to the latest py3.9 and 3.10 in the Windows dependency script
Python3.8 was already at its last version with an installer, FWIW.
Matt Harbison <matt_harbison@yahoo.com> [Sat, 19 Oct 2024 00:57:52 -0400] rev 52026
contrib: drop python 3.7 from the Windows dependency installer script
I'm tempted to drop 3.8 too, since we use 3.9 on Windows.
Matt Harbison <matt_harbison@yahoo.com> [Sat, 19 Oct 2024 00:50:49 -0400] rev 52025
contrib: drop python 3.5 requirements file for Linux automation
The new minimum this cycle is py3.8.
Matt Harbison <matt_harbison@yahoo.com> [Wed, 16 Oct 2024 18:06:36 -0400] rev 52024
windows: implement `util.cachestat` to fix numerous dirstate problems
I got here by bisecting the
issue1790 related failure on Windows to keep an
entry from being marked "unset" in `test-dirstate.t` back to
eedbf8256263.
There were a handful of other tests failing with an unexpected dirstate entry
state like this, as well as numerous "skip updating dirstate: identity mismatch"
messages added to various tests, as well as an issue with dirstate wrapping with
the largefiles extension[1], all of which appear to be fixed by this. In total,
~25 tests are fully fixed on Windows with this change on default.
This is basically a copy/paste of the posix implementation, but we drop the
`st_mode` comparison- I think the only reason we care about the mode on posix is
to detect +/-x mode changes, but the executable bits on Windows are synthesized
based on the name of the file[2]. None of the other parts of the codebase are
equipped to handle executable bits in the filesystem on Windows anyway, so it
doesn't make sense to worry about them here.
Note that `st_uid` and `st_gid` seem to always be 0 on Windows (and I can't find
them being initialized), so they can probably be dropped from the comparison.
But I doubt they matter any more on posix, since we don't track ownership. The
`st_ino`, `st_dev`, and `st_nlink` attributes all seem to have reasonable values
for comparing like on posix[3].
Also note that `st_ctime` is apparently deprecated in 3.12+ (for reasons I
haven't explored)[4].
[1] https://foss.heptapod.net/mercurial/mercurial-devel/-/merge_requests/884
[2] https://github.com/python/cpython/blob/
aab3210271136ad8e8fecd927b806602c463e1f2/Modules/posixmodule.c#L1948
[3] https://github.com/python/cpython/blob/
aab3210271136ad8e8fecd927b806602c463e1f2/Python/fileutils.c#L1158
[4] https://github.com/python/cpython/blob/
aab3210271136ad8e8fecd927b806602c463e1f2/Modules/posixmodule.c#L2200
Ludovic Chabant <ludovic@chabant.com> [Mon, 04 Feb 2019 23:32:20 -0800] rev 52023
extdiff: don't run gui programs when in a cli-only environment
In order to provide a useful error message to override the behavior, we also
need to slightly change the way that tool.gui is found in the config. Before,
it had to be where tool.diffargs is located, which might not exist. Now,
tool.isgui can exist on its own.
A test is added for the new error message. We also need to force
procutil.isgui() to return true, so we set $DISPLAY to a non-empty value
before running any test expecting to have a gui.
Ludovic Chabant <ludovic@chabant.com> [Wed, 28 Dec 2022 21:33:44 -0800] rev 52022
bookflow: fix bullet list indentation in docstring
Ludovic Chabant <ludovic@chabant.com> [Mon, 09 Oct 2023 22:14:24 -0700] rev 52021
doc: generate separate commands/topics/extension pages
This change modifies gendoc.py and Makefile so that individual pages for
commands, help topics, and extensions can be generated. A new index page is
also generated with links to all these pages. This makes it easier to look up
and search the help text of a given command or topic, instead of having to
deal with the giant hg.1 "all-in-one" page.
Since the list of individual pages varies based on the source code, we generate
a dynamic Makefile that contains this list of files as individual targets.
This gives us fine-grained control over output files. However, it greatly
increases the time spent generating all help pages. It's recommended to run
make with -j to make use of multi-core archs.
Individual man pages are produced in doc/man, and HTML ones are in doc/html
Ludovic Chabant <ludovic@chabant.com> [Mon, 09 Oct 2023 22:11:21 -0700] rev 52020
doc: refactor gendoc for better reusability
This change separates the gathering of commands/topics/etc from the logic of
printing their documentation out.
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 01 Oct 2024 16:07:51 +0200] rev 52019
stream: prefer keeping an open file handle to volatile file instead of copy
We will still do copy if too many file handle are open. Currently, have less
than 10 volatile files in typical usage, so we should be fine.
See inline documentation for details.
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 01 Oct 2024 15:55:49 +0200] rev 52018
stream: remove __getitem__ from the VolatileManager
It is no longer used and that API will get in the way of the new order.
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 01 Oct 2024 15:55:29 +0200] rev 52017
stream: open volatile file through the manager
To do more subtle things, we need more control.
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 14 Oct 2024 15:11:49 +0200] rev 52016
stream: rename TempCopyManager to VolatileManager
We are going to be more subtle in our management of volatile file, so use a more
semantic name.
Matt Harbison <matt_harbison@yahoo.com> [Mon, 14 Oct 2024 12:12:34 -0400] rev 52015
ci: only use the macOS runner if manually invoked
Right now, we only have a single machine with a single runner, so don't create a
bottleneck by default.