l10n lint fails on git-only environment, requiring hg
Categories
(Developer Infrastructure :: Lint and Formatting, defect, P3)
Tracking
(firefox101 fixed)
Tracking | Status | |
---|---|---|
firefox101 | --- | fixed |
People
(Reporter: saschanaz, Assigned: ahal)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
created virtual environment CPython3.9.9.final.0-64 in 40ms
creator CPython3Windows(dest=C:\Users\sasch\Documents\GitHub\gecko-dev\obj-x86_64-pc-mingw32\_virtualenvs\common, clear=False, no_vcs_ignore=False, global=False)
activators BashActivator,BatchActivator,FishActivator,PowerShellActivator,PythonActivator
Traceback (most recent call last):
File "c:\users\sasch\documents\github\gecko-dev\python\mozlint\mozlint\roller.py", line 228, in setup
res = findobject(linter["setup"])(
File "C:\Users\sasch\Documents\GitHub\gecko-dev\tools\lint\python\l10n_lint.py", line 93, in gecko_strings_setup
hg = mozversioncontrol.get_tool_path("hg")
File "c:\users\sasch\documents\github\gecko-dev\python\mozversioncontrol\mozversioncontrol\__init__.py", line 63, in get_tool_path
raise MissingVCSTool(
mozversioncontrol.MissingVCSTool: Unable to obtain hg path. Try running |mach bootstrap| to ensure your environment is up to date.
error: problem with lint setup, skipping android-api-lint, android-checkstyle, android-format, android-javadoc, android-lint, android-test, l10n
But mach bootstrap
won't install hg if you are on git.
Comment 1•2 years ago
|
||
The severity field is not set for this bug.
:ahal, could you have a look please?
For more information, please visit auto_nag documentation.
Assignee | ||
Comment 2•2 years ago
|
||
Interesting, I'm not sure what's going on here. Fwiw, I know many people using mach lint
with git + cinnabar (and have done so myself in the past). Do you have cinnabar installed here?
Reporter | ||
Comment 3•2 years ago
|
||
I do have git+cinnabar.
https://searchfox.org/mozilla-central/rev/d34f9713ae128a3138c2b70d8041a535f1049d19/tools/lint/python/l10n_lint.py#83-98 shows it clearly depends on mercurial for whatever reason.
Comment 4•2 years ago
|
||
The severity field is not set for this bug.
:ahal, could you have a look please?
For more information, please visit auto_nag documentation.
Assignee | ||
Comment 5•2 years ago
|
||
Ah ok, I believe this traceback isn't fatal correct? So this bug is more about the error message being a bit scarier than it needs to be. Bootstrapping Mercurial for git users is definitely out of scope for mozlint
, so I'll just hide the traceback from the error message and make it a bit less scary.
So you'll either need to install Mercurial yourself, or just live with the l10n
linter not running locally. It'll still run on your try pushes and via reviewbot on moz-phab.
Assignee | ||
Comment 6•2 years ago
|
||
This case can happen for Git users.
Updated•2 years ago
|
Updated•2 years ago
|
Comment 7•2 years ago
|
||
The severity field is not set for this bug.
:ahal, could you have a look please?
For more information, please visit auto_nag documentation.
Assignee | ||
Updated•2 years ago
|
Pushed by ahalberstadt@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/64eb6b660e81 Make l10n linter error less scary when Mercurial doesn't exist, r=linter-reviewers,sylvestre
Comment 9•2 years ago
|
||
bugherder |
Updated•2 years ago
|
Description
•