Skip to content

Commit

Permalink
Bump pre-commit versions
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremyh committed Mar 7, 2024
1 parent ba5644f commit dc67c03
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ exclude: tests/integration/data
repos:
# Normalise all Python code. (Black + isort + pyupgrade + autoflake)
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.2.2
rev: v0.3.1
hooks:
- id: ruff
args: [--fix, --show-fixes, --output-format, grouped]
Expand Down
3 changes: 1 addition & 2 deletions eodatasets3/assemble.py
Original file line number Diff line number Diff line change
Expand Up @@ -464,8 +464,7 @@ def __init__(
def __enter__(self) -> "DatasetPrepare":
return self

def __exit__(self, exc_type, exc_val, exc_tb):
...
def __exit__(self, exc_type, exc_val, exc_tb): ...

@property
def collection_location(self) -> Path:
Expand Down
3 changes: 1 addition & 2 deletions eodatasets3/names.py
Original file line number Diff line number Diff line change
Expand Up @@ -334,8 +334,7 @@ def __get__(self, c: "NamingConventions", owner) -> str:
return f"{c.collection_prefix}/{offset}/"


class MissingRequiredFieldsError(ValueError):
...
class MissingRequiredFieldsError(ValueError): ...


class RequiredPropertyDict(Eo3Dict):
Expand Down
1 change: 1 addition & 0 deletions eodatasets3/scripts/recompress.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
We compress the inner tiffs and store them in an uncompressed tar. This allows random reads within the files.
We also append a checksum file at the end of the tar.
"""

import copy
import io
import socket
Expand Down
6 changes: 3 additions & 3 deletions tests/integration/prepare/test_prepare_sentinel_l1.py
Original file line number Diff line number Diff line change
Expand Up @@ -448,9 +448,9 @@ def test_filter_folder_structure_info(
# Our output metadata is in a different place than the data, so we expect it to
# embed the true location in the metadata (by default)
if input_dataset_path.is_dir():
expected_metadata_doc[
"location"
] = f"file://{input_dataset_path.as_posix()}/tileInfo.json"
expected_metadata_doc["location"] = (
f"file://{input_dataset_path.as_posix()}/tileInfo.json"
)
else:
expected_metadata_doc["location"] = f"zip:{input_dataset_path}!/"

Expand Down
12 changes: 6 additions & 6 deletions tests/integration/test_naming_conventions.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,9 @@ def test_minimal_s2_dataset_normal(tmp_path: Path):
p.datetime = datetime(2018, 11, 4)
p.product_family = "blueberries"
p.processed = "2018-11-05T12:23:23"
p.properties[
"sentinel:sentinel_tile_id"
] = "S2A_OPER_MSI_L1C_TL_SGS__20170822T015626_A011310_T54KYU_N02.05"
p.properties["sentinel:sentinel_tile_id"] = (
"S2A_OPER_MSI_L1C_TL_SGS__20170822T015626_A011310_T54KYU_N02.05"
)

dataset_id, metadata_path = p.done()

Expand All @@ -139,9 +139,9 @@ def test_s2_naming_conventions(tmp_path: Path):
p.dataset_version = "1.0.0"
p.region_code = "Oz"
p.properties["odc:file_format"] = "GeoTIFF"
p.properties[
"sentinel:sentinel_tile_id"
] = "S2A_OPER_MSI_L1C_TL_SGS__20170822T015626_A011310_T54KYU_N02.05"
p.properties["sentinel:sentinel_tile_id"] = (
"S2A_OPER_MSI_L1C_TL_SGS__20170822T015626_A011310_T54KYU_N02.05"
)

p.note_source_datasets(
"telemetry",
Expand Down
1 change: 0 additions & 1 deletion versioneer.py
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,6 @@
"""


try:
import configparser
except ImportError:
Expand Down

0 comments on commit dc67c03

Please sign in to comment.