Closed
Bug 1487425
Opened 6 years ago
Closed 6 years ago
AttributeError: 'dict' object has no attribute 'failed' when pushing / committing / ...
Categories
(Developer Infrastructure :: Lint and Formatting, defect)
Developer Infrastructure
Lint and Formatting
Tracking
(firefox-esr60 unaffected, firefox61 unaffected, firefox62 unaffected, firefox63 fixed)
RESOLVED
FIXED
mozilla63
Tracking | Status | |
---|---|---|
firefox-esr60 | --- | unaffected |
firefox61 | --- | unaffected |
firefox62 | --- | unaffected |
firefox63 | --- | fixed |
People
(Reporter: Gijs, Assigned: ahal)
References
Details
(Keywords: regression)
Attachments
(1 file)
full output: $ hg push-to-try -m "Bug 1486824 - try: -b od -t none -p win64,macosx64,linux64,linux -u mochitest-bc --artifact " Creating temporary commit for remote... warning: no files linted Error running mach: ['lint', '--quiet', '--workdir=staged'] The error occurred in code that was called by the mach command. This is either a bug in the called code itself or in the way that mach is calling it. You should consider filing a bug for this issue. If filing a bug, please include the full output of mach, including this error message. The details of the failure are as follows: AttributeError: 'dict' object has no attribute 'failed' File "tools/lint/mach_commands.py", line 44, in lint return cli.run(*runargs, **lintargs) File "python/mozlint/mozlint/cli.py", line 184, in run out = formatter(result).encode(sys.stdout.encoding or 'ascii', 'replace') File "python/mozlint/mozlint/formatters/stylish.py", line 55, in __call__ failed = result.failed This has been happening for a while now, and successive updates of m-c have somehow not fixed it, so here's a bug report... Feels like the lack of files to lint means that the result object is empty and the formatter doesn't know how to deal with this.
Reporter | ||
Comment 1•6 years ago
|
||
Oh, and I have: pretxncommit.lint = python:path/to/m-c/tools/lint/hooks.py:hg defined in .hg/hgrc on the trees where this happens. But happens on both my Windows and mac machines...
Assignee | ||
Comment 2•6 years ago
|
||
Sorry about that, this is a regression from bug 1460856.
Assignee | ||
Comment 3•6 years ago
|
||
This is a regression from bug 1460856.
Reporter | ||
Comment 4•6 years ago
|
||
Comment on attachment 9005607 [details] Bug 1487425 - [mozlint] Fix regression where 'roll' returns dict instead of ResultSummary when no files linted, r=gijs :Gijs (he/him) has approved the revision.
Attachment #9005607 -
Flags: review+
Pushed by ahalberstadt@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/56d916d0bfb1 [mozlint] Fix regression where 'roll' returns dict instead of ResultSummary when no files linted, r=Gijs
Assignee | ||
Comment 6•6 years ago
|
||
Somewhat related, we should try to get the `push-to-try` extension to skip the lint check when committing the temporary commit. There will never be a dirty working directory anyway (as |mach try| would have errored out if before this point if there were).
Comment 7•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/56d916d0bfb1
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
status-firefox63:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla63
Reporter | ||
Comment 8•6 years ago
|
||
(In reply to Andrew Halberstadt [:ahal] from comment #6) > Somewhat related, we should try to get the `push-to-try` extension to skip > the lint check when committing the temporary commit. There will never be a > dirty working directory anyway (as |mach try| would have errored out if > before this point if there were). I still use `hg push-to-try` directly, also with a dirty working dir (which then gets temp-committed). This is particularly useful for things like sec bugs, where I don't want to publish the original commit or bug number. Instead I `hg up` to a known good other bug, `hg diff -c <sec-bug-rev> | patch`, and then push-to-try . Really what we need is a confidential copy of tryserver, but that's been on the wishlist for 5 years and has never happened, so I'm not holding my breath. In the meantime, if we could not break this type of usecase, that'd be great...
Updated•6 years ago
|
status-firefox61:
--- → unaffected
status-firefox62:
--- → unaffected
status-firefox-esr60:
--- → unaffected
Assignee | ||
Comment 9•6 years ago
|
||
(In reply to :Gijs (he/him) from comment #8) > I still use `hg push-to-try` directly, also with a dirty working dir (which > then gets temp-committed). This is particularly useful for things like sec > bugs, where I don't want to publish the original commit or bug number. > Instead I `hg up` to a known good other bug, `hg diff -c <sec-bug-rev> | > patch`, and then push-to-try . > > Really what we need is a confidential copy of tryserver, but that's been on > the wishlist for 5 years and has never happened, so I'm not holding my > breath. In the meantime, if we could not break this type of usecase, that'd > be great... Wfm, didn't realize anyone was using `hg push-to-try` directly. If it helps, we could add a --force flag to |mach try| to skip the uncommitted changes check. It's entirely superficial.
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
•