March 6-12, 2022 in Darker: Addressing Monorepo Configurations and Docstring Formatting #677
akaihola
announced in
Announcements
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
This week, we focused on addressing configuration issues for monorepo layouts and improving docstring formatting. We closed an important issue (#244) related to the project's configuration in monorepo structures. The change in how Darker handles the
--config
argument was causing problems for users with complex repository layouts. We're now exploring options to revert this change or provide a way to configure the path to the Darker config file, which will be addressed in the upcoming 1.5.0 release.In response to user feedback, we merged a pull request (#300) to improve the handling of multi-line docstrings. This change aims to prevent "reformat loops" where docstrings are repeatedly indented and unindented. The implementation involves using AST parsing to identify multi-line strings and treating them as complete chunks during formatting. This fix addresses a long-standing issue (#240) where Darker would continuously indent docstrings on each call.
We also acknowledged the importance of transparency regarding potential drawbacks of partial formatting tools like Darker. In response to a closed issue (#294), we're considering adding a reference to Łukasz Langa's blog post about the rationale behind Black's full codebase formatting approach in our README. This addition will provide users with a more comprehensive understanding of the trade-offs involved in choosing Darker for their projects.
Beta Was this translation helpful? Give feedback.
All reactions