sage.matroids: Modularization fixes#35719
Conversation
|
Would it be possible to filter out all these optional tags from the docs? Its a bit annoying and they don't really add anything. |
That would be very useful for the PDF documentation because in that format, the comments wrap around. For HTML, I want to keep them.
I have aligned these annotations so that only a little bit (
They do add important information for users of the modularized distributions: They can see in the documentation what examples can be run when this or that is installed but other things aren't, so that they can avoid trial and error. Moreover, annotations that refer to libraries, such as Here in the case of |
Sure, documentation will be needed. It will be added in the documentation of |
I don't plan to work on this |
|
Based on https://www.sphinx-doc.org/en/master/usage/configuration.html#confval-trim_doctest_flags and https://github.com/sphinx-doc/sphinx/blob/d3c91f951255c6729a53e38c895ddc0af036b5b9/sphinx/transforms/post_transforms/code.py#L82-L125 this shouldn't be that hard. Maybe from sphinx.ext import doctest as sphinx_doctest
sphinx_doctest.doctestopt_re = re.compile(r'#\s*(doctest|optional):.+$', re.MULTILINE)
trim_doctest_flags = Trueor overwriting |
|
Thanks, I've added this info to: That we are adding these annotations is already documented in https://doc.sagemath.org/html/en/developer/packaging_sage_library.html#preparing-doctests There's nothing that "needs work" here. |
This is happening in #35749 |
|
The test failure in ell_rational_field is unrelated. |
|
Documentation preview for this PR (built with commit 4d507c7) is ready! 🎉 |
|
Thank you! May I set to "positive review"? |
|
Done. |

📚 Description
Fixes for imports and adding
# optional.Also some
# optionalupdates in other modules.📝 Checklist
⌛ Dependencies