Contributors mailing list archives

contributors@odoo-community.org

Browse archives

Avatar

Enable new checks and suggest a new Project - Modules pylint-oca for custom lint of odoo

by
Vauxoo, Moisés López Calderón
- 09/09/2015 03:51:35
New checks:
Leveraging this thread:
 - We have a PR/234 in MQT to enable new checks just in modules changed of all OCA projects, then you will see a new red in your PR travis-builds by this matter.
 - Your feedback is welcome.
 -
Anticipate your open PR's and new ones.
 - NOTE: IMHO PR/234 don't depend of new project, we can work in parallel.

New project suggest:
Name of the project
pylint-oca

Description
We have many guidelines without a lint tool.
A project called django use a project similar to create tools of auto-check custom guidelines: pylint-django

We need a custom tools for odoo to check:
 - Missing author required "Odoo Community Association (OCA)" in manifest file
 - Missing required key in manifest file.
 - Deprecated key  in manifes file.
 - No UTF-8 coding comment found.
 - RST syntax error
 - Use of vim comment
 - Missing ./README.rst file
 - Use CamelCase in >=v8
 - Import Warning should be renamed as UserError from openerp.exceptions import Warning as UserError
 ... and so on.

Now, we are creating manually messages in each pr with this cases.
If we can automate it... why not automate it.
Save time to developer, save time to reviewers.

Why not in MQT:
 - This tool can be used in local by all developers without depend of MQT then we can create a single project to this case and enable in pypi.

Roadmap:
 - Create plugin of oca-pylint with 100% of coverage in test.
 - Add new checks (welcome feedback).

NOTE: Currently we have oca-pylint with 100% of coverage in test here (waiting new project).

Team:
MQT-maintainers.

--
Moisés López Calderón
Vauxoo - OpenERP's Gold Partner
Mobile: (+521) 477-752-22-30
Office: (+52) 477-773-33-46
web: http://www.vauxoo.com
twitter: @vauxoo
           @moylop260