Linux opt format and tidy bustages with bash: ./mach: Argument list too long
Categories
(Developer Infrastructure :: Lint and Formatting, defect, P2)
Tracking
(firefox68 fixed)
| Tracking | Status | |
|---|---|---|
| firefox68 | --- | fixed |
People
(Reporter: CosminS, Assigned: bastien)
References
(Regression)
Details
(Keywords: intermittent-failure, regression)
Attachments
(2 files)
Comment 1•6 years ago
|
||
When the command line is too long, we should split into several executions.
(this is what we are doing for clang-format)
Comment 2•6 years ago
|
||
Does clang-format already accept @resource-file arguments? mach whatever could accept those too.
| Assignee | ||
Comment 3•6 years ago
|
||
This error happens because both ./mach clang-format and ./mach static-analysis check CI tasks need the list of files modified in the try push.
This is done in taskcluster/scripts/misc/source-test-clang-setup.sh by creating an environment variable TRY_MODIFIED_FILES, and you can see the export line in the log file from this bug.
We could do this in the Python code directly to avoid creating huge environment variables by adding a mercurial revision option. Andrew, what do you think of this solution ? I can implement it.
Comment 4•6 years ago
|
||
You would need to use all files touched in the push, not just a single revision. Luckily we have a function that gives you that already:
https://searchfox.org/mozilla-central/source/python/mozversioncontrol/mozversioncontrol/__init__.py#309
Another alternative would be to modify the mach_commands.py itself to read that environment variable instead of passing it in on the task command line.
| Assignee | ||
Updated•6 years ago
|
| Assignee | ||
Comment 5•6 years ago
|
||
| Reporter | ||
Comment 6•6 years ago
|
||
There is also this failure now on trees: https://treeherder.mozilla.org/logviewer.html#/jobs?job_id=236298018&repo=mozilla-inbound&lineNumber=463
[task 2019-03-27T05:22:06.928Z] ++ cd /builds/worker/checkouts/gecko
[task 2019-03-27T05:22:06.928Z] +++ hg status --rev 'max(ancestors(tip) and public())' -q --no-status
[task 2019-03-27T05:22:09.514Z] ++ export TRY_MODIFIED_FILES=
[task 2019-03-27T05:22:09.514Z] ++ TRY_MODIFIED_FILES=
[task 2019-03-27T05:22:09.514Z] + cd /builds/worker/checkouts/gecko
[task 2019-03-27T05:22:09.514Z] + ./mach --log-no-times clang-format --path --output /builds/worker/clang-format.json --format json
[task 2019-03-27T05:22:09.812Z] usage: mach [global arguments] clang-format [command arguments]
[task 2019-03-27T05:22:09.812Z] mach: error: argument --path/-p: expected at least one argument
[taskcluster 2019-03-27 05:22:10.368Z] === Task Finished ===
[taskcluster 2019-03-27 05:22:10.481Z] Artifact "public/code-review/clang-format.json" not found at "/builds/worker/clang-format.json"
[taskcluster 2019-03-27 05:22:11.272Z] Unsuccessful task run with exit code: 2 completed in 338.428 seconds
| Comment hidden (Intermittent Failures Robot) |
| Comment hidden (Intermittent Failures Robot) |
| Assignee | ||
Comment 9•6 years ago
|
||
Comment 10•6 years ago
|
||
Comment 11•6 years ago
|
||
| bugherder | ||
Comment 12•6 years ago
|
||
Updated•6 years ago
|
Updated•6 years ago
|
Comment 13•6 years ago
|
||
| bugherder | ||
| Comment hidden (Intermittent Failures Robot) |
Updated•6 years ago
|
Updated•4 years ago
|
Updated•3 years ago
|
Description
•