On 10/18/20, Mike Miller <[email protected]> wrote:
>
> Also, a shell is not a terminal, so terminal routines don't feel right in
> shutil.  Putting get_terminal_size() there was a mistake imho.

The shutil module "offers a number of high-level operations on files".
ISTM that shutil.get_terminal_size is a high-level operation on
sys.__stdout__, if it's a terminal/console device file, though it's an
odd duck since the rest of the module is dealing with filesystem
files. That said, rightly or wrongly, I think of shutil as a
collection of shell utility (SHell UTILity) functions for Python's
standard library, so I'm comfortable with expanding its mandate to
functions commonly supported by CLI shell environments, such as
terminal/console management.
_______________________________________________
Python-ideas mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/[email protected]/message/237RUHNA6IFRXPBBWHH3QHIEUNO77MRG/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to