Skip to content

Commit

Permalink
Merge pull request #2739 from pytroll/pre-commit-ci-update-config
Browse files Browse the repository at this point in the history
[pre-commit.ci] pre-commit autoupdate
  • Loading branch information
djhoese authored Feb 6, 2024
2 parents 5eba93d + 55d7ed2 commit a97ebb0
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 8 deletions.
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ fail_fast: false
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: 'v0.1.9'
rev: 'v0.2.0'
hooks:
- id: ruff
- repo: https://github.com/pre-commit/pre-commit-hooks
Expand All @@ -14,7 +14,7 @@ repos:
- id: check-yaml
args: [--unsafe]
- repo: https://github.com/PyCQA/bandit
rev: '1.7.6' # Update me!
rev: '1.7.7' # Update me!
hooks:
- id: bandit
args: [--ini, .bandit]
Expand Down
10 changes: 6 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,19 +14,21 @@ known_first_party = "satpy"
line_length = 120

[tool.ruff]
line-length = 120

[tool.ruff.lint]
# See https://docs.astral.sh/ruff/rules/
# In the future, add "B", "S", "N"
select = ["A", "D", "E", "W", "F", "I", "PT", "TID", "C90", "Q", "T10", "T20"]
line-length = 120

[tool.ruff.per-file-ignores]
[tool.ruff.lint.per-file-ignores]
"satpy/tests/*" = ["S101"] # assert allowed in tests
"utils/coord2area_def.py" = ["T201"] # allow print
"fetch_avhrr_calcoeffs.py" = ["T201"] # allow print

[tool.ruff.pydocstyle]
[tool.ruff.lint.pydocstyle]
convention = "google"

[tool.ruff.mccabe]
[tool.ruff.lint.mccabe]
# Unlike Flake8, default to a complexity level of 10.
max-complexity = 10
2 changes: 1 addition & 1 deletion satpy/tests/reader_tests/test_hy2_scat_l2b_h5.py
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ def _get_global_attrs(self, num_rows, num_cols):
"/attr/Platform_LongName": "Haiyang 2B Ocean Observing Satellite",
"/attr/Platform_ShortName": "HY-2B",
"/attr/Platform_Type": "spacecraft",
"/attr/Producer_Agency": "Ministry of Natural Resources of the People\'s Republic of China",
"/attr/Producer_Agency": "Ministry of Natural Resources of the People's Republic of China",
"/attr/Producer_Institution": "NSOAS",
"/attr/Production_Date_Time": "20200326T06:23:10",
"/attr/Range_Beginning_Time": "20200326T01:11:07",
Expand Down
2 changes: 1 addition & 1 deletion satpy/writers/awips_tiled.py
Original file line number Diff line number Diff line change
Expand Up @@ -1824,7 +1824,7 @@ def main():
group_2.add_argument("--letters", dest="lettered_grid", action="store_true",
help="Create tiles from a static letter-based grid based on the product projection")
group_2.add_argument("--letter-subtiles", nargs=2, type=int, default=(2, 2),
help="Specify number of subtiles in each lettered tile: \'row col\'")
help="Specify number of subtiles in each lettered tile: 'row col'")
group_2.add_argument("--output-pattern", default=DEFAULT_OUTPUT_PATTERN,
help="output filenaming pattern")
group_2.add_argument("--source-name", default="SSEC",
Expand Down

0 comments on commit a97ebb0

Please sign in to comment.