You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello,
It seems that the option close-quotes-on-newline is not taken into account with pre-commit when it is declared in the pyproject.toml. For instance, if I have the following files: pyproject.toml
When I run docformatter on the following example, it works as expected:
class CudaStatus:
"""Singleton class that contains informations relative to CUDA in the
- current process."""+ current process.+ """
But the pre-commit pipeline will not fix the issue, unless I had a "--close-quotes-on-newline", in the args section in the pre-commit-config. Any ideas about this ?
I also think that the documentation should specify that this option fixes the pydocstyle D209 rule.
Thanks
The text was updated successfully, but these errors were encountered:
weibullguy
added
P: bug
PEP 257 violation or existing functionality that doesn't work as documented
C: stakeholder
Relates to docformatter stakeholder requested behavior
and removed
fresh
This is a new issue
labels
Mar 21, 2023
@VDuchauffour this is similar to issue #172. In both cases, I see you're using docformatter-1.5.0. Could you try with docformatter-1.6.0 to see if the problem persists? Also, is that the only argument you set in pyproject.toml or is that the only setting that is being ignored?
In all of my pre-commits, docformatter reads pyproject.toml, but the only thing I set is:
@VDuchauffour actually, now that I posted that comment, you probably need to add the additional_dependencies: [tomli] to your .pre-commit-config.yaml file. If that solves your issue, this is a docformatter documentation issue.
weibullguy
added
S: feedback
Open but need feedback from OP to proceed with solution
and removed
P: bug
PEP 257 violation or existing functionality that doesn't work as documented
C: stakeholder
Relates to docformatter stakeholder requested behavior
labels
Apr 4, 2023
Hello @weibullguy, thanks for your answers.
Actually I solved the issue simply by adding as you said additional_dependencies: [tomli] in the .pre-commit-config.yaml file. I guess it was not related to the option itself but rather to the fact that the pre-commit action can't read the pyproject file without this dependency.
Hello,
It seems that the option
close-quotes-on-newline
is not taken into account with pre-commit when it is declared in the pyproject.toml. For instance, if I have the following files:pyproject.toml
and
.pre-commit-config.yaml
When I run
docformatter
on the following example, it works as expected:But the pre-commit pipeline will not fix the issue, unless I had a
"--close-quotes-on-newline",
in the args section in the pre-commit-config. Any ideas about this ?I also think that the documentation should specify that this option fixes the pydocstyle D209 rule.
Thanks
The text was updated successfully, but these errors were encountered: