Closed Bug 1650306 Opened 4 years ago Closed 4 years ago

Enable the "no-else-return" rule in pylint and fix the existing issues

Categories

(Developer Infrastructure :: Lint and Formatting, task)

Tracking

(firefox80 fixed)

RESOLVED FIXED
mozilla80
Tracking Status
firefox80 --- fixed

People

(Reporter: Sylvestre, Assigned: manish.giri.me, Mentored)

References

(Blocks 1 open bug)

Details

(Keywords: good-first-bug, Whiteboard: [lang=python])

Attachments

(2 files, 1 obsolete file)

This can be done by adding the option here:
https://searchfox.org/mozilla-central/source/tools/lint/python/pylint.py#109

Then run with

$ ./mach lint -l pylint  --verbose

As the change should be easy, it is just to learn how to contribute to Firefox.

Tutorial to contribute:
https://firefox-source-docs.mozilla.org/contributing/contribution_quickref.html

Please don't ask for the bug to be assigned. It will be automatically assigned to the first patch.

Hello, I have previously submitted a few one-line patches to Mozilla, but that was in C++, and not in the "Lint and Formatting" project. I just wanted to check if I can still submit a patch for this.

Sure :)

Thank You! I'll get on it right away.

Assignee: nobody → manish.giri.me
Status: NEW → ASSIGNED
Attachment #9161834 - Attachment is obsolete: true
Attachment #9161838 - Attachment description: Bug 1650306 - Enable 'no-else-return' rule, pylint. r?Sylvestre → Bug 1650306 - mozlint/pylint - Enable 'no-else-return' rule r?Sylvestre
Attachment #9161839 - Attachment description: Bug 1650306 - Fix issues which conflict with Pylint 'no-else-return' rule. r?Sylvestre → Bug 1650306 - Address the defects found by the pylint/no-else-return rule. r?Sylvestre
Pushed by sledru@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/ff64dd0c6510
mozlint/pylint - Enable 'no-else-return' rule r=sylvestre
https://hg.mozilla.org/integration/autoland/rev/4a5fa0f58c63
Address the defects found by the pylint/no-else-return rule. r=sylvestre
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla80
Product: Firefox Build System → Developer Infrastructure
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: