Further py3 fix in tools/docs
Change: 146325723
This commit is contained in:
parent
9211ee0388
commit
416887f8ac
tensorflow/tools/docs
@ -22,6 +22,7 @@ import argparse
|
||||
import inspect
|
||||
import os
|
||||
|
||||
import six
|
||||
import tensorflow as tf
|
||||
|
||||
from tensorflow.tools.common import public_api
|
||||
@ -65,7 +66,7 @@ def write_docs(output_dir, base_dir, duplicate_of, duplicates, index, tree):
|
||||
raise
|
||||
|
||||
# Parse and write Markdown pages, resolving cross-links (@{symbol}).
|
||||
for full_name, py_object in index.iteritems():
|
||||
for full_name, py_object in six.iteritems(index):
|
||||
|
||||
if full_name in duplicate_of:
|
||||
print('Not writing docs for %s, duplicate of %s.' % (
|
||||
|
@ -23,6 +23,7 @@ import inspect
|
||||
import os
|
||||
import re
|
||||
|
||||
import six
|
||||
|
||||
# A regular expression capturing a python indentifier.
|
||||
IDENTIFIER_RE = '[a-zA-Z_][a-zA-Z0-9_]*'
|
||||
@ -616,7 +617,7 @@ def generate_global_index(library_name, root_name, index, duplicate_of):
|
||||
A string containing an index page as Markdown.
|
||||
"""
|
||||
symbol_links = []
|
||||
for full_name, py_object in index.iteritems():
|
||||
for full_name, py_object in six.iteritems(index):
|
||||
index_name = full_name or root_name
|
||||
if (inspect.ismodule(py_object) or inspect.isfunction(py_object) or
|
||||
inspect.isclass(py_object)):
|
||||
|
Loading…
Reference in New Issue
Block a user