Sunday, May 18, 2025
4 changes · master
Resolved issues and error corrections
This fixes an issue in the web guided tour system related to drag-and-drop steps. It helps automated onboarding or training flows run more reliably, reducing interruptions when users or tests follow guided actions.
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This pull request confirms contributor license compliance and includes several reliability fixes across Odoo apps. It improves accounting partner updates, tax report totals, invoice generation permissions, calendar syncing, and company data enrichment so users see more accurate data and fewer errors.
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update fixes and standardizes internal documentation across many Odoo modules so automated documentation can be generated more reliably. It helps future API and model documentation show accurate parameters, types, examples, and guidance for teams using or extending Odoo.
Original PR description
We are doing a new `/doc` endpoint where we list all the models, their fields, their public methods. For every public method we list the parameters, their type, their default value and a help…
This update fixes formatting issues in internal documentation comments across several Odoo Enterprise apps. It helps automated quality checks pass and keeps developer-facing guidance clearer, with no expected change to day-to-day user workflows.
We are doing a new `/doc` endpoint where we list all the models, their fields, their public methods.
For every public method we list the parameters, their type, their default value and a help message.
We also provide with actual *runnable in the browser* examples how to call those methods in RPC.
The problem is that we fail to parse the docstring in far too many functions, because the rst is broken, or because not all parameters are correctly documented.
So, because we are very sane people, we decided to...

(plus it makes for an excellent thing to talk about on Friday :smiling_imp:)
### Fix all `:param:` found in docstring
**Typo in parameter name**
```py
def foo(self, bar):
"""
:param baz: blablabla
"""
```
**Malformed tag**
```py
""":param: baz blablabla"""
```
**Inconsistent type**
```py
def foo(self, bar: int | float):
"""
:param int bar: blablabla
"""
```
**Bogus `**kwargs`**
We also noted several functions that are abusing `**kwargs` but actually document a bunch of parameters. We decided not to lint those, and to only emits a logging.info. I wish to change them someday.
```
def foo(self, **kwargs):
"""
:param bar: blablabla
:param egg: blablabla
:param spam: blablabla
"""
```
There are also other mistakes we fixed, just read the commit n°2
### reStructuredText syntax error
While working on the first linter, we had to silence the docutils parser because it emitted too many warnings for badly structured rst.
The commit n°3 enabled those warnings and it reported several hundreds of broken docstrings.
With commit n°4 we decided on a per-module approach, starting with base (and base-inherited models), because there were damn too many docstrings to fix.
The common mistakes were:
**Missing empty line before list**
```rst
Items:
- one
- two
```
instead of
```rst
Items:
- one
- two
```
**Indented list**
```rst
Items:
- one
- two
```
instead of
```rst
Items:
- one
- two
```
**Bad code block**
```rst
:return: a list in the form
{
"a": 1,
}
```
instead of either
```rst
:return: a list in the
form::
{
"a": 1,
}
```
or
```rst
:return: a list in the form
::
{
"a": 1,
}
```
---
## Review
I had to decide on a few short-coming to get to a point where I can merge something. e.g. I stopped to care about changing `see the method create` to `see :meth:create`, or to surround technical terms (e.g. parameters) with a literal (double backtick).
If you wanna change stuff, just get in touch with me and please commit directly on-top of the branch with your changes.
Online rst editor: https://rsted.info.ucl.ac.be/
A script I made: https://gist.github.com/Julien00859/822835b0c75e8bfe0e1c003a32c029d2