Closed
Bug 1591977
Opened 5 years ago
Closed 5 years ago
"TypeError: run_rustfmt() missing 1 required positional argument: 'log'" when running mach lint -l rustfmt --fix
Categories
(Developer Infrastructure :: Lint and Formatting, defect)
Tracking
(firefox72 fixed)
RESOLVED
FIXED
mozilla72
Tracking | Status | |
---|---|---|
firefox72 | --- | fixed |
People
(Reporter: mstange, Assigned: ahal)
References
(Regression)
Details
(Keywords: regression)
Attachments
(2 files)
I wanted to see what would happen if I rust-formatted gfx/wr/webrender
but got an error:
mozilla mstange$ hg diff
diff --git a/tools/lint/rustfmt.yml b/tools/lint/rustfmt.yml
--- a/tools/lint/rustfmt.yml
+++ b/tools/lint/rustfmt.yml
@@ -1,13 +1,14 @@
---
rust:
description: Reformat rust
include:
- js/src/wasm/cranelift/
+ - gfx/wr/webrender/
- testing/geckodriver/
- testing/mozbase/rust/
- testing/webdriver/
extensions:
- rs
support-files:
- 'tools/lint/rust/**'
type: external
mozilla mstange$ ./mach lint -l rustfmt gfx/wr/webrender/
✖ 0 problems (0 errors, 4356 warnings)
mozilla mstange$ hg ci -m "Add gfx/wr/webrender to the rustfmt lint list."
mozilla mstange$ ./mach lint -l rustfmt gfx/wr/webrender/ --fix
Traceback (most recent call last):
File "/Users/mstange/code/mozilla/python/mozlint/mozlint/roller.py", line 55, in _run_worker
res = func(paths, config, **lintargs) or []
File "/Users/mstange/code/mozilla/python/mozlint/mozlint/types.py", line 54, in __call__
return self._lint(paths, config, **lintargs)
File "/Users/mstange/code/mozilla/python/mozlint/mozlint/types.py", line 139, in _lint
return func(files, config, **lintargs)
File "/Users/mstange/code/mozilla/tools/lint/rust/__init__.py", line 158, in lint
run_rustfmt(config, files, fix=True)
TypeError: run_rustfmt() missing 1 required positional argument: 'log'
A failure occurred in the rust linter.
✖ 1 problem (0 errors, 0 warnings, 1 failure)
Assignee | ||
Comment 1•5 years ago
|
||
Thanks for reporting!
Updated•5 years ago
|
Keywords: regression
Assignee | ||
Comment 2•5 years ago
|
||
Assignee | ||
Comment 3•5 years ago
|
||
This matches the behaviour of the other linters.
Depends on D50822
Assignee | ||
Comment 4•5 years ago
|
||
Also fyi, you can run ./mach lint --warnings
to see the warnings (which includes diffs).
Reporter | ||
Comment 5•5 years ago
|
||
Cool! Thanks for the quick fix!
Pushed by ahalberstadt@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/edfae1797e9b
[lint.rustfmt] Fix error when running 'mach lint -l rustfmt --fix', r=sylvestre
https://hg.mozilla.org/integration/autoland/rev/8b5ad87bc066
[lint.rustfmt] Don't print issues if --fix is passed in, r=sylvestre
Comment 7•5 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/edfae1797e9b
https://hg.mozilla.org/mozilla-central/rev/8b5ad87bc066
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
status-firefox72:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla72
Updated•3 years ago
|
Has Regression Range: --- → yes
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
•