Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some weird exceptions when building #4528

Closed
wqh17101 opened this issue Aug 16, 2018 · 3 comments
Closed

Some weird exceptions when building #4528

wqh17101 opened this issue Aug 16, 2018 · 3 comments
Labels
Support Support question

Comments

@wqh17101
Copy link

Details

Expected Result

A description of what you wanted to happen
Get a doc normally

Actual Result

A description of what actually happened

when build it occurred an error
Running Sphinx v1.7.6
loading translations [en]... done
making output directory...
building [mo]: targets for 0 po files that are out of date
building [readthedocs]: targets for 9 source files that are out of date
updating environment: 9 added, 0 changed, 0 removed
reading sources... [ 11%] index
reading sources... [ 22%] matchzoo
reading sources... [ 33%] matchzoo.engine
Using TensorFlow backend.
/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/importlib/_bootstrap.py:205: RuntimeWarning: compiletime version 3.5 of module 'tensorflow.python.framework.fast_tensor_util' does not match runtime version 3.6
  return f(*args, **kwds)

Traceback (most recent call last):
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/cmdline.py", line 304, in main
    app.build(args.force_all, filenames)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/application.py", line 331, in build
    self.builder.build_update()
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/builders/__init__.py", line 342, in build_update
    'out of date' % len(to_build))
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/builders/__init__.py", line 355, in build
    updated_docnames = set(self.env.update(self.config, self.srcdir, self.doctreedir))
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/environment/__init__.py", line 565, in update
    self._read_serial(docnames, self.app)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/environment/__init__.py", line 584, in _read_serial
    self.read_doc(docname, app)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/environment/__init__.py", line 659, in read_doc
    doctree = read_doc(self.app, self, self.doc2path(docname))
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/io.py", line 302, in read_doc
    pub.publish()
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/core.py", line 217, in publish
    self.settings)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/readers/__init__.py", line 72, in read
    self.parse()
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/readers/__init__.py", line 78, in parse
    self.parser.parse(self.input, document)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/parsers.py", line 85, in parse
    self.statemachine.run(inputstring, document, inliner=self.inliner)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 170, in run
    input_source=document['source'])
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/statemachine.py", line 239, in run
    context, state, transitions)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/statemachine.py", line 460, in check_line
    return method(match, context, next_state)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 2745, in underline
    self.section(title, source, style, lineno - 1, messages)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 326, in section
    self.new_subsection(title, lineno, messages)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 394, in new_subsection
    node=section_node, match_titles=True)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 281, in nested_parse
    node=node, match_titles=match_titles)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 195, in run
    results = StateMachineWS.run(self, input_lines, input_offset)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/statemachine.py", line 239, in run
    context, state, transitions)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/statemachine.py", line 460, in check_line
    return method(match, context, next_state)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 2745, in underline
    self.section(title, source, style, lineno - 1, messages)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 326, in section
    self.new_subsection(title, lineno, messages)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 394, in new_subsection
    node=section_node, match_titles=True)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 281, in nested_parse
    node=node, match_titles=match_titles)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 195, in run
    results = StateMachineWS.run(self, input_lines, input_offset)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/statemachine.py", line 239, in run
    context, state, transitions)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/statemachine.py", line 460, in check_line
    return method(match, context, next_state)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 2318, in explicit_markup
    nodelist, blank_finish = self.explicit_construct(match)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 2330, in explicit_construct
    return method(self, expmatch)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 2073, in directive
    directive_class, match, type_name, option_presets)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/docutils/parsers/rst/states.py", line 2122, in run_directive
    result = directive_instance.run()
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/ext/autodoc/directive.py", line 133, in run
    documenter.generate(more_content=self.content)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/ext/autodoc/__init__.py", line 799, in generate
    self.document_members(all_members)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/ext/autodoc/__init__.py", line 720, in document_members
    check_module=members_check_module and not isattr)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/ext/autodoc/__init__.py", line 1211, in generate
    all_members=all_members)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/ext/autodoc/__init__.py", line 799, in generate
    self.document_members(all_members)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/ext/autodoc/__init__.py", line 1200, in document_members
    ModuleLevelDocumenter.document_members(self, all_members)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/ext/autodoc/__init__.py", line 720, in document_members
    check_module=members_check_module and not isattr)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/ext/autodoc/__init__.py", line 786, in generate
    sig = self.format_signature()
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/ext/autodoc/__init__.py", line 993, in format_signature
    return Documenter.format_signature(self)  # type: ignore
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/ext/autodoc/__init__.py", line 448, in format_signature
    self.object, self.options, args, retann)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/application.py", line 448, in emit_firstresult
    return self.events.emit_firstresult(event, self, *args)
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/events.py", line 84, in emit_firstresult
    for result in self.emit(name, *args):
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/events.py", line 79, in emit
    results.append(callback(*args))
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx_autodoc_typehints.py", line 140, in process_signature
    return formatargspec(obj, *argspec[:-1]), None
  File "/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/site-packages/sphinx/ext/autodoc/inspector.py", line 134, in formatargspec
    if typing and hasattr(function, '__code__') else {})
  File "/home/docs/.pyenv/versions/3.6.2/lib/python3.6/typing.py", line 1552, in get_type_hints
    value = _eval_type(value, globalns, localns)
  File "/home/docs/.pyenv/versions/3.6.2/lib/python3.6/typing.py", line 350, in _eval_type
    return t._eval_type(globalns, localns)
  File "/home/docs/.pyenv/versions/3.6.2/lib/python3.6/typing.py", line 245, in _eval_type
    eval(self.__forward_code__, globalns, localns),
  File "<string>", line 1, in <module>
NameError: name 'BaseGenerator' is not defined

Exception occurred:
  File "<string>", line 1, in <module>
NameError: name 'BaseGenerator' is not defined
The full traceback has been saved in /tmp/sphinx-err-cw12rb1h.log, if you want to report the issue to the developers.
Please also report this if it was a user error, so that a better error message can be provided next time.
A bug report can be filed in the tracker at <https://github.com/sphinx-doc/sphinx/issues>. Thanks!
Command time: 6s Return: 2

I build it locally and got the same exception
sphinx-err-nwwq7ojq.log

@stsewd
Copy link
Member

stsewd commented Aug 16, 2018

I build it locally and got the same exception

If the error happens locally, then this isn't a rtd problem, this issue tracker is for problems related to rtd only.

Anyway, from the first error looks like you need to run your project with python3.5, not 3.6

/home/docs/checkouts/readthedocs.org/user_builds/matchzoo/envs/hotfix-doc/lib/python3.6/importlib/_bootstrap.py:205: RuntimeWarning: compiletime version 3.5 of module 'tensorflow.python.framework.fast_tensor_util' does not match runtime version 3.6

@stsewd stsewd added the Support Support question label Aug 16, 2018
@wqh17101
Copy link
Author

DId you mean that the problem was caused by tensorflow with py3.6?
https://readthedocs.org/projects/matchzoo/builds/7623201/
As you can see the last successful one had the same warning. @stsewd

@stsewd
Copy link
Member

stsewd commented Aug 16, 2018

I didn't know that, looks like there is something wrong in the code

NameError: name 'BaseGenerator' is not defined

Or maybe you are using features that aren't available in python 3.6 or there is a missing dependency. I'll recommend you to first try to fix the problem locally, closing as this isn't a rtd problem.

@stsewd stsewd closed this as completed Aug 16, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Support Support question
Projects
None yet
Development

No branches or pull requests

2 participants