Update the bundled the `watchman` in `MozillaBuild` to version `v2025.02.24.00`
Categories
(Firefox Build System :: MozillaBuild, task, P2)
Tracking
(Not tracked)
People
(Reporter: ahochheiden, Assigned: ahochheiden)
References
Details
Attachments
(2 files)
The current bundled version of watchman is v2022.04.11.00, which is over two years old.
Edit: This bug has been repurposed to remove the bundled watchman from MozillaBuild, as it is no longer necessary on Windows after our changeover to git. See details below.
| Assignee | ||
Updated•7 months ago
|
Comment 1•7 months ago
|
||
fwiw, I found fsmonitor = true and fscache = true in git working as well as watchman, or even better. Are we sure watchman is still necessary?
| Assignee | ||
Comment 2•7 months ago
|
||
I was under the impression that fsmonitor was a consumer of watchman, but maybe the capabilities of fsmonitor have been expanded? I'll do some research. I've been meaning to dig into this anyway. When using jj I think I concluded that watchman was slowing down/conflicting with jj's built in equivalent (I experienced much better performance after I turned watchman off).
I also think with the full git changeover most people are not going to have watchman enabled, either. I think it's only enabled by the standalone bootstrap script (since we don't have query-watchman anywhere else in tree) and the instructions that were sent out were to just do a raw git clone https://github.com/mozilla-firefox/firefox.git, so anyone who followed the changeover instructions won't have watchman enabled without manual intervention (currently).
I do want to add jj to ./mach vcs-setup and if my initial findings about watchman are correct, then I'd need to jj setup to disable watchman on git, but have a git ./mach vcs-setup re-enable it (assuming it is better than just pure fsmonitor), that would fix the missing path due to the raw clone without strict manual intervention (most people eventually run ./mach bootstrap, which runs ./mach vcs-setup).
If it's not useful for git nor jj, then yes, we should remove it from MozillaBuild and the standalone bootstrap script, but I'll need to get some data to convince me of that first.
| Assignee | ||
Comment 3•7 months ago
•
|
||
https://github.blog/open-source/git/highlights-from-git-2-37
In the past, Git has made it possible to integrate with tools like Watchman via a hook, making it possible to replace Git’s expensive refreshing process with a long-running daemon which tracks the filesystem state more directly.
But setting up this hook and installing a third-party tool can be cumbersome. In Git 2.37, this functionality is built into Git itself on Windows and macOS, removing the need to install an external tool and configure the hook.
Very well, on Windows and macOS we don't need watchman anymore. We still need it on Linux, but that simplifies things greatly. I think I came across this information ages ago, but kind of disregarded it since we still needed it for hg. Now that we're switching off hg fully to git, in the context of this bug, we no longer need to bundle watchman.
| Assignee | ||
Comment 4•7 months ago
|
||
We do still need to make ./mach vcs-setup enable fsmonitor, though. I will raise a bug.
| Assignee | ||
Comment 5•7 months ago
|
||
Actually, let's re-use this bug, since it contains all the useful information.
| Assignee | ||
Comment 6•7 months ago
|
||
(In reply to Marco Bonardo [:mak] from comment #1)
fwiw, I found
fsmonitor = trueandfscache = truein git working as well as watchman, or even better. Are we sure watchman is still necessary?
Thanks for asking this question!
| Assignee | ||
Comment 7•7 months ago
|
||
Since we're not fully ripping out hg support yet, we should keep watchman around for this cycle, as hg still needs watchman to have acceptable performance.
| Assignee | ||
Comment 8•7 months ago
|
||
| Assignee | ||
Comment 9•7 months ago
|
||
Comment 10•6 months ago
|
||
Pushed by ahochheiden@mozilla.com:
https://hg.mozilla.org/mozilla-build/rev/326cab29f802
Bump the bundled watchman version to v2025.02.24.00 in MozillaBuild r=firefox-build-system-reviewers,nalexander
https://hg.mozilla.org/mozilla-build/rev/bd832176ae4b
Make the watchman- zip be automatically detected by packageit.py r=firefox-build-system-reviewers,nalexander
Description
•