How to remove the cause of an unexpected indentation warning when generating code documentation?

Just add a blank line after the summary description of the method, before the description of the parameters:

"""
Gtk.EventBox::button-release-event signal handler.

:param widget: The clicked widget (The Gtk.EventBox).
:param event: Gdk.EventButton object with information regarding
       the event.
:param user_data: The Gtk.LinkButton that should be opened when
       the Gtk.EventBox is clicked.
:return: None
"""

Here you can find this advice:

If you get a Sphinx build error that says “Unexpected indentation,” it is probably because Sphinx is expecting a blank line, such as after a literal text block. Your line may have wrapped and confused Sphinx. In this case, try pulling the text up to the previous line even if it extends out past the margin of your window. Or, you could press Enter to go to the next line, but be sure to indent the text on the new line.


Maybe this will help somebody who stumbles upon this question - in my case I was getting a bunch of warnings that were because I was using Google style docstrings. Just add "sphinx.ext.napoleon" to the extensions list in conf.py and the warnings should go away.