Skip to content

The _curses.window.get_wch() method is not available in Python 3.13 for macOS universal2 installer #128085

Closed as duplicate of#91132
@atsuoishimoto

Description

@atsuoishimoto

Bug report

Bug description:

With macOS 64-bit universal2 installer for Python 3.13(both 3.13.0 and 3.13.1), following code raises
error AttributeError: '_curses.window' object has no attribute 'get_wch'. Did you mean: 'getch'? .

from curses import wrapper

def main(stdscr):
    c = stdscr.get_wch()

wrapper(main)

However, it can be used on the same box if I build Python from source code myself.

Tested on MacOS Sequoia 15.0:

  • With macOS 64-bit universal2:

     python3.13 -c "import sysconfig; print(sysconfig.get_config_vars('HAVE_NCURSES', 'HAVE_NCURSESW'))"
     [0, 0]
    
  • Built from source:

     ./python.exe -c "import sysconfig; print(sysconfig.get_config_vars('HAVE_NCURSES', 'HAVE_NCURSESW'))"
     [0, 1]
    

CPython versions tested on:

3.13

Operating systems tested on:

macOS

Metadata

Metadata

Assignees

Labels

OS-macextension-modulesC modules in the Modules dirtype-bugAn unexpected behavior, bug, or error

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions