Skip to content

Commit

Permalink
Merge pull request #1220 from camptocamp/prospector-profile
Browse files Browse the repository at this point in the history
Use the new Prospector profile to avoid conflict or duplicated
  • Loading branch information
sbrunner authored Aug 23, 2023
2 parents 976384a + 1341510 commit 506b72d
Show file tree
Hide file tree
Showing 8 changed files with 447 additions and 437 deletions.
6 changes: 4 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ repos:
- id: jsonschema-validator
files: |-
(?x)^(
ci/config\.yaml
|example-project/ci/config\.yaml
ci/config\.yaml
|example-project/ci/config\.yaml
)$
- repo: https://github.com/sbrunner/jsonschema2md2
rev: 0.9.0
Expand Down Expand Up @@ -141,3 +141,5 @@ repos:
- --tool=pydocstyle
- --die-on-tool-error
- --output-format=pylint
additional_dependencies:
- prospector-profile-duplicated==0.1.0 # pypi
7 changes: 2 additions & 5 deletions .prospector.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
inherits:
- duplicated
strictness: veryhigh
max-line-length: 110
doc-warnings: true
Expand All @@ -7,7 +9,6 @@ ignore-paths:

pylint:
disable:
- wrong-import-order
- too-many-arguments
- too-many-branches
- too-many-locals
Expand All @@ -22,21 +23,17 @@ pycodestyle:
options:
max-line-length: 110
disable:
- E203 # whitespace before ':'
- W293 # blank line contains whitespace
- E501 # line too long, Done by Black

pydocstyle:
disable:
- D100 # Missing docstring in public module
- D105 # Missing docstring in magic method
- D200 # One-line docstring should fit on one line with quotes
- D202 # No blank lines allowed after function docstring
- D203 # 1 blank line required before class
- D212 # Multi-line docstring summary should start at the first line
- D407 # Missing dashed underline after section
- D413 # Missing blank line after last section

mypy:
run: true

Expand Down
3 changes: 3 additions & 0 deletions example-project/.pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -99,3 +99,6 @@ repos:
args:
- --tool=pydocstyle
- --die-on-tool-error
- --output-format=pylint
additional_dependencies:
- prospector-profile-duplicated==0.1.0 # pypi
21 changes: 2 additions & 19 deletions example-project/.prospector.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
inherits:
- duplicated
strictness: veryhigh
max-line-length: 110

pylint:
disable:
- wrong-import-order
- too-many-arguments
- too-many-branches
- too-many-locals
Expand All @@ -14,24 +15,6 @@ pylint:
pycodestyle:
options:
max-line-length: 110
disable:
- E203 # whitespace before ':'
- E231 # missing whitespace after ','
- E501 # line too long
- E641 # at least two spaces before inline comment
- E261 # at least two spaces before inline comment
- E302 # expected 2 blank lines, found 1
- W293 # blank line contains whitespace

pydocstyle:
disable:
- D102 # missing docstring in public method
- D200 # one-line docstring should fit on one line with quotes
- D202 # no blank lines after function docstring
- D203 # 1 blank line required before class docstring
- D204 # 1 blank line required after class docstring
- D212 # multi-line docstring summary should start at the first line
- D213 # multi-line docstring summary should start at the second line

mypy:
run: true
Expand Down
826 changes: 419 additions & 407 deletions example-project/poetry.lock

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions example-project/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ include = ["project/py.typed"]
[tool.poetry.dependencies]
python = ">=3.10,<3.11"

[tool.poetry.dev-dependencies]
# pylint = "2.15.6"
[tool.poetry.group.dev.dependencies]
prospector = { version = "1.10.2", extras = ["with_bandit", "with_mypy", "with_pyroma"] }
prospector-profile-duplicated = "0.1.0"

[build-system]
requires = [
Expand Down
14 changes: 13 additions & 1 deletion poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ publish_plugins = []
pr_checks = ["codespell"]
version = ["multi-repo-automation"]

[tool.poetry.dev-dependencies]
[tool.poetry.group.dev.dependencies]
# pylint = "2.15.6"
prospector = { version = "1.10.2", extras = ["with_bandit", "with_mypy", "with_pyroma"] }
types-requests = "2.31.0.2"
Expand All @@ -110,6 +110,7 @@ types-setuptools = "68.0.0.3"
types-markdown = "3.4.2.10"
types-toml = "0.10.8.7"
typing-extensions = "4.7.1"
prospector-profile-duplicated = "0.1.0"

[build-system]
requires = [
Expand Down

0 comments on commit 506b72d

Please sign in to comment.