New submission from Ned Deily <n...@acm.org>:

wrong error from curses.wrapper if curses initialization fails

One way to reproduce is trying under IDLE.app in OS X:

  import curses
  def scr(a):
    a.getch()

  curses.wrapper(scr)

Traceback before patch:
  UnboundLocalError: local variable 'stdscr' referenced before 
assignment

Traceback after patch:
  _curses.error: setupterm: could not find terminal

APPLIES         2.6, 2.7, 3.0, 3.1

----------
components: Library (Lib)
files: patch-nad0018.txt
messages: 84793
nosy: nad
severity: normal
status: open
title: wrong error from curses.wrapper if curses initialization fails
versions: Python 2.6, Python 2.7, Python 3.0, Python 3.1
Added file: http://bugs.python.org/file13512/patch-nad0018.txt

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

Reply via email to