Skip to content
This repository was archived by the owner on Aug 21, 2025. It is now read-only.
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
2 changes: 1 addition & 1 deletion .github/workflows/python_deploy_dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
JFROG_ARTIFACTORY_URL: ${{ secrets.JFROG_ARTIFACTORY_URL }}
JFROG_ARTIFACTORY_TOKEN: ${{ secrets.JFROG_ARTIFACTORY_TOKEN }}
call-workflow-pypi-publish:
name: Publish development pypi package (JFrog Artifactory and TestPyPI)
name: Publish development pypi package (JFrog Artifactory, TestPyPI)
uses: MiraGeoscience/CI-tools/.github/workflows/reusable-python-publish_pypi_package.yml@main
with:
package-manager: 'poetry'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/python_deploy_prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
JFROG_ARTIFACTORY_URL: ${{ secrets.JFROG_ARTIFACTORY_URL }}
JFROG_ARTIFACTORY_TOKEN: ${{ secrets.JFROG_ARTIFACTORY_TOKEN }}
call-workflow-pypi-release:
name: Publish production PyPI package (JFrog Artifactory and PyPI)
name: Publish production PyPI package (JFrog Artifactory, PyPI)
if: ${{ github.event_name == 'release' || github.event.inputs.publish-pypi == 'true' }}
uses: MiraGeoscience/CI-tools/.github/workflows/reusable-python-release_pypi_assets.yml@main
with:
Expand Down
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,8 @@
.idea
/tests/**/*.geoh5
/dist/**

#pycharm
/.idea/*
!/.idea/scopes/
!/.idea/copyright/
12 changes: 6 additions & 6 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ repos:
- id: poetry-check
args: [--lock]
- repo: https://github.com/hadialqattan/pycln
rev: v2.4.0
rev: v2.5.0
hooks:
- id: pycln
args: [--config=pyproject.toml]
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.7.0
rev: v0.9.0
hooks:
- id: ruff
args:
Expand All @@ -31,7 +31,7 @@ repos:
# - --unsafe-fixes
- id: ruff-format
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.12.0
rev: v1.14.1
hooks:
- id: mypy
additional_dependencies: [
Expand All @@ -42,15 +42,15 @@ repos:
]
exclude: ^docs/
- repo: https://github.com/codingjoe/relint
rev: 3.2.0
rev: 3.3.1
hooks:
- id: relint
args: [-W] # to fail on warnings
- repo: https://github.com/MiraGeoscience/pre-commit-hooks
rev: v1.0.1
rev: v1.0.2
hooks:
- id: check-copyright
files: (^LICENSE|^README(|-dev).rst|\.py|\.pyi)$
files: (^package\.rst|^LICENSE|^README(|-dev)\.rst|\.py|\.pyi)$
exclude: (^\.|^docs/)
- id: prepare-commit-msg
- id: check-commit-msg
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2024 Mira Geoscience
Copyright (c) 2022-2025 Mira Geoscience

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -71,4 +71,4 @@ Third Party Software notices and/or additional terms and conditions are located

Copyright
^^^^^^^^^
Copyright (c) 2024 Mira Geoscience Ltd.
Copyright (c) 2022-2025 Mira Geoscience Ltd.
2 changes: 1 addition & 1 deletion THIRD_PARTY_SOFTWARE.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ compatibly licensed. We list these here.
- LGPL-3.0-or-later
- Python API for geoh5, an open file format for geoscientific data
* - `h5py <https://www.h5py.org/>`_
- BSD License
- BSD-3-Clause
- The h5py package provides both a high- and low-level interface to the HDF5 library from Python.
* - `numpy <https://github.com/numpy/numpy>`_
- BSD-3-Clause
Expand Down
2 changes: 1 addition & 1 deletion meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ requirements:
run:
- python >=3.10.0,<4
- numpy >=1.26.0,<1.27.0
- geoh5py >=0.10.0a1,<0.11.0a0.dev0
- geoh5py >=0.10.0b1,<0.11.0a.dev

test:
imports:
Expand Down
16 changes: 9 additions & 7 deletions param_sweeps/__init__.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
# Copyright (c) 2024 Mira Geoscience Ltd.
#
# This file is part of param-sweeps.
#
# param-sweeps is distributed under the terms and conditions of the MIT License
# (see LICENSE file at the root of this source code package).

# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
# Copyright (c) 2022-2025 Mira Geoscience Ltd. '
# '
# This file is part of param-sweeps package. '
# '
# param-sweeps is distributed under the terms and conditions of the MIT License '
# (see LICENSE file at the root of this source code package). '
# '
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

__version__ = "0.3.0-alpha.1"
15 changes: 9 additions & 6 deletions param_sweeps/constants.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Copyright (c) 2024 Mira Geoscience Ltd.
#
# This file is part of param-sweeps.
#
# param-sweeps is distributed under the terms and conditions of the MIT License
# (see LICENSE file at the root of this source code package).
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
# Copyright (c) 2022-2025 Mira Geoscience Ltd. '
# '
# This file is part of param-sweeps package. '
# '
# param-sweeps is distributed under the terms and conditions of the MIT License '
# (see LICENSE file at the root of this source code package). '
# '
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

from __future__ import annotations

Expand Down
15 changes: 9 additions & 6 deletions param_sweeps/driver.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Copyright (c) 2024 Mira Geoscience Ltd.
#
# This file is part of param-sweeps.
#
# param-sweeps is distributed under the terms and conditions of the MIT License
# (see LICENSE file at the root of this source code package).
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
# Copyright (c) 2022-2025 Mira Geoscience Ltd. '
# '
# This file is part of param-sweeps package. '
# '
# param-sweeps is distributed under the terms and conditions of the MIT License '
# (see LICENSE file at the root of this source code package). '
# '
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

from __future__ import annotations

Expand Down
15 changes: 9 additions & 6 deletions param_sweeps/generate.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Copyright (c) 2024 Mira Geoscience Ltd.
#
# This file is part of param-sweeps.
#
# param-sweeps is distributed under the terms and conditions of the MIT License
# (see LICENSE file at the root of this source code package).
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
# Copyright (c) 2022-2025 Mira Geoscience Ltd. '
# '
# This file is part of param-sweeps package. '
# '
# param-sweeps is distributed under the terms and conditions of the MIT License '
# (see LICENSE file at the root of this source code package). '
# '
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

from __future__ import annotations

Expand Down
15 changes: 9 additions & 6 deletions param_sweeps/sample_driver.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Copyright (c) 2024 Mira Geoscience Ltd.
#
# This file is part of param-sweeps.
#
# param-sweeps is distributed under the terms and conditions of the MIT License
# (see LICENSE file at the root of this source code package).
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
# Copyright (c) 2022-2025 Mira Geoscience Ltd. '
# '
# This file is part of param-sweeps package. '
# '
# param-sweeps is distributed under the terms and conditions of the MIT License '
# (see LICENSE file at the root of this source code package). '
# '
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

from __future__ import annotations

Expand Down
12 changes: 6 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ classifiers = [
]

include = [
{ path = "COPYING", format = ["sdist", "wheel"] },
{ path = "COPYING.LESSER", format = ["sdist", "wheel"] },
{ path = "LICENSE", format = ["sdist", "wheel"] },
{ path = "README.rst", format = ["sdist", "wheel"] },
{ path = "THIRD_PARTY_SOFTWARE.rst", format = ["sdist", "wheel"] },
{ path = "docs/**/THIRD_PARTY_SOFTWARE.rst", format = ["sdist", "wheel"] },
{ path = "COPYING" },
{ path = "COPYING.LESSER" },
{ path = "LICENSE" },
{ path = "README.rst" },
{ path = "THIRD_PARTY_SOFTWARE.rst" },
{ path = "docs/**/THIRD_PARTY_SOFTWARE.rst" },
]

[tool.poetry.dependencies]
Expand Down
15 changes: 9 additions & 6 deletions tests/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Copyright (c) 2024 Mira Geoscience Ltd.
#
# This file is part of param-sweeps.
#
# param-sweeps is distributed under the terms and conditions of the MIT License
# (see LICENSE file at the root of this source code package).
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
# Copyright (c) 2022-2025 Mira Geoscience Ltd. '
# '
# This file is part of param-sweeps package. '
# '
# param-sweeps is distributed under the terms and conditions of the MIT License '
# (see LICENSE file at the root of this source code package). '
# '
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
21 changes: 12 additions & 9 deletions tests/driver_test.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Copyright (c) 2024 Mira Geoscience Ltd.
#
# This file is part of param-sweeps.
#
# param-sweeps is distributed under the terms and conditions of the MIT License
# (see LICENSE file at the root of this source code package).
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
# Copyright (c) 2022-2025 Mira Geoscience Ltd. '
# '
# This file is part of param-sweeps package. '
# '
# param-sweeps is distributed under the terms and conditions of the MIT License '
# (see LICENSE file at the root of this source code package). '
# '
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

import itertools
import json
Expand Down Expand Up @@ -51,9 +54,9 @@ def test_uuid_from_params():
iterations = list(itertools.product(*test.values()))
for iteration in iterations:
trial_uuid = SweepDriver.uuid_from_params(iteration)
assert trial_uuid == SweepDriver.uuid_from_params(
iteration
), "method is not deterministic"
assert trial_uuid == SweepDriver.uuid_from_params(iteration), (
"method is not deterministic"
)


def test_file_validation(tmp_path: Path):
Expand Down
15 changes: 9 additions & 6 deletions tests/generate_test.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Copyright (c) 2024 Mira Geoscience Ltd.
#
# This file is part of param-sweeps.
#
# param-sweeps is distributed under the terms and conditions of the MIT License
# (see LICENSE file at the root of this source code package).
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
# Copyright (c) 2022-2025 Mira Geoscience Ltd. '
# '
# This file is part of param-sweeps package. '
# '
# param-sweeps is distributed under the terms and conditions of the MIT License '
# (see LICENSE file at the root of this source code package). '
# '
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

import json
from copy import deepcopy
Expand Down
22 changes: 14 additions & 8 deletions tests/version_test.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Copyright (c) 2024 Mira Geoscience Ltd.
#
# This file is part of param-sweeps.
#
# param-sweeps is distributed under the terms and conditions of the MIT License
# (see LICENSE file at the root of this source code package).
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
# Copyright (c) 2022-2025 Mira Geoscience Ltd. '
# '
# This file is part of param-sweeps package. '
# '
# param-sweeps is distributed under the terms and conditions of the MIT License '
# (see LICENSE file at the root of this source code package). '
# '
# '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

from __future__ import annotations

Expand All @@ -18,7 +21,7 @@
import param_sweeps


def get_version():
def get_pyproject_version():
path = Path(__file__).resolve().parents[1] / "pyproject.toml"

with open(str(path), encoding="utf-8") as file:
Expand All @@ -42,7 +45,10 @@ def get_conda_recipe_version():


def test_version_is_consistent():
assert param_sweeps.__version__ == get_version()
assert param_sweeps.__version__ == get_pyproject_version()
normalized_conda_version = Version(get_conda_recipe_version())
normalized_version = Version(param_sweeps.__version__)
assert normalized_conda_version == normalized_version


def test_conda_version_is_pep440():
Expand Down
Loading