FRRouting / frr

The FRRouting Protocol Suite

Home Page:https://frrouting.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

make doc/developer ocurs module 'sphinx.addnodes' has no attribute 'desc_sig_operator'.

nanfengnan1 opened this issue · comments

Description

make doc generate python module sphinx lacks of 'desc_sig_operator' attribue.

Version

frr10
python3.8.10

How to reproduce

cd doc/developer && make;

Expected behavior

make ok

Actual behavior

root@localhost:/opt/code/FRR/doc/developer# make
SPHINX doc/developer/_build/.doctrees/environment.pickle
/opt/code/FRR/doc/developer/cspf.rst:84: WARNING: Unknown directive type "c:struct".

.. c:struct:: constraints
/opt/code/FRR/doc/developer/cspf.rst:100: WARNING: Unknown directive type "c:struct".

.. c:struct:: c_path
/opt/code/FRR/doc/developer/cspf.rst:109: WARNING: Unknown directive type "c:struct".

.. c:struct:: cspf
/opt/code/FRR/doc/developer/link-state.rst:56: WARNING: Unknown directive type "c:struct".

.. c:struct:: ls_node

that groups all information related to a node
/opt/code/FRR/doc/developer/link-state.rst:60: WARNING: Unknown directive type "c:struct".

.. c:struct:: ls_attributes

that groups all information related to a link
/opt/code/FRR/doc/developer/link-state.rst:64: WARNING: Unknown directive type "c:struct".

.. c:struct:: ls_prefix

that groups all information related to a prefix
/opt/code/FRR/doc/developer/link-state.rst:76: WARNING: Unknown directive type "c:struct".

.. c:struct:: ls_node_id

defines the Node identifier as router ID IPv4 address plus the area ID for
OSPF or the ISO System ID plus the IS-IS level for IS-IS.
/opt/code/FRR/doc/developer/link-state.rst:162: WARNING: Unknown directive type "c:struct".

.. c:struct:: ls_vertex
/opt/code/FRR/doc/developer/link-state.rst:163: WARNING: Unknown directive type "c:struct".

.. c:struct:: ls_edge
/opt/code/FRR/doc/developer/link-state.rst:164: WARNING: Unknown directive type "c:struct".

.. c:struct:: ls_ted

  • :c:struct:ls_prefix
    /opt/code/FRR/doc/developer/link-state.rst:416: WARNING: Unknown directive type "c:struct".

.. c:struct:: ls_message

Exception occurred:
File "/opt/code/FRR/doc/developer/conf.py", line 374, in parse_frrfmt
node += addnodes.desc_sig_operator('%', '%')
AttributeError: module 'sphinx.addnodes' has no attribute 'desc_sig_operator'
The full traceback has been saved in /tmp/sphinx-err-08fv1sq_.log, if you want to report the issue to the developers.
Please also report this if it was a user error, so that a better error message can be provided next time.
A bug report can be filed in the tracker at https://github.com/sphinx-doc/sphinx/issues. Thanks!
make[1]: *** [Makefile:18170: doc/developer/_build/.doctrees/environment.pickle] Error 2
make: *** [Makefile:2: all] Error 2
root@localhost:/opt/code/FRR/doc/developer# cd ..^C
root@localhost:/opt/code/FRR/doc/developer# python3
Python 3.8.10 (default, Nov 22 2023, 10:22:35)
[GCC 9.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.

import sphinx.addnodes

if hasattr(sphinx.addnodes, 'desc_sig_operator'):
... print("sphinx.addnodes 模块具有 desc_sig_operator 属性。")
... else:
... print("sphinx.addnodes 模块没有 desc_sig_operator 属性。")
...
sphinx.addnodes 模块没有 desc_sig_operator 属性。

Additional context

i think it should sphinx version is not matched, i use python3.8.10.
in fact, python3.8.10 don't have 'desc_sig_operator' attribue.
test program as:
root@localhost:/opt/code/FRR/doc/developer# python3
Python 3.8.10 (default, Nov 22 2023, 10:22:35)
[GCC 9.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.

import sphinx.addnodes

if hasattr(sphinx.addnodes, 'desc_sig_operator'):
... print("sphinx.addnodes 模块具有 desc_sig_operator 属性。")
... else:
... print("sphinx.addnodes 模块没有 desc_sig_operator 属性。")
...
sphinx.addnodes 模块没有 desc_sig_operator 属性

Checklist

  • I have searched the open issues for this bug.
  • I have not included sensitive information in this report.

root@localhost:/opt/code/FRR# pip show sphinx
Name: Sphinx
Version: 1.8.5
Summary: Python documentation generator
Home-page: http://sphinx-doc.org/
Author: Georg Brandl
Author-email: georg@python.org
License: BSD
Location: /usr/lib/python3/dist-packages
Requires:
Required-by:

i have resolved.
python3 -m pip install --upgrade pip3
python3 -m pip cache purge
python3 -m pip install --force-reinstall Sphinx
python3 -m pip install protobuf