diff options
author | Karthikeyan Singaravelan <tir.karthi@gmail.com> | 2020-08-03 22:12:03 +0530 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-03 16:42:03 +0000 |
commit | 0f60eda81ea524dcd1358d87b06da701412bb414 (patch) | |
tree | c47338bb8ce3518f483459b9707bdb848bd2db40 | |
parent | cd4e8f429422232dd82ef7e9bc685061d5df94a1 (diff) | |
download | google-api-python-client-0f60eda81ea524dcd1358d87b06da701412bb414.tar.gz |
docs: fix deprecation warnings due to invalid escape sequences. (#996)
Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
- [x] Make sure to open an issue as a [bug/issue](https://github.com/googleapis/google-api-python-client/issues/new/choose) before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea
- [ ] Ensure the tests and linter pass
- [ ] Code coverage does not decrease (if any source code was changed)
- [ ] Appropriate docs were updated (if necessary)
Fixes #995 🦕
-rwxr-xr-x | describe.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/describe.py b/describe.py index f60d72dc6..107fa9d59 100755 --- a/describe.py +++ b/describe.py @@ -226,7 +226,7 @@ def method_params(doc): parameters.append(pname) for line in args: - m = re.search("^\s+([a-zA-Z0-9_]+): (.*)", line) + m = re.search(r"^\s+([a-zA-Z0-9_]+): (.*)", line) if m is None: desc += line continue @@ -284,7 +284,7 @@ def breadcrumbs(path, root_discovery): display = p if i == 0: display = root_discovery.get("title", display) - crumbs.append('<a href="%s.html">%s</a>' % (prefix + p, display)) + crumbs.append('<a href="{}.html">{}</a>'.format(prefix + p, display)) accumulated.append(p) return " . ".join(crumbs) @@ -407,7 +407,7 @@ def document_api(name, version, uri): version = safe_version(version) document_collection_recursive( - service, "%s_%s." % (name, version), discovery, discovery + service, "{}_{}.".format(name, version), discovery, discovery ) @@ -427,7 +427,7 @@ def document_api_from_discovery_document(uri): version = safe_version(discovery["version"]) document_collection_recursive( - service, "%s_%s." % (name, version), discovery, discovery + service, "{}_{}.".format(name, version), discovery, discovery ) |