Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
77 changes: 39 additions & 38 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,49 +1,50 @@
repos:

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
- id: check-added-large-files
- id: check-case-conflict
- id: check-yaml
args: ["--unsafe"]
- id: debug-statements
- id: end-of-file-fixer
- id: trailing-whitespace

- repo: https://github.com/asottile/pyupgrade
rev: v3.15.0
hooks:
- id: pyupgrade
args: ["--py38-plus"]

- repo: https://github.com/PyCQA/autoflake
rev: v2.2.1
hooks:
- id: autoflake

- repo: https://github.com/pycqa/isort
rev: 5.12.0
hooks:
- id: isort
rev: v6.0.0
hooks:
- id: check-added-large-files
- id: check-ast
- id: check-case-conflict
- id: check-yaml
args: ["--unsafe"]
- id: check-toml
- id: check-merge-conflict
- id: check-symlinks
- id: debug-statements
- id: detect-private-key
- id: end-of-file-fixer
- id: trailing-whitespace

- repo: https://github.com/pre-commit/pygrep-hooks
rev: v1.10.0
hooks:
#- id: python-check-blanket-noqa
- id: python-check-mock-methods
- id: rst-directive-colons
- id: rst-inline-touching-normal
- id: text-unicode-replacement-char

- repo: https://github.com/codespell-project/codespell
rev: v2.4.1
hooks:
- id: codespell
args: ["--write-changes"]
additional_dependencies:
- tomli

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: 'v0.13.0'
hooks:
- id: ruff
args: ["--fix"]

- repo: https://github.com/psf/black
rev: 23.10.1
rev: 25.1.0
hooks:
- id: black

- repo: https://github.com/asottile/blacken-docs
rev: 1.16.0
rev: 1.20.0
hooks:
- id: blacken-docs

- repo: https://github.com/PyCQA/flake8
rev: 6.1.0
hooks:
- id: flake8

- repo: https://github.com/PyCQA/bandit
rev: 1.7.5
hooks:
- id: bandit
args: ["-c", "bandit.yaml"]
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import sys
from pathlib import Path

# Ensure documentation examples are determinstically random.
# Ensure documentation examples are deterministically random.
import numpy
import tomli
from pkg_resources import get_distribution
Expand Down
27 changes: 23 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,26 @@ force-exclude = '''
)
'''

[tool.isort]
profile = "black"
filter_files = true
line_length = 120
[tool.ruff]
line-length = 120

[tool.ruff.lint]
select = [
"E", # pycodestyle
"F", # pyflakes, autoflake
"I", # isort
"S", # bandit
"UP", # pyupgrade
"RUF", # ruff specific, includes yesqa
]
extend-ignore = [
"RUF005",

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ignoring this for now since it would trigger substantive changes in the code.

]

[tool.ruff.lint.per-file-ignores]
"test_*.py" = ["S101"]
"tests/*" = ["S101"]


[tool.codespell]
skip="*.pdf,*.fits,*.asdf,.tox,build,./tags,.git,docs/build"
7 changes: 1 addition & 6 deletions src/asdf_coordinates_schemas/integration.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,6 @@
import sys
import importlib.resources as importlib_resources
from pathlib import Path

if sys.version_info < (3, 9):
import importlib_resources
else:
import importlib.resources as importlib_resources

from asdf.resource import DirectoryResourceMapping

import asdf_coordinates_schemas
Expand Down
Loading