New submission from Robert T McQuaid <r...@fixcas.com>:

This applies to Python 3.8 under Debian-11 Bullseye.

Under curses getch should return the value of curses.KEY_B2
(350 decimal) when pressing the keypad 5.  Instead it
returns 574.

The simple program following the signature block
illustrates the problem.

Robert T McQuaid
558 McMartin Road
Mattawa Ontario P0H 1V0

phone:  705-744-6274
email:  r...@fixcas.com


# Put the following lines in a file bug.py
# Run from a terminal with:  python3 bug.py

import curses as cs
def report(stdscr):
    print('press the keypad 5')
    global result
    result=stdscr.getch()
cs.initscr()
cs.wrapper(report)
print('KEY_B2 (decimal): '+str(cs.KEY_B2))
print('input decimal value: '+str(result))

----------
components: Library (Lib)
messages: 399917
nosy: arbor
priority: normal
severity: normal
status: open
title: curses getch returns wrong value
versions: Python 3.8

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue44956>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to