<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[[8.6.2] Display live console to work with Python script?]]></title><description><![CDATA[<p dir="auto">Hello,</p>
<p dir="auto">I’d like to find how to get NppExec to display the output from a Python script in a console within NPP so I don’t need to switch back and forth to Windows’ cmd window.</p>
<p dir="auto">Thank you.</p>
<p dir="auto"><img src="/assets/uploads/files/1714190173443-aeae22a0-b20c-4ddc-8a55-d7b9a30fc8dd-image.png" alt="aeae22a0-b20c-4ddc-8a55-d7b9a30fc8dd-image.png" class=" img-fluid img-markdown" /></p>
]]></description><link>https://community.notepad-plus-plus.org/topic/25722/8-6-2-display-live-console-to-work-with-python-script</link><generator>RSS for Node</generator><lastBuildDate>Wed, 17 Jun 2026 06:50:31 GMT</lastBuildDate><atom:link href="https://community.notepad-plus-plus.org/topic/25722.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 27 Apr 2024 03:56:19 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to [8.6.2] Display live console to work with Python script? on Mon, 29 Apr 2024 06:09:13 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/ekopalypse" aria-label="Profile: Ekopalypse">@<bdi>Ekopalypse</bdi></a> said in <a href="/post/94522">[8.6.2] Display live console to work with Python script?</a>:</p>
<blockquote>
<p dir="auto">then you can use quit() as long as you understand what it does.</p>
</blockquote>
<p dir="auto">Correction: this should actually read:</p>
<p dir="auto">then you can use <code>exit()</code> as long as you understand what it does.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/94541</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/94541</guid><dc:creator><![CDATA[Ekopalypse]]></dc:creator><pubDate>Mon, 29 Apr 2024 06:09:13 GMT</pubDate></item><item><title><![CDATA[Reply to [8.6.2] Display live console to work with Python script? on Sat, 27 Apr 2024 17:57:14 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/shohreh" aria-label="Profile: Shohreh">@<bdi>Shohreh</bdi></a></p>
<p dir="auto">but now you have changed the way in which the Python script is executed. In the previous example you executed python directly, now you start a cmd that executes the python script itself.<br />
As said before, if you want to switch to interactive mode, use os._exit(1) for example, if not, then you can use quit() as long as you understand what it does.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/94522</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/94522</guid><dc:creator><![CDATA[Ekopalypse]]></dc:creator><pubDate>Sat, 27 Apr 2024 17:57:14 GMT</pubDate></item><item><title><![CDATA[Reply to [8.6.2] Display live console to work with Python script? on Sat, 27 Apr 2024 17:11:24 GMT]]></title><description><![CDATA[<p dir="auto">I also tried quit(), still no output — Can’t post as text since the forum assumes it’s a link.</p>
<p dir="auto">The code works fine when ran from a cmd window.</p>
<p dir="auto">Too bad.</p>
<p dir="auto"><img src="/assets/uploads/files/1714237867049-82912603-df7e-4909-83b4-855116c39080-image.png" alt="82912603-df7e-4909-83b4-855116c39080-image.png" class=" img-fluid img-markdown" /></p>
]]></description><link>https://community.notepad-plus-plus.org/post/94520</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/94520</guid><dc:creator><![CDATA[Shohreh]]></dc:creator><pubDate>Sat, 27 Apr 2024 17:11:24 GMT</pubDate></item><item><title><![CDATA[Reply to [8.6.2] Display live console to work with Python script? on Sat, 27 Apr 2024 14:33:47 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/shohreh" aria-label="Profile: Shohreh">@<bdi>Shohreh</bdi></a></p>
<p dir="auto">Read about what <a href="https://docs.python.org/3/library/sys.html#sys.exit" rel="nofollow ugc">sys.exit</a> does.<br />
If interactive mode is required, then use os._exit(WHATEVER_NUMBER) instead.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/94515</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/94515</guid><dc:creator><![CDATA[Ekopalypse]]></dc:creator><pubDate>Sat, 27 Apr 2024 14:33:47 GMT</pubDate></item><item><title><![CDATA[Reply to [8.6.2] Display live console to work with Python script? on Sun, 28 Apr 2024 13:57:58 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/shohreh" aria-label="Profile: Shohreh">@<bdi>Shohreh</bdi></a> said in <a href="/post/94507">[8.6.2] Display live console to work with Python script?</a>:</p>
<blockquote>
<p dir="auto">Hello,</p>
<p dir="auto">I’d like to find how to get NppExec to display the output from a Python script in a console within NPP so I don’t need to switch back and forth to Windows’ cmd window.</p>
</blockquote>
<p dir="auto">Then congratulations, you have succeeded.  The screenshot you included showed it is indeed putting the output into the Book exec console in Notepad++.</p>
<p dir="auto"><s>Unfortunately, your Python has an error,</s> so the error is the only output that you see.  Try a simple Hello World to see it “work”</p>
<p dir="auto">–<br />
<em>update</em>: sorry, that’s showing my obvious lack of knowledge about <code>exit</code> in Python; see more knowledgeable posts below</p>
]]></description><link>https://community.notepad-plus-plus.org/post/94514</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/94514</guid><dc:creator><![CDATA[PeterJones]]></dc:creator><pubDate>Sun, 28 Apr 2024 13:57:58 GMT</pubDate></item></channel></rss>