From 30eb47012423eaca964eab1d6867ec8d218fa201 Mon Sep 17 00:00:00 2001 From: SophieCurinier Date: Wed, 22 Jan 2025 13:32:48 -0500 Subject: [PATCH 1/6] [DEVOPS-635] Convert conda to rattler recipe --- meta.yaml => recipe.yaml | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) rename meta.yaml => recipe.yaml (71%) diff --git a/meta.yaml b/recipe.yaml similarity index 71% rename from meta.yaml rename to recipe.yaml index d32bc215..0602c938 100644 --- a/meta.yaml +++ b/recipe.yaml @@ -1,17 +1,20 @@ -{% set name = "mira-omf" %} -{% set version = "3.3.0b2" %} +schema_version: 1 + +context: + name: mira-omf + version: 3.3.0b2 package: - name: {{ name|lower }} - version: {{ version }} + name: ${{ name|lower }} + version: ${{ version }} source: path: ../omf build: - noarch: python - script: {{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation number: 0 + noarch: python + script: ${{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation requirements: host: @@ -37,3 +40,4 @@ extra: recipe-maintainers: - SophieCurinier - sebhmg + From 7983b3c4a32f1369dd5824180121d3ea50782eed Mon Sep 17 00:00:00 2001 From: SophieCurinier Date: Wed, 29 Jan 2025 16:02:20 -0500 Subject: [PATCH 2/6] [DEVOPS-635] Correct .pre-commit-config and test/version_test to use rattler instead of conda --- .github/workflows/python_deploy_dev.yml | 3 ++- .pre-commit-config.yaml | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/python_deploy_dev.yml b/.github/workflows/python_deploy_dev.yml index 5c681284..5e56cd79 100644 --- a/.github/workflows/python_deploy_dev.yml +++ b/.github/workflows/python_deploy_dev.yml @@ -12,10 +12,11 @@ concurrency: jobs: call-workflow-conda-publish: name: Publish development conda package on JFrog Artifactory - uses: MiraGeoscience/CI-tools/.github/workflows/reusable-python-publish_conda_package.yml@main + uses: MiraGeoscience/CI-tools/.github/workflows/reusable-python-publish_rattler_package.yml@DEVOPS-635 with: package-name: 'mira-omf' python-version: '3.10' + local-repo-names: '["public-conda-dev-local"]' virtual-repo-names: '["public-conda-dev"]' secrets: JFROG_ARTIFACTORY_URL: ${{ secrets.JFROG_ARTIFACTORY_URL }} diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 32c89854..88119aaa 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -78,7 +78,7 @@ repos: exclude_types: [jupyter] - id: check-toml - id: check-yaml - exclude: ^meta.yaml$ + exclude: ^recipe.yaml$ - id: check-added-large-files - id: check-case-conflict - id: check-merge-conflict From 5a620a2df3cb181cb47642953f884c9c60b7fd13 Mon Sep 17 00:00:00 2001 From: SophieCurinier Date: Thu, 30 Jan 2025 10:05:15 -0500 Subject: [PATCH 3/6] [DEVOPS-635] Use reusable-python-publish_rattler_package.yml@main --- .github/workflows/python_deploy_dev.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/python_deploy_dev.yml b/.github/workflows/python_deploy_dev.yml index 5e56cd79..ab4b5c87 100644 --- a/.github/workflows/python_deploy_dev.yml +++ b/.github/workflows/python_deploy_dev.yml @@ -12,12 +12,12 @@ concurrency: jobs: call-workflow-conda-publish: name: Publish development conda package on JFrog Artifactory - uses: MiraGeoscience/CI-tools/.github/workflows/reusable-python-publish_rattler_package.yml@DEVOPS-635 + uses: MiraGeoscience/CI-tools/.github/workflows/reusable-python-publish_rattler_package.yml@main with: package-name: 'mira-omf' python-version: '3.10' - local-repo-names: '["public-conda-dev-local"]' - virtual-repo-names: '["public-conda-dev"]' + source-repo-names: '["public-conda-dev-local", "conda-forge-dev-remote"]' + publish-repo-names: '["public-conda-dev"]' secrets: JFROG_ARTIFACTORY_URL: ${{ secrets.JFROG_ARTIFACTORY_URL }} JFROG_ARTIFACTORY_TOKEN: ${{ secrets.JFROG_ARTIFACTORY_TOKEN }} From 2a3b9138154c0233a4c48f348de848294ffb0421 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Thu, 30 Jan 2025 15:06:41 +0000 Subject: [PATCH 4/6] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- recipe.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/recipe.yaml b/recipe.yaml index bc4a62bd..1de2daaa 100644 --- a/recipe.yaml +++ b/recipe.yaml @@ -40,4 +40,3 @@ extra: recipe-maintainers: - SophieCurinier - sebhmg - From 9d3eefbda251331e29052ea2dc6daf03a1aa0f93 Mon Sep 17 00:00:00 2001 From: SophieCurinier Date: Thu, 30 Jan 2025 10:10:27 -0500 Subject: [PATCH 5/6] [DEVOPS-635] Correct get_conda_recipe_version --- tests/version_test.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/version_test.py b/tests/version_test.py index 571408d8..356f2741 100644 --- a/tests/version_test.py +++ b/tests/version_test.py @@ -33,7 +33,7 @@ def get_pyproject_version(): def get_conda_recipe_version(): - path = Path(__file__).resolve().parents[1] / "meta.yaml" + path = Path(__file__).resolve().parents[1] / "recipe.yaml" with open(str(path), encoding="utf-8") as file: content = file.read() @@ -43,7 +43,7 @@ def get_conda_recipe_version(): recipe = yaml.safe_load(rendered_yaml) - return recipe["package"]["version"] + return recipe["context"]["version"] def get_version_in_readme() -> str | None: From 101ebe221800cc199ae79ae474dc4aba0fd1d24c Mon Sep 17 00:00:00 2001 From: SophieCurinier Date: Thu, 30 Jan 2025 14:23:09 -0500 Subject: [PATCH 6/6] [DEVOPS-635] Add homepage, repository, documentation and summary inside recipe.yaml --- recipe.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/recipe.yaml b/recipe.yaml index 1de2daaa..8602813b 100644 --- a/recipe.yaml +++ b/recipe.yaml @@ -32,9 +32,14 @@ requirements: - geoh5py >=0.10.0b1,<0.11.0a.dev about: + summary: API library for Open Mining Format, a new standard for mining data backed by the Global Mining Standards & Guidelines Group. + description: | + API library for Open Mining Format, a new standard for mining data backed by the Global Mining Standards & Guidelines Group. license: MIT license_file: - LICENSE + homepage: https://www.mirageoscience.com/mining-industry-software/python-integration/ + repository: https://github.com/MiraGeoscience/omf extra: recipe-maintainers: