-
-
Notifications
You must be signed in to change notification settings - Fork 386
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unify Printer, Logger and Console classes #2124
Conversation
Apologies in advance for this monster :-) |
25a4743
to
dced62d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The important bits in console.py
look good. Since we're delineating the groups of related methods with "hashtag boxes", do you want to add one above textwrap()
for "user input and output formatting"....or something like that :)?
Otherwise, I'm hoping to get through this tomorrow.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few comments while I'm making my way.
…lear simple/advanced i/o sections.
Looks like |
/me grumbles... I thought I ran those tests... |
Dammit... I did... and then didn't stage the change in git. 🤦 |
Following the discussion in #2115 - unifies the
Printer
,Logger
andConsole
classes into a single Console class.This allows a single representation of "interaction with the user", capturing both input and output, which also writes to a log file as required. It also cleans up some odd API usage (such as needing to invoke
input.wait_bar()
, and the__call__
interface on input (it can now be replaced with aninput()
method.This PR builds on #2115 to avoid collisions with that work. You could either review, approve and merge this PR by itself; or review and merge #2115, then rebase, review and merge this one.UPDATE: PR has now been rebased onto main.It is, unfortunately, a very large PR... but most of the changes are renames.
PR Checklist: