Skip to content

Commit 6402f4f

Browse files
chore: update pre-commit hooks (#85)
* chore: update pre-commit hooks updates: - [github.com/astral-sh/ruff-pre-commit: v0.9.7 → v0.11.4](astral-sh/ruff-pre-commit@v0.9.7...v0.11.4) - [github.com/crate-ci/typos: v1.29.10 → v1](crate-ci/typos@v1.29.10...v1) - [github.com/abravalheri/validate-pyproject: v0.23 → v0.24.1](abravalheri/validate-pyproject@v0.23...v0.24.1) - [github.com/python-jsonschema/check-jsonschema: 0.31.2 → 0.32.1](python-jsonschema/check-jsonschema@0.31.2...0.32.1) * style: pre-commit fixes * Drop typos --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Alec Thomson (S&A, Kensington WA) <[email protected]>
1 parent 6e3b738 commit 6402f4f

File tree

6 files changed

+13
-18
lines changed

6 files changed

+13
-18
lines changed

.pre-commit-config.yaml

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,17 +33,12 @@ repos:
3333
- id: rst-inline-touching-normal
3434

3535
- repo: https://github.com/astral-sh/ruff-pre-commit
36-
rev: "v0.9.7"
36+
rev: "v0.11.4"
3737
hooks:
3838
- id: ruff
3939
args: ["--fix", "--show-fixes"]
4040
- id: ruff-format
4141

42-
- repo: https://github.com/crate-ci/typos
43-
rev: v1.29.10
44-
hooks:
45-
- id: typos
46-
4742
- repo: local
4843
hooks:
4944
- id: disallow-caps
@@ -53,13 +48,13 @@ repos:
5348
exclude: .pre-commit-config.yaml
5449

5550
- repo: https://github.com/abravalheri/validate-pyproject
56-
rev: "v0.23"
51+
rev: "v0.24.1"
5752
hooks:
5853
- id: validate-pyproject
5954
additional_dependencies: ["validate-pyproject-schema-store[all]"]
6055

6156
- repo: https://github.com/python-jsonschema/check-jsonschema
62-
rev: "0.31.2"
57+
rev: "0.32.1"
6358
hooks:
6459
- id: check-dependabot
6560
- id: check-github-workflows

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ Corresponds with DR1 paper.
384384

385385
- `submit/casda_pre_prep.sh`
386386
- `submit/casda_prep_test.sh`
387-
- ASKAP RACS database as a submodule (changes how `init_databse.py` ingests
387+
- ASKAP RACS database as a submodule (changes how `init_database.py` ingests
388388
data)
389389

390390
## [0.2.0] - 2019-12-01

arrakis/makecat.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ class SpectralIndices(NamedTuple):
5858
betas_err: np.ndarray
5959

6060

61-
def combinate( # codespell:ignore[combinate]
61+
def combine( # codespell:ignore[combine]
6262
data: ArrayLike,
6363
) -> tuple[ArrayLike, ArrayLike]:
6464
"""Return all combinations of data with itself
@@ -69,8 +69,8 @@ def combinate( # codespell:ignore[combinate]
6969
Returns:
7070
Tuple[ArrayLike, ArrayLike]: Data_1 matched with Data_2
7171
"""
72-
ix, iy = np.triu_indices(data.shape[0], k=1)
73-
idx = np.vstack((ix, iy)).T
72+
ix, it = np.triu_indices(data.shape[0], k=1)
73+
idx = np.vstack((ix, it)).T
7474
dx, dy = data[idx].swapaxes(0, 1)
7575
return dx, dy
7676

@@ -684,7 +684,7 @@ def get_integration_time(cat: RMTable, field_col: Collection, sbid: int | None =
684684
] * len(field_names)
685685
unique_field_names = list(set(field_names))
686686

687-
reutrn_vals = {"_id": 0, "SCAN_TINT": 1, "FIELD_NAME": 1, "SBID": 1}
687+
return_vals = {"_id": 0, "SCAN_TINT": 1, "FIELD_NAME": 1, "SBID": 1}
688688

689689
doc_count = field_col.count_documents(query)
690690

@@ -699,7 +699,7 @@ def get_integration_time(cat: RMTable, field_col: Collection, sbid: int | None =
699699
else:
700700
logger.warning("Using SELECT=0 instead.")
701701

702-
field_data = list(field_col.find(query, reutrn_vals))
702+
field_data = list(field_col.find(query, return_vals))
703703
tint_df = pd.DataFrame(field_data)
704704
tint_df.set_index("FIELD_NAME", inplace=True, drop=False)
705705

arrakis/merge_fields.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,7 @@ def main(
317317
merge_name=merge_name,
318318
)
319319

320-
mutilple_updates = merge_multiple_fields(
320+
multiple_updates = merge_multiple_fields(
321321
field_dict=field_dict,
322322
data_dir=data_dir,
323323
beams_col=beams_col,
@@ -326,7 +326,7 @@ def main(
326326
)
327327

328328
singleton_comp = [f.result() for f in singleton_updates]
329-
multiple_comp = [f.result() for f in mutilple_updates]
329+
multiple_comp = [f.result() for f in multiple_updates]
330330

331331
for m in multiple_comp:
332332
m._doc["$set"].update({f"beams.{merge_name}.DR1": True})

arrakis/rmsynth_oncuts.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ def rmsynthoncut3d(
190190
fitRMSF=fitRMSF,
191191
prefixOut=prefix,
192192
outDir=os.path.dirname(ifile),
193-
write_seperate_FDF=True,
193+
write_separate_FDF=True,
194194
not_rmsf=not_RMSF,
195195
nBits=32,
196196
verbose=rm_verbose,

scripts/casda_prepare.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -514,7 +514,7 @@ def main(
514514
casda_dir = os.path.join(data_dir, f"casda_{prep_type}")
515515
try_mkdir(casda_dir)
516516

517-
# Link catalgoue to casda directory
517+
# Link catalogue to casda directory
518518
cat_dir = os.path.join(casda_dir, "catalogues")
519519
try_mkdir(cat_dir)
520520
if prep_type != "full":

0 commit comments

Comments
 (0)