-
Notifications
You must be signed in to change notification settings - Fork 76
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bugs in link handling in 1.5.1 #140
Comments
Can confirm the issue, both with Trace of my CI for reference: https://github.com/kdeldycke/click-extra/actions/runs/3786046355/jobs/6436595023#step:8:43 |
For the first problem (IndexError), docformatter shouldn't even be preserving links unless the wrapping broke it across multiple lines. PR #141 now causes docformatter to skip link preservation in any wrapped text that results in no wrapped lines. For the second problem, rebuilding the link should've resulted in the following:
Note that it added a blank line after the Thanks @drasmuss and @kdeldycke for your inputs and sorry for any headaches. |
Thanks @weibullguy for being so fast fixing this issue! I'm relying on |
@weibullguy in case this is of any help, 1.5.1 trips over a particular URL:
is reformatted fine. However
is losing data during the reformat operation, the output:
Not sure if this case is handled by #141 as the URL is not in RST style, so thought worth posting for you (and perhaps others). |
A different, but related case with the URL:
1.5.1 trips over with the traceback (with no configuration at all, i.e. all defaults):
|
@drasmuss, @kdeldycke, and @AlexTereshenkov I got ahead of myself releasing 1.5.0 to PyPi without sufficient testing. Before I cause users anymore headaches, I'm providing release candidates for the brave to use and provide feedback. If you'd like to use the next release candidate that should resolve your issue, you can install it with pip:
|
I've run into a couple issues related to formatting links in 1.5.1.
To reproduce, create a file
tmp.py
containing:Running
docformatter tmp.py
gives an errorRunning
docformatter tmp.py
produces the outputNote that the space has been removed between "more" and "details".
The text was updated successfully, but these errors were encountered: