python / python/cpython

curses: initscr(), newterm(), start_color() and the screen type have no docstrings

Open
#157,546 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

docs topic-curses type-bug
Dominant language
Python
Stars
77.2k
Forks
35.9k
PR merge metrics
PR metrics pending

Description

Bug report

curses.initscr(), curses.newterm() and curses.start_color() are Python wrappers of the C functions (they copy the ACS_*, LINES/COLS and COLORS/COLOR_PAIRS constants into the package), and the wrappers have no docstring, so help(curses.initscr) shows nothing although _curses.initscr is documented. The curses.screen type has no docstring either, unlike window, complexchar and complexstr.

Also, the docstring of _curses.initscr() says "Return a WindowObject", the name of the C struct rather than the Python type.

Linked PRs
  • gh-157547

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the curses.initscr(), curses.newterm(), curses.start_color(), and curses.screen entry points, comparing their help output with the documented _curses.initscr(), window, complexchar, and complexstr types. Done means the wrappers and screen type have useful docstrings and _curses.initscr() names the Python type correctly; check the linked gh-157547 work before starting.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
documentation
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.