-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Closed
Labels
type: cleanupAn internal cleanup or hygiene concern.An internal cleanup or hygiene concern.
Description
See review feedback from PR #2443 where FLAGS shouldn't be referenced directly in functions.
See the code below, specifically line 410 where we have FLAGS.discovery_uri_template
google-api-python-client/describe.py
Lines 392 to 412 in 0cb7266
| def document_api( | |
| name, version, uri, doc_destination_dir, artifact_destination_dir=DISCOVERY_DOC_DIR | |
| ): | |
| """Document the given API. | |
| Args: | |
| name (str): Name of the API. | |
| version (str): Version of the API. | |
| uri (str): URI of the API's discovery document | |
| doc_destination_dir (str): relative path where the reference | |
| documentation should be saved. | |
| artifact_destination_dir (str): relative path where the discovery | |
| artifacts should be saved. | |
| """ | |
| http = build_http() | |
| resp, content = http.request( | |
| uri | |
| or uritemplate.expand( | |
| FLAGS.discovery_uri_template, {"api": name, "apiVersion": version} | |
| ) | |
| ) |
Metadata
Metadata
Assignees
Labels
type: cleanupAn internal cleanup or hygiene concern.An internal cleanup or hygiene concern.