[issue13720] argparse print_help() fails if COLUMNS is set to a low value

2014-02-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you Zbyszek and Steven for your report and patch, but this was fixed in issue13107. -- nosy: +serhiy.storchaka resolution: -> duplicate stage: -> committed/rejected status: open -> closed superseder: -> Text width in optparse.py can become ne

[issue13720] argparse print_help() fails if COLUMNS is set to a low value

2012-07-22 Thread Steven Bethard
Steven Bethard added the comment: Definitely a bug here. Attached is a patch and a test, based on Russell Sim's suggestion, that should fix it. -- keywords: +patch versions: +Python 3.4 Added file: http://bugs.python.org/file26486/13720.patch ___ Py

[issue13720] argparse print_help() fails if COLUMNS is set to a low value

2012-07-21 Thread Russell Sim
Russell Sim added the comment: Hi, I am having the same problem while running ipython in a batch mode emacs. Apparently you can't even start ipython if the columns are less than 27, since they use the argparse library for the magic method help printing and they preformat the strings at impo

[issue13720] argparse print_help() fails if COLUMNS is set to a low value

2012-01-07 Thread Terry J. Reedy
Terry J. Reedy added the comment: Now I get error, even with Window actually about 100 columns wide. -- ___ Python tracker ___ ___ Py

[issue13720] argparse print_help() fails if COLUMNS is set to a low value

2012-01-07 Thread Zbyszek Szmek
Zbyszek Szmek added the comment: > I am not setting columns, so that might be the important difference. Yeah, the whole example with IDLE is moot: argparse only checks $COLUMNS and defaults to 80, so if COLUMNS is not set, you are only checking if the code works with 80 columns. Please try my c

[issue13720] argparse print_help() fails if COLUMNS is set to a low value

2012-01-07 Thread Terry J. Reedy
Terry J. Reedy added the comment: I am not setting columns, so that might be the important difference. -- ___ Python tracker ___ ___

[issue13720] argparse print_help() fails if COLUMNS is set to a low value

2012-01-07 Thread Zbyszek Szmek
Zbyszek Szmek added the comment: > What system and version are you running? Linux (debian amd64), Python is compiled from hg (1ea8b7233fd7). > The error directly comes from textwrap. In the other hand, > textwrap.wrap works with widths down to 1 (on 3.2.2), which suggests > that argparse is

[issue13720] argparse print_help() fails if COLUMNS is set to a low value

2012-01-06 Thread Terry J. Reedy
Terry J. Reedy added the comment: The code works fine on 3.2.2, Win7, IDLE, narrowest window possible (about 14 chars), which actually wraps to the window width. (In command window, lines are fixed length and scroll bar is added if window is narrowed.) What system and version are you running?

[issue13720] argparse print_help() fails if COLUMNS is set to a low value

2012-01-06 Thread Zbyszek Szmek
New submission from Zbyszek Szmek : % cat test_argparse_narrow.py import argparse argparse.ArgumentParser().print_help() % COLUMNS=15 ./python test_argparse_narrow.py Traceback (most recent call last): File "test_argparse_narrow.py", line 2, in argparse.ArgumentParser().print_help() Fil