A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2005-November/058208.html below:

[Python-Dev] str.dedent

[Python-Dev] str.dedent [Python-Dev] str.dedent"Martin v. Löwis" martin at v.loewis.de
Fri Nov 18 23:13:25 CET 2005
Noam Raphael wrote:
> I just wanted to add another use case: long messages. Consider those
> lines from idlelib/run.py:133
> 
>         msg = "IDLE's subprocess can't connect to %s:%d.  This may be due "\
>               "to your personal firewall configuration.  It is safe to "\
>               "allow this internal connection because no data is visible on "\
>               "external ports." % address
>         tkMessageBox.showerror("IDLE Subprocess Error", msg, parent=root)

You are missing an important point here: There are intentionally no line
breaks in this string; it must be a single line, or else showerror will
break it in funny ways. So converting it to a multi-line string would
break it, dedent or not.

Regards,
Martin
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4