New submission from Terry J. Reedy <tjre...@udel.edu>:

Attribute .context_use_ps1 is False in EditorWindow and Outwin, True in 
PyShell.  It is use to switch code paths in multiple classes.  It is equal to 
isinstance(self/editwin, PyShell) (which requires an import).  It has the same 
truth value as attribute .prompt_last_line, which is '' except in PyShell.  
This more informative attribute was added in #31858 to consolidate all PS1 
handling in PyShell.

A PR for #34055 proposed to remove the setting of .context_use_ps1 and the uses 
with .prompt_last_line.  I will change the title after I submit this.  I am not 
yet sure if this is the change I want to make.

----------
assignee: terry.reedy
components: IDLE
messages: 332700
nosy: cheryl.sabella, terry.reedy
priority: normal
severity: normal
stage: patch review
status: open
title: IDLE: replace use of EditorWindow.context_use_ps1
type: enhancement
versions: Python 3.7, Python 3.8

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

Reply via email to