GeezerVison is showing github.com — Add JSON Documentation · Issue #2352 · googleapis/google-cloud-python
Add JSON Documentation #2352Labels priority: p2Moderately-important priority. Fix may not be included in next release. DescriptionThis issue is for tracking the requirements, issues and solutions in generating JSON for the gcloud-common Angular site.
Known Requirements
- Extracting sphinx code examples and place them in
methods[{examples:[]}].
- Generate table of contents from sphinx toc. (index.rst).
- Class linking should be added. i.e. support :class:
gcloud.datastore._generated.query_pb2.Query, this is partially done through types.json.
- Source code links (base on relative repo path. i.e.
/google/cloud/datastore/client.py#L25).
- "Getting Started" and "Guide" type pages need to be ported.
- Ensure that snippets are pulled in properly from
docs/*_snippets.py.
- Turn on auto
gcloud-common/site deployments.
Discussions
Resources
Activitydhermes commented on Sep 19, 2016 @daspecster Did you mean to use gcloud.datastore._generated.query_pb2.Query as an example? Those generated files don't have any docs. daspecster commented on Sep 19, 2016 ContributorAuthor More actions Actually yes I did.
We would need to do one of two things with a reference to generated code.
- Strip the directive and just not link it anywhere.
- Just link it to that file/line in the repo (which is what I did/tried to do before since I generated JSON for everything under
gcloud/, now google/cloud).
The bigger thing is generating types.json, I just used that one to illustrate this case. dhermes commented on Sep 19, 2016 I am 👎 on linking into the source. Those protoc generated files are not meant for human eyes and are very nasty to look at. daspecster commented on Sep 19, 2016 ContributorAuthor More actions Sorry, I wasn't very clear on that.
Not linking to the source in this case(however that is a required feature for documented modules,classes,methods,params,variables.
I was generating a JSON file for the _generated files as well since I was processing all python files under gcloud at the time. So the JSON representation was there, but not linked in the TOC. So it just means when there's a reference to one of those in a docstring, the :class: directive works as expected. That is, they could click on the class name and get a description of the module/class/method/whatever. dhermes commented on Apr 5, 2017 lukesneeringer commented on Apr 5, 2017 I had no idea this was even a thing. lukesneeringer commented on Aug 8, 2017
MetadataMetadatapriority: p2Moderately-important priority. Fix may not be included in next release. DevelopmentNo branches or pull requestsIssue actions
|