python interpreter citing zen of python in the terminal window

Viewed 1112

I run vscode version 1.65.2. Today it started citing the whole "The Zen of Python" in the terminal window every time I run a python script in the debugger.

EDIT: It turns out that it is the python interpreter that does it, not vscode. The problem apparently came after I updated ipykernel to version 6.11.0. I run python version 3.9.1 on Windows.

How can I turn it off?

I havent been able to find an answer to this anywhere.

2 Answers

It turned out that an import statement had found its way into my code: "import this as d", and removing it solved the problem. It is a mystery how it ended up there, I certainly haven't put it there knowingly. But problem solved!

That's really odd. I just had the exact same thing. Even the import this as d was on the first line before everything. I use vscode as well. Removing it does help. But I didn't update a kernel prior to this. It happened while I was writing code I think. Python 3.8.10 on Linux.

Related