manifest-summary-multiline (ODOO012)
Preview (since 0.16.2.2) · Related issues · View source
Derived from the odoo linter.
Fix is always available.
This rule is unstable and in preview. The --preview flag is required for use.
What it does
Checks that the summary key in an Odoo module's __manifest__.py is a single line.
Why is this bad?
Odoo displays summary as a one-line short description in the Apps list; a newline
breaks that layout.
Example
Use instead:
Only a newline in the summary's value is reported. A summary whose source is spread over several lines — an implicit concatenation, or a backslash continuation — produces a single-line value, so it is left untouched:
{
"summary": "A summary whose source is split across two adjacent string literals "
"even though its value is still a single line.",
}
When the collapsed summary would exceed the configured line length, the fix wraps it into a parenthesized implicit string concatenation instead: