Kind Regards,

Abdur-Rahmaan Janhangeer
Mauritius


On Fri, Apr 3, 2020 at 3:55 AM Steven D'Aprano <steve@pearwood.info> wrote:
On Thu, Apr 02, 2020 at 07:18:47PM +0400, Abdur-Rahmaan Janhangeer wrote:

> Out of curiosity how did you learn about sys.displayhook?

20+ years of using Python, experimenting at the interpreter, reading the
documentation, blog posts, etc. I have no idea *specifically* where I
learned it.

I didn't remember the name of the hook, but I knew it existed, so I ran
dir(sys) to get a list of objects in the sys module, then tested it to
make sure it did what I thought it did.

Thanks! Learning some internals is always interesting!