python - How should I group similar exceptions in a docstring? -


i don't see mentioned in style guide. should combine similar exception types or split them separate lines:

""" google style docs. ... ... raises:     typeerror: foo() missing 1 required positional argument. key must numeric value.     keyerror: bar """ 

or this:

""" google style docs. ... ... raises:     typeerror: foo() missing 1 required positional argument     typeerror: key must numeric value     keyerror: bar """ 

i think go second.

""" google style docs. ... ... raises:     typeerror: 1. foo() missing 1 required positional argument.                2. key must numeric value.                3. ...     keyerror:  1. bar key missing.                2. ... """ 

Comments

Popular posts from this blog

apache - PHP Soap issue while content length is larger -

asynchronous - Python asyncio task got bad yield -

javascript - Complete OpenIDConnect auth when requesting via Ajax -