Sage-Bionetworks / synapsePythonClient

Programmatic interface to Synapse services for Python
https://www.synapse.org
Apache License 2.0
67 stars 68 forks source link

[SYNPY-1345] Migrate to mkdocstrings #1023

Closed BryanFauble closed 9 months ago

BryanFauble commented 9 months ago

Problem: Our previous documentation tool through Sphinx was a bit difficult to work with. It relied on RST files. It used sphinx docstrings format as well.

Solution:

  1. Migrated the pages to mkdocstrings and python.
  2. Migrated a small number of RST documents into markdown - More documents still need to be converted over, but those can come when we start to write content. The amount done as of now is to showcase what the documentation looks like in this format.
  3. Moved to google docstrings for object-orientated POC. Tested out what the google docstring looks like in the Synapse class.

Testing:

  1. Make sure that you have the latest dependencies installed. ie: pip install .
  2. In the root synapsePythonClient directory you should see the mkdocs.yml. In this directory you can run mkdocs serve to view the live files.

mkdocs builds is used to create the site directory when we serve these on a live server.

image

image

image

image

image image

image

image

BryanFauble commented 9 months ago

What we will need to do is be diligent about some of the potential broken links to the python client docs from the synapse help docs once we push to master.

Thanks @thomasyu888 . My plan is to make a branch from develop and bring forward the minimum number of changes required to have a 1-to-1 (Or close to) transition from the current python client docs into this format. That way there are less things to review and go wrong. Once we are in the format than we have a great base to start adding all of these additional documents.

pep8speaks commented 9 months ago

Hello @BryanFauble! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

Line 211:89: E501 line too long (99 > 88 characters)

Line 27:89: E501 line too long (92 > 88 characters) Line 30:89: E501 line too long (92 > 88 characters) Line 35:89: E501 line too long (90 > 88 characters) Line 36:89: E501 line too long (97 > 88 characters) Line 42:89: E501 line too long (101 > 88 characters) Line 43:89: E501 line too long (91 > 88 characters) Line 48:89: E501 line too long (103 > 88 characters) Line 50:89: E501 line too long (96 > 88 characters) Line 52:89: E501 line too long (94 > 88 characters) Line 161:89: E501 line too long (110 > 88 characters) Line 221:89: E501 line too long (110 > 88 characters) Line 246:89: E501 line too long (110 > 88 characters)

Line 26:89: E501 line too long (94 > 88 characters) Line 27:89: E501 line too long (93 > 88 characters) Line 31:89: E501 line too long (97 > 88 characters) Line 32:89: E501 line too long (97 > 88 characters) Line 40:89: E501 line too long (96 > 88 characters) Line 42:89: E501 line too long (94 > 88 characters) Line 128:89: E501 line too long (110 > 88 characters) Line 209:89: E501 line too long (110 > 88 characters) Line 270:89: E501 line too long (110 > 88 characters)

Line 24:89: E501 line too long (95 > 88 characters) Line 25:89: E501 line too long (97 > 88 characters) Line 29:89: E501 line too long (94 > 88 characters) Line 30:89: E501 line too long (101 > 88 characters) Line 38:89: E501 line too long (96 > 88 characters) Line 39:89: E501 line too long (95 > 88 characters) Line 40:89: E501 line too long (106 > 88 characters) Line 118:89: E501 line too long (92 > 88 characters) Line 175:89: E501 line too long (110 > 88 characters) Line 251:89: E501 line too long (110 > 88 characters) Line 312:89: E501 line too long (110 > 88 characters)

Line 340:89: E501 line too long (89 > 88 characters) Line 346:89: E501 line too long (90 > 88 characters) Line 347:89: E501 line too long (97 > 88 characters) Line 350:89: E501 line too long (95 > 88 characters) Line 356:89: E501 line too long (98 > 88 characters) Line 359:89: E501 line too long (95 > 88 characters) Line 361:89: E501 line too long (94 > 88 characters) Line 463:89: E501 line too long (110 > 88 characters) Line 489:89: E501 line too long (110 > 88 characters) Line 514:89: E501 line too long (110 > 88 characters) Line 593:89: E501 line too long (110 > 88 characters) Line 617:89: E501 line too long (110 > 88 characters) Line 644:89: E501 line too long (110 > 88 characters)