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

"duplicate object description" warning for classes/functions defined in __init__.py. #54

Open
Viech opened this issue Nov 7, 2018 · 0 comments

Comments

@Viech
Copy link

Viech commented Nov 7, 2018

Hello,

I have an __init__.py file that defines an exception and a number of functions. I want to document it as follows (from /…/src/picos/doc/api/solvers.rst):

.. automodapi:: picos.solvers
  :no-heading:
  :headings: =-

The documentation generates fine, but I get the following warnings

/…/src/picos/picos/solvers/__init__.py:docstring of picos.solvers.NoAppropriateSolverError:1: WARNING: duplicate object description of picos.solvers.NoAppropriateSolverError, other instance in /…/src/picos/doc/api/solvers.rst, use :noindex: for one of them
/…/src/picos/picos/solvers/__init__.py:docstring of picos.solvers.all_solvers:1: WARNING: duplicate object description of picos.solvers.all_solvers, other instance in /…/src/picos/doc/api/solvers.rst, use :noindex: for one of them
/…/src/picos/picos/solvers/__init__.py:docstring of picos.solvers.available_solvers:1: WARNING: duplicate object description of picos.solvers.available_solvers, other instance in /…/src/picos/doc/api/solvers.rst, use :noindex: for one of them
/…/src/picos/picos/solvers/__init__.py:docstring of picos.solvers.get_solver:1: WARNING: duplicate object description of picos.solvers.get_solver, other instance in /…/src/picos/doc/api/solvers.rst, use :noindex: for one of them
/…/src/picos/picos/solvers/__init__.py:docstring of picos.solvers.potential_solvers:1: WARNING: duplicate object description of picos.solvers.potential_solvers, other instance in /…/src/picos/doc/api/solvers.rst, use :noindex: for one of them
/…/src/picos/picos/solvers/__init__.py:docstring of picos.solvers.suggested_solver:1: WARNING: duplicate object description of picos.solvers.suggested_solver, other instance in /…/src/picos/doc/api/solvers.rst, use :noindex: for one of them

I verified that these are the only definitions of the exception and the functions in question.

I don't know how to get rid of the warnings and I suspect that this is an issue with automodapi.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant