This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author rmccampbell7
Recipients docs@python, rmccampbell7
Date 2021-04-05.23:37:41
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1617665861.34.0.620299558452.issue43738@roundup.psfhosted.org>
In-reply-to
Content
Until 3.8 the curses window class was not directly available in code, but now it is available as `_curses.window`. This is not explicitly stated in the documentation (although it is consistent with how the method signatures are written). It is useful to have a public name for the type to aid IDE's with explicit type annotations, i.e.

@curses.wrapper
def main(stdscr: curses.window):
    stdscr.addstr(...)

See https://github.com/python/typeshed/pull/5180, which adds this name to type hints in the typeshed project.

This name should be more clearly documented so programmers can annotate the type without worrying that it may change (which will cause a runtime error unless it is quoted).
History
Date User Action Args
2021-04-05 23:37:41rmccampbell7setrecipients: + rmccampbell7, docs@python
2021-04-05 23:37:41rmccampbell7setmessageid: <1617665861.34.0.620299558452.issue43738@roundup.psfhosted.org>
2021-04-05 23:37:41rmccampbell7linkissue43738 messages
2021-04-05 23:37:41rmccampbell7create