Closed
Bug 1516733
Opened 6 years ago
Closed 6 years ago
hg: clang-format hook is broken (error: pretxncommit.clang-format hook raised an exception: No module named hglib.client)
Categories
(Developer Infrastructure :: Lint and Formatting, defect)
Developer Infrastructure
Lint and Formatting
Tracking
(Not tracked)
RESOLVED
WONTFIX
People
(Reporter: jwatt, Unassigned)
References
Details
Attachments
(1 obsolete file)
https://hg.mozilla.org/mozilla-central/rev/d7507f185a63 (from bug 1514770 comment 3) broke the clang-format hook for hg (for me on Mac at least). Specifically:
hg ci -m "bad"
committing files:
layout/svg/SVGFEContainerFrame.cpp
committing manifest
committing changelog
calling hook pretxncommit.clang-format: hghook_pretxncommit_clang-format.hg
error: pretxncommit.clang-format hook raised an exception: No module named hglib.client
transaction abort!
rollback completed
abort: No module named hglib.client!
Reverting that change locally gets things working.
Reporter | ||
Comment 1•6 years ago
|
||
It took quite a bit of digging through m.d.platform email and bugs to figure out that there were hooks available and how to use them. Given that nobody else has reported this breakage in the last couple of weeks I'm assuming that I'm not the only one who didn't get the message that hooks existed. A PSA to m.d.platform once these are working again would seem to be in order. :)
Comment 2•6 years ago
|
||
Hmm, you enabled the clang-format hook yourself, right?
How did you enable it? thanks and sorry for this issue
Reporter | ||
Comment 3•6 years ago
|
||
No worries, running `./mach clang-format` manually isn't the end of the world. :)
I enabled the hook myself by adding the following to my .hgrc:
[hooks]
pretxncommit.clang-format = python:./tools/lint/hooks_clang_format.py:hg
Reporter | ||
Comment 4•6 years ago
|
||
I should say the same error occurs whether that's added to the repo's .hg/hgrc or to $HOME/.hgrc
Comment 5•6 years ago
|
||
Updated•6 years ago
|
Attachment #9041129 -
Attachment is obsolete: true
Comment 6•6 years ago
|
||
We moved to an extension in bug 1525725, so, this bug is not relevant anymore
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
Updated•2 years ago
|
Product: Firefox Build System → Developer Infrastructure
You need to log in
before you can comment on or make changes to this bug.
Description
•