Repository navigation
Remove ..._Impl comments generation and add member‑level docstrings under if TYPE_CHECKING. - #966
Merged
Merged
Conversation
When COM type info has a doc comment, the generator now adds it to the created method stub. This helps IDEs show better help text for generated methods and makes the type annotation output easier to understand.
- attach the getter doc comment to generated property objects when available - keep setter-only properties untouched - preserve generated `TYPE_CHECKING` annotations as valid Python - update the related `typeannotator` regression expectations
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #966 +/- ##
==========================================
- Coverage 89.21% 89.20% -0.02%
==========================================
Files 143 142 -1
Lines 13933 13902 -31
==========================================
- Hits 12431 12401 -30
+ Misses 1502 1501 -1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #530
We are removing the
ComInterfaceBodyImplCommentWriterclass.Before, this class made special comments (
class …_Impl) in the generated Python files.Instead of old comment styles, codegenerator writes docstrings directly after definitions inside an
if TYPE_CHECKING:block.They will be on the same line as the definition.
It isn't the standard PEP 257 style, but Python accepts it without errors, and a code formatter can fix the style.