Commit a43b791
committed
fix(docs[ext]): Restrict tool label registration to tool sections only
why: _register_tool_labels iterated every section in every document,
registering non-tool headings (e.g. "Inspect", "Act") in the
StandardDomain. This risked label collisions with other extensions.
what:
- Replace fallback to title_node.astext() with continue
- Only register sections whose title starts with a nodes.literal child
(the pattern used by fastmcp-tool directive output)1 parent 6074aba commit a43b791
1 file changed
Lines changed: 5 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
814 | 814 | | |
815 | 815 | | |
816 | 816 | | |
817 | | - | |
818 | | - | |
| 817 | + | |
| 818 | + | |
| 819 | + | |
| 820 | + | |
819 | 821 | | |
820 | 822 | | |
821 | 823 | | |
822 | 824 | | |
823 | 825 | | |
824 | 826 | | |
825 | 827 | | |
826 | | - | |
| 828 | + | |
827 | 829 | | |
828 | 830 | | |
829 | 831 | | |
| |||
0 commit comments