_
is just a variable like any other, however there are a few (contradictory) conventions for a variable called _
. The one you see here is when you need to assign a result to a value that is not subsequently used: the retrieve
method is returning two values and the programmer is only interested in the second one.
_
is also used in the interactive shell to store the result of the last expression.
_
is also used in some code as the name of a function that will translate a string, so _("some string")
will lookup the string in a language specific table and return the appropriate translation or the original string if no translation is available.