Skip to content

Type annotations cause Sphinx warnings #14

Description

@HekkiMelody

Type annotations cause the following warning:

[...]/src/sphinxy/sphinx.py:docstring of sphinxy.sphinx.Sphinx.update_riddle:1: WARNING: more than one target found for cross-reference 'Riddle': sphinxy.Riddle, sphinxy.riddle.Riddle

Apparently this is a several-years-old issue

sphinx-doc/sphinx#4961

that just became more common as type annotations in python started being used more and more:

sphinx-doc/sphinx#4961 (comment)

(Temporary?) solution I found: sphinx-doc/sphinx#4961 (comment)

Adding this line in conf.py

autodoc_default_options = {
    'ignore-module-all': True
}

Unsure about any possible side effects, but worked for me.

Thank you for the workshop! It was very useful and both of you were very helpful and very clear 💜

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions