Skip to content

Fix module docstring format for ismags reference article.#6611

Merged
dschult merged 1 commit intonetworkx:mainfrom
rossbar:doc/hotfix-ismags-page-layout
Apr 3, 2023
Merged

Fix module docstring format for ismags reference article.#6611
dschult merged 1 commit intonetworkx:mainfrom
rossbar:doc/hotfix-ismags-page-layout

Conversation

@rossbar
Copy link
Copy Markdown
Contributor

@rossbar rossbar commented Apr 3, 2023

Closes #6547

Improperly formatted Notes/References sections was causing a sphinx parsing error which led to a very poorly formatted html page.

Fixing the numpydoc formatting for the module docstring + minor munging of the heading levels should fix the issue.

Improperly formatted Notes/References sections was causing a sphinx
parsing error which led to a very poorly formatted html page.

Fixing the numpydoc formatting for the module docstring + minor
munging of the heading levels was sufficient to fix this.
@dschult
Copy link
Copy Markdown
Member

dschult commented Apr 3, 2023

This looks fine for content -- but the ISMAGS Object section has no space before it (the References section runs right up to it, while the other sections get some breathing room). I don't mind merging this as is, but is there an easy way to make the space between sections? (maybe just a blank line at end of doc_string? but maybe different autodoc magic in the .rst file?)

@rossbar
Copy link
Copy Markdown
Contributor Author

rossbar commented Apr 3, 2023

the ISMAGS Object section has no space before it (the References section runs right up to it, while the other sections get some breathing room).

Good point - I'm not sure why this happens. I'll try adding some newlines (in isomorphism.ismags.rst and/or the ismags module docstring) to see if I can't get an extra line break in there. There's still likely something funky with the numpydoc module docstring parsing so it may not be possible, but let's check!

@rossbar
Copy link
Copy Markdown
Contributor Author

rossbar commented Apr 3, 2023

Okay, I've tried with adding extra newlines in both the reference doc as well as the module docstring and unfortunately that doesn't make any difference. I suspect this is something that will have to be fixed upstream.

Copy link
Copy Markdown
Member

@dschult dschult left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for trying out the newlines -- I didn't know if there was something about sphinx I didn't know about.

Let's merge these and we can fix minor stuff later.

@dschult dschult merged commit 020eaf6 into networkx:main Apr 3, 2023
@jarrodmillman jarrodmillman added this to the networkx-3.1 milestone Apr 3, 2023
Alex-Markham pushed a commit to Alex-Markham/networkx that referenced this pull request Oct 13, 2023
)

Improperly formatted Notes/References sections was causing a sphinx
parsing error which led to a very poorly formatted html page.

Fixing the numpydoc formatting for the module docstring + minor
munging of the heading levels was sufficient to fix this.
dschult pushed a commit to BrunoBaldissera/networkx that referenced this pull request Oct 23, 2023
)

Improperly formatted Notes/References sections was causing a sphinx
parsing error which led to a very poorly formatted html page.

Fixing the numpydoc formatting for the module docstring + minor
munging of the heading levels was sufficient to fix this.
cvanelteren pushed a commit to cvanelteren/networkx that referenced this pull request Apr 22, 2024
)

Improperly formatted Notes/References sections was causing a sphinx
parsing error which led to a very poorly formatted html page.

Fixing the numpydoc formatting for the module docstring + minor
munging of the heading levels was sufficient to fix this.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

Layout of website page for ISMAGS needs fixing

3 participants