Message 381599 - Python tracker
> (1) add a .dedent() method to str (and bytes?) - behaviors to consider mirroring are textwrap.dedent() and inspect.cleandoc(). Given their utility and similarities, it makes sense to offer both behaviors; behavior could be selected by a kwarg passed to the method. I don't think we need two algorithms here. I'm +1 to add str.dedent() which mirroring only inspect.cleandoc().