# PEP 822: Dedented Multiline String (d-string)

**URL:** <https://discuss.python.org/t/pep-822-dedented-multiline-string-d-string/105519>\
**Category:** PEPs\
**Created:** [January 5, 2026, 11:18am UTC](https://discuss.python.org/t/pep-822-dedented-multiline-string-d-string/105519 "2026-01-05T11:18:19Z")\
**Posts on this page:** 1\
**Showing post:** 49

<div class="post-metadata">

**Author:** ![methane](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/methane/32/43_2.png) [@methane](https://discuss.python.org/u/methane)\
**Post date:** [January 16, 2026, 3:56am UTC](https://discuss.python.org/t/pep-822-dedented-multiline-string-d-string/105519/49 "2026-01-16T03:56:59Z")

</div>

> [@h-vetinari](#):
>
> In contrast to the bug you describe (which only affects people that require to remove the initial newline), this will hit a far larger set of users – anyone doing concatenation of multi-line strings – who simply “forgot” (due to irregularity of the feature) to insert an extra newline when converting something to a d-string.

In past threads, we also considered the idea of using `from __future__ import dedent_string_literals` instead of the d-prefix.  
So if `future import` had been chosen there, I would have designed the rules to prioritize maximum compatibility with all multiline string literals.

However, people chose the d-prefix over future import. We do not need to replace all `"""..."""` with d-strings. I designed the rules with priority given to usability in contexts such as `textwrap.dedent("""...""")`.

Therefore, I prioritized eliminating the inconvenience that a `\` is almost always required immediately after `textwrap.dedent("""`, over the inconvenience of needing to add a newline when rewriting `"""` as `d"""`.

When making technical decisions, many objective facts are taken into consideration, but the final choice of priorities is always subjective. My subjective judgment may not align with yours; however, since I am the author of this PEP, it is ultimately written based on my own subjective decisions.

The presentation of new facts that support your position is welcome, but let us refrain from continuing subjective and abstract discussions about whether the initial newline should be preserved or removed.

---

_[View the full topic](https://discuss.python.org/t/pep-822-dedented-multiline-string-d-string/105519)._
