[issue37102] Automatically dedent docstring constants by default

2019-06-06 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: This is the function I inlined and as far as I can tell, my approach as been similar to the one you linked. I'm still need to fix some issues as doctest was expecting to find the string before dedenting though. -- _

[issue37102] Automatically dedent docstring constants by default

2019-06-06 Thread Inada Naoki
Inada Naoki added the comment: How about do `inspect.cleandoc()` instead of just a dedent? Some method has docstring like this: """First line blah blah blah blah example code here ... """ In such docstring, dedent can not strip indent well. There is existing attempt

[issue37102] Automatically dedent docstring constants by default

2019-05-31 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: Hi, I'm working on a PR. It should be ready in a couple of days. It's more involved than what I thought as to avoid importing inspect during compilation I will probably need to port cleandoc() in C. -- nosy: +remi.lapeyre __

[issue37102] Automatically dedent docstring constants by default

2019-05-31 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- nosy: +pablogsal ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:/

[issue37102] Automatically dedent docstring constants by default

2019-05-31 Thread Matthias Bussonnier
Change by Matthias Bussonnier : -- nosy: +mbussonn ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

[issue37102] Automatically dedent docstring constants by default

2019-05-30 Thread Gregory P. Smith
New submission from Gregory P. Smith : I'm spawning this issue of as a separate feature from https://bugs.python.org/issue36906 (adding string dedent method and an optimization to do it at compile timer on constants). It'd be great if docstrings were given a similar treatment. Right now we c