odoo/documentation#17080

Created by fw-bot
Merged at 7c1c4839e273e8842db3a273507af75bb9455348

Statuses:

label
odoo-dev:18.0-17.0-make-review-toc-tree-update-511243-fw
head
6aa6eed30426228435edca732f00d9cefd1a245a
merged
1 month ago by Documentation, Niki Brown (nikbr)
odoo/documentation
17.0 #17073
18.0 #17080
saas-18.2 #17081
saas-18.3 #17082
saas-18.4 #17087
19.0 #17088
saas-19.1 #17089
saas-19.2 #17090
saas-19.3
master #17091

[IMP] skip toctree in check_early_line_breaks

Task: https://www.odoo.com/odoo/project/3835/tasks/6065752

Issue:
Make review is showing early line break errors within toctrees:
<img width="875" height="754" alt="image" src="https://github.com/user-attachments/assets/a7e6de4f-19b4-4c18-97aa-b6f3d674538f" />

Solution:
Update check_early_line_breaks function to skip checking for early returns in a toctree.

Testing:
Run make review on a file that has a toctree at the bottom. For example: content/applications/marketing/events.rst

Expected output should be No problems found.

<img width="617" height="108" alt="image" src="https://github.com/user-attachments/assets/89077d78-90a8-4937-ba48-20170de35468" />

Forward-Port-Of: #17073