Skip to content

Commit

Permalink
Set default value to False
Browse files Browse the repository at this point in the history
  • Loading branch information
jsh9 committed Jul 16, 2024
1 parent fa494b0 commit e6051cf
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 8 deletions.
7 changes: 3 additions & 4 deletions docs/config_options.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ page:
- [13. `--ignore-underscore-args` (shortform: `-iua`, default: `True`)](#13---ignore-underscore-args-shortform--iua-default-true)
- [14. `--check-class-attributes` (shortform: `-cca`, default: `True`)](#14---check-class-attributes-shortform--cca-default-true)
- [15. `--should-document-private-class-attributes` (shortform: `-sdpca`, default: `False`)](#15---should-document-private-class-attributes-shortform--sdpca-default-false)
- [16. `--treat-property-methods-as-class-attributes` (shortform: `-tpmaca`, default: `True`)](#16---treat-property-methods-as-class-attributes-shortform--tpmaca-default-true)
- [16. `--treat-property-methods-as-class-attributes` (shortform: `-tpmaca`, default: `False`)](#16---treat-property-methods-as-class-attributes-shortform--tpmaca-default-false)
- [17. `--baseline`](#17---baseline)
- [18. `--generate-baseline` (default: `False`)](#18---generate-baseline-default-false)
- [19. `--show-filenames-in-every-violation-message` (shortform: `-sfn`, default: `False`)](#19---show-filenames-in-every-violation-message-shortform--sfn-default-false)
Expand Down Expand Up @@ -194,13 +194,12 @@ for more instructions.
If True, private class attributes (those that start with leading `_`) should be
documented. If False, they should not be documented.

## 16. `--treat-property-methods-as-class-attributes` (shortform: `-tpmaca`, default: `True`)
## 16. `--treat-property-methods-as-class-attributes` (shortform: `-tpmaca`, default: `False`)

If True, treat `@property` methods as class properties. This means that they
need to be documented in the "Attributes" section of the class docstring, and
there cannot be any docstring under the @property methods. This option is only
effective when --check-class-attributes is True. We recommend setting both this
option and --check-class-attributes to True.
effective when --check-class-attributes is True.

## 17. `--baseline`

Expand Down
2 changes: 1 addition & 1 deletion pydoclint/flake8_entry.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ def add_options(cls, parser): # noqa: D102
'-tpmaca',
'--treat-property-methods-as-class-attributes',
action='store',
default='True',
default='False',
parse_from_config=True,
help=(
'If True, treat @property methods as class properties. This means'
Expand Down
6 changes: 3 additions & 3 deletions pydoclint/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ def validateStyleValue(
'--treat-property-methods-as-class-attributes',
type=bool,
show_default=True,
default=True,
default=False,
help=(
'If True, treat @property methods as class properties. This means'
' that they need to be documented in the "Attributes" section of'
Expand Down Expand Up @@ -527,7 +527,7 @@ def _checkPaths(
ignoreUnderscoreArgs: bool = True,
checkClassAttributes: bool = True,
shouldDocumentPrivateClassAttributes: bool = False,
treatPropertyMethodsAsClassAttributes: bool = True,
treatPropertyMethodsAsClassAttributes: bool = False,
requireReturnSectionWhenReturningNothing: bool = False,
requireYieldSectionWhenYieldingNothing: bool = False,
quiet: bool = False,
Expand Down Expand Up @@ -606,7 +606,7 @@ def _checkFile(
ignoreUnderscoreArgs: bool = True,
checkClassAttributes: bool = True,
shouldDocumentPrivateClassAttributes: bool = False,
treatPropertyMethodsAsClassAttributes: bool = True,
treatPropertyMethodsAsClassAttributes: bool = False,
requireReturnSectionWhenReturningNothing: bool = False,
requireYieldSectionWhenYieldingNothing: bool = False,
) -> List[Violation]:
Expand Down

0 comments on commit e6051cf

Please sign in to comment.