Skip to content

Update to version 7.0.1 of SIL.Chorus.Mercurial to speed up Send/Receive on Windows - #396

Open
rmunn wants to merge 7 commits into
masterfrom
chore/update-mercurial-to-7-dot-star
Open

rmunn wants to merge 7 commits into
masterfrom
chore/update-mercurial-to-7-dot-star

Conversation

@rmunn

@rmunn rmunn commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

Version 7.0.1 of SIL.Chorus.Mercurial has been released, and tested to work on both Windows and Linux with no Chorus code changes needed (all unit tests pass). It's time to update the package version that Chorus depends on, so that downstream projects (like LexBox) that want to update to Mercurial 7.x can do so.

We specify 7.* instead of 7.0.* because there is currently an open PR updating SIL.Chorus.Mercurial to version 7.2.2, and a 7.* spec will allow downstream Chorus-using projects to smoothly update to version 7.2.2 of Mercurial later without requiring a new Chorus PR to be tested and approved.

Important

There will soon be a new version of SIL.Chorus.Mercurial 7.0.1 that changes the build process in a way that would require SIL.BuildTasks version 3.3.0 or later. So I may need to also bump SIL.BuildTasks in this same PR in order for it to build. Not currently required until sillsdev/Mercurial4Chorus#33 is merged, but once sillsdev/Mercurial4Chorus#33 merges then SIL.BuildTasks 3.3.0 or later will become required in order to build the ChorusHub installer.

It would also be possible to say "version 6.5.1.43 or later", i.e.:

<PackageReference Include="SIL.Chorus.Mercurial" Version="[6.5.1.43,)" IncludeAssets="build" />

Or, to keep allowing all 6.5 packages (6.5.1.18 was the first 6.5 package released):

<PackageReference Include="SIL.Chorus.Mercurial" Version="[6.5.1.18,)" IncludeAssets="build" />

That would allow all future SIL.Chorus.Mercurial packages, including 8.x and later which don't exist yet. But it's entirely possible that Mercurial 8 will include breaking changes that would need a corresponding change to SIL.Chorus in order to compile, so it's probably safer to just accept 7.* rather than a truly open-ended NuGet package range.


This change is Reviewable

We specify `7.*` instead of `7.0.*` because there is currently an
open PR updating SIL.Chorus.Mercurial to version 7.2.2, and a `7.*`
spec will allow downstream Chorus-using projects to smoothly update
to version 7.2.2 of Mercurial later without requiring a new Chorus
PR to be tested and approved.
@rmunn rmunn self-assigned this Aug 20, 2026
@rmunn

rmunn commented Aug 20, 2026

Copy link
Copy Markdown
Contributor Author

I have downloaded the SIL.Chorus.Mercurial 7.0.1.58 NuGet package and run the Chorus unit tests against it, on both Linux and Windows. All tests pass.

I have not yet built the Chorus installer and verified that it would work without changes in FLExBridge. That was a concern raised by @hahn-kev in sillsdev/Mercurial4Chorus#30 (review), so it's worth testing. (By someone who has a working setup to build the Chorus installer and test it with FLExBridge and FieldWorks, i.e. not me).

@github-actions

github-actions Bot commented Aug 20, 2026

Copy link
Copy Markdown

Test Results

       8 files  ±0     334 suites  ±0   1h 42m 13s ⏱️ - 44m 1s
1 008 tests ±0     952 ✔️ ±0    56 💤 ±0  0 ±0 
3 197 runs  ±0  3 074 ✔️ ±0  123 💤 ±0  0 ±0 

Results for commit 8f6f7de. ± Comparison against base commit c2c1e42.

♻️ This comment has been updated with latest results.

@rmunn

rmunn commented Aug 26, 2026

Copy link
Copy Markdown
Contributor Author

Installer is failing because it cannot find certain files, which were actually unnecessary in our Chorus Mercurial package (they were part of TortoiseHg and Chorus never uses them) and which I therefore deliberately removed in version 7 of the Mercurial package. I'll go through and see about removing them from the installer, though someone with more experience with WiX may need to help me confirm that the installer will then properly remove them from a user's computer when upgrading from 6.5 to 7.0.1 (or 7.2.2).

Seven files deleted between Mercurial 6.5.1 and 7.0.1, and one new file,
which the installer needs to know about in order to build correctly.
@rmunn

rmunn commented Sep 3, 2026

Copy link
Copy Markdown
Contributor Author

In light of the failing installer build step (caused by the file list changing), we probably shouldn't just set 7.* in the NuGet package version after all, as that will probably cause the build to fail when Mercurial goes from 7.0 to 7.2 (likely to also change the file list). So I'll pin the Mercurial package to 7.0.1.* instead, and make a new PR once we bump Mercurial up to 7.2.x later on.

@rmunn

rmunn commented Sep 15, 2026

Copy link
Copy Markdown
Contributor Author

sillsdev/Mercurial4Chorus#33 has been approved and is going to be merged soon, which will result in a new 7.0.1.xx NuGet package that will require SIL.BuildTasks 3.3. SIL.Chorus.Mercurial 7.0.1.58 is the last NuGet package that will build under SIL.BuildTasks 3.0.

I will add the SIL.BuildTasks update to this PR before merging sillsdev/Mercurial4Chorus#33 so that CI will continue to build.

New SIL.Chorus.Mercurial packages are built using a feature found in
SIL.BuildTasks 3.3.0 or later, the ConsolidatedGuidFile parameter. This
allows a single .guidsForInstaller.all.xml file at the root of a directory
tree, rather than dozens of them scattered throughout the tree.
New Mercurial build has a very different file layout: instead of
packing everything into a library.zip file, which turned out to
be quite inefficient at starting hg.exe, the new Mercurial package
has a bunch of individual files, which causes a much larger installer
but is also much faster to start hg.exe.
These have also been removed from the fixutf8 extension in recent builds
of the SIL.Chorus.Mercurial package, so GeneratedMercurialExtensions.wxs
will fail if it still contains a reference to these files.
@rmunn
rmunn force-pushed the chore/update-mercurial-to-7-dot-star branch from b7ce45e to 32fea00 Compare September 15, 2026 09:08
SIL.BuildTasks 3.3.0 or later is now required in order to build
correctly, so we should make sure that is mentioned in the changelog.
Since the WiX installer needs every individual file listed, and the
new SIL.Chorus.Mercurial build is copying Mercurial source more
directly instead of zipping it into a library.zip file, that means
that future SIL.Chorus.Mercurial releases (e.g., 7.2.x eventually)
are likely to cause installer failures until the WiX generation
build tasks are re-run. So it's probably best to pin a specific
version of SIL.Chorus.Mercurial here rather than saying `7.*`.
@rmunn

rmunn commented Sep 17, 2026

Copy link
Copy Markdown
Contributor Author

@jasonleenaylor The work on SIL.Chorus.Mercurial is completed; it is now 15 MB smaller and runs nearly twice as fast on Windows (at least the Chorus tests run twice as fast; actual speedup on a user machine has not yet been tested).

I've tested the Chorus unit tests extensively, over and over, on Linux and Windows; everything still passes. Is there any other testing you'd like me to do before you take a look at it?

@rmunn rmunn changed the title Update to version 7.* of SIL.Chorus.Mercurial (7.01 current, 7.2.2 upcoming) Update to version 7.0.1 of SIL.Chorus.Mercurial to speed up Send/Receive on Windows Sep 17, 2026
@jasonleenaylor

Copy link
Copy Markdown
Contributor

@jasonleenaylor The work on SIL.Chorus.Mercurial is completed; it is now 15 MB smaller and runs nearly twice as fast on Windows (at least the Chorus tests run twice as fast; actual speedup on a user machine has not yet been tested).

I've tested the Chorus unit tests extensively, over and over, on Linux and Windows; everything still passes. Is there any other testing you'd like me to do before you take a look at it?

I don't think so, I've started the installer testing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants