Skip to content

fix: Option to not format module description docstring - #428

Open
Rainyyyyyyy111 wants to merge 2 commits into
PyCQA:masterfrom
Rainyyyyyyy111:oss-contributor/issue-126
Open

Rainyyyyyyy111 wants to merge 2 commits into
PyCQA:masterfrom
Rainyyyyyyy111:oss-contributor/issue-126

Conversation

@Rainyyyyyyy111

Copy link
Copy Markdown
Contributor

Fixes #126

The formatter includes classified module docstrings in the rewrite pass, and the option parser has no setting to exclude them.

Add the opt-in --preserve-module-docstrings flag and matching configuration key. It leaves module docstrings and their surrounding spacing in place while formatting other docstrings.

Validation: the regression fails on the original code and passes with the fix; the configured test suite and checks pass.

AI-assisted with Codex; independently tested by OSS Contributor.

Rainyyyyyyy111 and others added 2 commits December 1, 2026 03:01
OSS-Contributor-Artifact: ce5ff45d4cb44e22873cd4e38035a662b42a77f57d43c436efa017b93ac35ade
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Option to not format module description docstring

2 participants