[New-bugs-announce] [issue32222] pygettext doesn't extract docstrings for functions with type annotated params

Toby Harradine report at bugs.python.org
Tue Dec 5 05:36:15 EST 2017


New submission from Toby Harradine <tobyharradine at gmail.com>:

### Expected Behaviour
When running pygettext with the -D CLI flag, all module, class, method and function docstrings should be extracted and outputted to the .pot file.

### Actual Behaviour
In the case of functions whose parameters have PEP 484 type annotations, their docstrings are not being extracted. I have attached two files, one .py file and its corresponding .pot file, as examples of this behaviour.

----------
components: Demos and Tools
files: test_typehinted_funcs.py
messages: 307652
nosy: Toby Harradine
priority: normal
severity: normal
status: open
title: pygettext doesn't extract docstrings for functions with type annotated params
type: behavior
versions: Python 3.5, Python 3.6
Added file: https://bugs.python.org/file47316/test_typehinted_funcs.py

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue32222>
_______________________________________


More information about the New-bugs-announce mailing list