New GitHub issue #99735 from ppaez:<br>
<hr>
<pre>
# Documentation
The example that shows the use of sub-commands and set_defaults to dispatch a function for each sub-command, fails when the are no command line arguments:
`AttributeError: 'Namespace' object has no attribute 'func'`
A pull request is provided that adds one line to handle that case and an explanation in the documentation.
</pre>
<hr>
<a href="https://github.com/python/cpython/issues/99735">View on GitHub</a>
<p>Labels: docs</p>
<p>Assignee: </p>