From 539d5037af0bdbee8ab3fcc407bb9a5e8369d14d Mon Sep 17 00:00:00 2001 From: Kristoffer Andersen Date: Wed, 4 Sep 2024 21:16:34 +0200 Subject: [PATCH] fix: ifco v08 support (#6) --- .github/dependabot.yml | 10 + .github/workflows/ci-tests.yaml | 49 + .../workflows/{ci-test.yaml => pr-tests.yaml} | 61 +- .gitignore | 3 +- action_config.toml | 18 - conda/bld.bat | 4 +- conda/build.sh | 4 +- conda/conda_build_config.yaml | 37 +- conda/meta.yaml | 20 +- conda/stub_gen.py | 93 -- conda/yum_requirements.txt | 6 + environment.build.yml | 18 +- pixi.lock | 960 ++++++++++++++++++ pyproject.toml | 23 +- src/adacpp/cadit/__init__.py | 4 + src/cadit/ifc/ifcop.cpp | 8 +- src/cadit/occt/step_writer.cpp | 25 +- tests/py/test_ada_integration.py | 48 + tests/py/test_basic.py | 30 +- 19 files changed, 1239 insertions(+), 182 deletions(-) create mode 100644 .github/dependabot.yml create mode 100644 .github/workflows/ci-tests.yaml rename .github/workflows/{ci-test.yaml => pr-tests.yaml} (66%) delete mode 100644 conda/stub_gen.py create mode 100644 conda/yum_requirements.txt create mode 100644 pixi.lock create mode 100644 tests/py/test_ada_integration.py diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..ae18a3c --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,10 @@ +version: 2 +updates: + - package-ecosystem: github-actions + directory: / + schedule: + interval: monthly # or daily, weekly + groups: + dependencies: + patterns: + - '*' \ No newline at end of file diff --git a/.github/workflows/ci-tests.yaml b/.github/workflows/ci-tests.yaml new file mode 100644 index 0000000..822b315 --- /dev/null +++ b/.github/workflows/ci-tests.yaml @@ -0,0 +1,49 @@ +name: ci-tests + +# bump 1 +on: + push: + +# Use concurrency to ensure that only one instance of this workflow is running at a time +concurrency: + group: ci-tests-${{ github.ref_name }} + cancel-in-progress: true + +env: + CROOT_DIR: /home/runner/work/build + ARTIFACTS_DIR: /home/runner/work/artifacts + PKG_DIR: linux-64 + +jobs: + + build_test: + name: ada-cpp-test + runs-on: ubuntu-latest + defaults: + run: + shell: bash -l {0} + steps: + - uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.head.sha || github.ref }} + + # Install OpenGL dependencies + - name: Install OpenGL dependencies + run: sudo apt-get update && sudo apt-get install -y libgl1-mesa-dev + + - uses: mamba-org/setup-micromamba@v1 # https://github.com/mamba-org/setup-micromamba + with: + environment-file: environment.build.yml + cache-environment: true + cache-downloads: true + create-args: >- + python=3.12 + ada-py + + - name: install package + run: | + pip install . + + - name: test package + run: | + pytest tests \ No newline at end of file diff --git a/.github/workflows/ci-test.yaml b/.github/workflows/pr-tests.yaml similarity index 66% rename from .github/workflows/ci-test.yaml rename to .github/workflows/pr-tests.yaml index cc3f385..6f606c4 100644 --- a/.github/workflows/ci-test.yaml +++ b/.github/workflows/pr-tests.yaml @@ -1,20 +1,36 @@ -name: ci-ada-cpp-test +name: pr-tests # bump 1 on: - push: -# branches: -# - donotrun - paths-ignore: - - README.md - - .gitignore - - .github/workflows/basic_test.yaml + pull_request: + branches: + - main + +# Use concurrency to ensure that only one instance of this workflow is running at a time +concurrency: + group: pr-tests-${{ github.ref_name }} + cancel-in-progress: true env: CROOT_DIR: /home/runner/work/build ARTIFACTS_DIR: /home/runner/work/artifacts jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.head.sha || github.ref }} + + - uses: prefix-dev/setup-pixi@v0.8.1 # https://github.com/prefix-dev/setup-pixi + with: + pixi-version: v0.28.2 + cache: true + environments: lint + + - run: pixi run lint + build_test: name: ada-cpp-${{ matrix.platform.name }}-${{ matrix.pyver.name }}-${{ matrix.variant.name }}=${{ matrix.variant.value }} runs-on: ${{ matrix.platform.distver }} @@ -25,19 +41,26 @@ jobs: fail-fast: false matrix: pyver: [ - { name: py311, distver: '3.11' }, + { name: py312, distver: '3.12' }, ] platform: [ { name: win, distver: windows-latest, pkg_dir: 'win-64' }, { name: linux, distver: ubuntu-latest, pkg_dir: 'linux-64' }, - { name: macOS, distver: macos-latest, pkg_dir: 'osx-64' } + { name: macOS, distver: macos-13, pkg_dir: 'osx-64' } ] variant: [ - { name: occt, value: '7.7.2=*novtk*' }, - { name: occt, value: '7.7.2=*all*' } + { name: variant, value: 'novtk' }, + { name: variant, value: 'all' } ] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.head.sha || github.ref }} + + # Install OpenGL dependencies + - name: Install OpenGL dependencies + if: ${{ matrix.platform.name == 'linux' }} + run: sudo apt-get update && sudo apt-get install -y libgl1-mesa-dev - name: set ENV WORK_DIR run: | @@ -58,7 +81,7 @@ jobs: if: ${{ matrix.platform.name == 'macOS' }} run: | curl -L https://github.com/phracker/MacOSX-SDKs/releases/download/11.3/MacOSX10.15.sdk.tar.xz | tar -xvJf - -C /Users/runner/work/ - + - uses: mamba-org/setup-micromamba@v1 # https://github.com/mamba-org/setup-micromamba with: @@ -73,11 +96,9 @@ jobs: zstd_compression_level: 19 channel_priority: strict channels: - - krande - conda-forge create-args: >- - python=${{ matrix.pyver.distver }} - anaconda-client + python=3.12 boa - name: make dirs @@ -88,8 +109,4 @@ jobs: - name: build local packages run: | conda mambabuild . --python ${{ matrix.pyver.distver }} --variants "{ '${{matrix.variant.name}}': '${{matrix.variant.value}}'}" - working-directory: conda - - - name: upload to anaconda - run: | - anaconda -t ${{ secrets.ANACONDA_TOKEN }} upload --force --user krande --label dev ${{ env.ARTIFACTS_DIR }}/${{ env.PKG_DIR }}/*.conda + working-directory: conda \ No newline at end of file diff --git a/.gitignore b/.gitignore index cea042d..50665f3 100644 --- a/.gitignore +++ b/.gitignore @@ -3,4 +3,5 @@ build/ cmake-build*/ .env .env.json -temp/ \ No newline at end of file +temp/ +.pixi/ \ No newline at end of file diff --git a/action_config.toml b/action_config.toml index 24be379..ce994ae 100644 --- a/action_config.toml +++ b/action_config.toml @@ -2,24 +2,6 @@ enabled = true pre_release_tag = "dev" -[tool.python.conda] -enabled = true -recipe_dir = "./conda" - -# Anaconda Related -use_anaconda_server = true -owner = "Krande" -label = "main" -# -# info -# -# If you are uploading to public/private anaconda you need to set this -# secrets.CONDA_API_TOKEN -# -# Or if you will use a private QUETZ server you need to set these -# secrets.QUETZ_API_KEY -# secrets.QUETZ_URL - [tool.semantic_release] version_toml = ["pyproject.toml:project.version"] # info diff --git a/conda/bld.bat b/conda/bld.bat index e2a5ae0..2f57b3b 100644 --- a/conda/bld.bat +++ b/conda/bld.bat @@ -1,6 +1,4 @@ python -m pip install . --no-build-isolation -v ^ --config-settings=cmake.args=-DODBDUMP_BIN_DIR="%LIBRARY_PREFIX%"/bin ^ --config-settings=cmake.args=-DCMAKE_INSTALL_PREFIX="%LIBRARY_PREFIX%" ^ - --config-settings=cmake.args=-DCONDA_BUILD=ON - -python %RECIPE_DIR%/stub_gen.py \ No newline at end of file + --config-settings=cmake.args=-DCONDA_BUILD=ON \ No newline at end of file diff --git a/conda/build.sh b/conda/build.sh index 55e5c8c..3e04b78 100644 --- a/conda/build.sh +++ b/conda/build.sh @@ -5,6 +5,4 @@ set -ex python -m pip install . --no-build-isolation -v \ --config-settings=cmake.args=-DODBDUMP_BIN_DIR="${PREFIX}"/bin \ --config-settings=cmake.args=-DCMAKE_INSTALL_PREFIX="${PREFIX}" \ - --config-settings=cmake.args=-DCONDA_BUILD=ON - -python "${RECIPE_DIR}/stub_gen.py" \ No newline at end of file + --config-settings=cmake.args=-DCONDA_BUILD=ON \ No newline at end of file diff --git a/conda/conda_build_config.yaml b/conda/conda_build_config.yaml index 5668e36..6d6c879 100644 --- a/conda/conda_build_config.yaml +++ b/conda/conda_build_config.yaml @@ -1,12 +1,39 @@ occt: - - 7.7.2=*novtk* - - 7.7.2=*all* + - 7.7.2 -#CONDA_BUILD_SYSROOT: -# - "/Users/runner/work/MacOSX10.15.sdk" # [osx] +variant: + - novtk + - all + +c_stdlib: + - vs # [win] + - sysroot # [linux] + - macosx_deployment_target # [osx and x86_64] + +cdt_name: + - cos7 # [linux] + +c_stdlib_version: + - "10.15" # [osx and x86_64] + - '2.17' # [linux] + +MACOSX_SDK_VERSION: # [osx and x86_64] + - "10.15" # [osx and x86_64] c_compiler: - vs2022 # [win] + - gcc # [linux] + - clang # [osx] + +c_compiler_version: + - '17' # [osx] + - '13' # [linux] cxx_compiler: - - vs2022 # [win] \ No newline at end of file + - vs2022 # [win] + - gcc # [linux] + - clang # [osx] + +cxx_compiler_version: + - '17' # [osx] + - '13' # [linux] \ No newline at end of file diff --git a/conda/meta.yaml b/conda/meta.yaml index 27314fd..9cb1d8c 100644 --- a/conda/meta.yaml +++ b/conda/meta.yaml @@ -10,19 +10,24 @@ source: path: ../ build: + skip: True # [py<310] number: 0 - string: py{{ CONDA_PY }}_{{ variant }}_h{{ PKG_HASH }}_{{ PKG_BUILDNUM }} + run_exports: + - {{ pin_subpackage(name, max_pin='x.x.x') }} requirements: build: - - "{{ compiler('c') }}" - - "{{ compiler('cxx') }}" - - "{{ cdt('mesa-libGL-devel') }}" # [unix] provides OpenGL development libraries + - {{ stdlib("c") }} + - {{ compiler('c') }} + - {{ compiler('cxx') }} + - {{ cdt('mesa-libGL-devel') }} # [linux] + - cmake + - ninja # [win] + - make # [unix] host: - python - - occt - - pybind11-stubgen 2.1 + - occt * *{{ variant }}* - ifcopenshell - cgal-cpp - scikit-build-core @@ -34,9 +39,7 @@ requirements: run: - python - - "{{ pin_compatible('occt', max_pin='x.x.x') }}" - "{{ pin_compatible('gmsh', max_pin='x.x.x') }}" - - "{{ pin_compatible('ifcopenshell', max_pin='x.x.x') }}" test: source_files: @@ -44,6 +47,7 @@ test: - files requires: - pytest + - ada-py commands: - pytest tests diff --git a/conda/stub_gen.py b/conda/stub_gen.py deleted file mode 100644 index 4fd09c6..0000000 --- a/conda/stub_gen.py +++ /dev/null @@ -1,93 +0,0 @@ -import argparse -import importlib -import logging -import pathlib -from typing import Union - -import pybind11_stubgen - -logger = logging.getLogger(__name__) - - -def run( - parser: pybind11_stubgen.IParser, - printer: pybind11_stubgen.Printer, - module_name: str, - out_dir: pathlib.Path, - sub_dir: Union[pathlib.Path, None], - dry_run: bool, -): - module = parser.handle_module( - pybind11_stubgen.QualifiedName.from_str(module_name), - importlib.import_module(module_name), - ) - - parser.finalize() - - if module is None: - raise RuntimeError(f"Can't parse {module_name}") - - if dry_run: - return - - writer = pybind11_stubgen.Writer() - - out_dir.mkdir(exist_ok=True) - logger.info(f"Writing stubs to {out_dir}") - writer.write_module(module, printer, to=out_dir, sub_dir=sub_dir) - - -def main(): - module_name = "adacpp" - pyi_dest_dir = pathlib.Path(__import__(module_name).__file__).parent.parent - # pyi_dest_dir = ".stubs" - - args = argparse.Namespace( - module_name=module_name, - ignore_all_errors=None, - ignore_invalid_identifiers=None, - ignore_invalid_expressions=None, - ignore_unresolved_names=None, - print_invalid_expressions_as_is=False, - output_dir=pyi_dest_dir, - root_suffix=None, - # set_ignored_invalid_identifiers=None, - # set_ignored_invalid_expressions=None, - # set_ignored_unresolved_names=None, - exit_code=False, - numpy_array_wrap_with_annotated_fixed_size=True, - numpy_array_remove_parameters=True, - numpy_array_wrap_with_annotated=True, - dry_run=False, - ) - # shutil.copytree('stubs', dummy_lib, dirs_exist_ok=True) - logging.basicConfig( - level=logging.INFO, - format="%(name)s - [%(levelname)7s] %(message)s", - ) - - parser = pybind11_stubgen.stub_parser_from_args(args) - printer = pybind11_stubgen.Printer(invalid_expr_as_ellipses=not args.print_invalid_expressions_as_is) - - out_dir = pathlib.Path(args.output_dir) - out_dir.mkdir(exist_ok=True) - - if args.root_suffix is None: - sub_dir = None - else: - sub_dir = pathlib.Path(f"{args.module_name}{args.root_suffix}") - try: - run( - parser, - printer, - args.module_name, - out_dir, - sub_dir=sub_dir, - dry_run=args.dry_run, - ) - except BaseException as e: - logger.error(f"generator error -> {e}") - - -if __name__ == "__main__": - main() diff --git a/conda/yum_requirements.txt b/conda/yum_requirements.txt new file mode 100644 index 0000000..f307cf1 --- /dev/null +++ b/conda/yum_requirements.txt @@ -0,0 +1,6 @@ +mesa-libGL +mesa-dri-drivers +libselinux +libXdamage +libXxf86vm +libXext \ No newline at end of file diff --git a/environment.build.yml b/environment.build.yml index 6bf148b..11d7b91 100644 --- a/environment.build.yml +++ b/environment.build.yml @@ -2,17 +2,15 @@ name: ada-cpp channels: - conda-forge dependencies: + - python ==3.12 - occt ==7.7.2=*novtk* - - ifcopenshell - - nanobind ==1.8.0 - - pytest ==7.3.1 - - scikit-build-core ==0.7.1 - - cmake ==3.26.3 + - ifcopenshell ==0.8.0 + - nanobind ==2.1.0 + - pytest ==8.3.2 + - scikit-build-core ==0.10.5 + - cmake ==3.30.3 - numpy - - cgal-cpp ==5.6 - - nomkl + - cgal-cpp ==5.6.1 - cli11 - - boa ==0.16 - - tinygltf ==2.8.19 # This must be installed in target dir also if you want to compile + - tinygltf ==2.8.21 # This must be installed in target dir also if you want to compile - gmsh - - python ==3.11 \ No newline at end of file diff --git a/pixi.lock b/pixi.lock new file mode 100644 index 0000000..fb5d017 --- /dev/null +++ b/pixi.lock @@ -0,0 +1,960 @@ +version: 5 +environments: + default: + channels: + - url: https://conda.anaconda.org/conda-forge/ + packages: + linux-64: + - conda: https://conda.anaconda.org/conda-forge/linux-64/_libgcc_mutex-0.1-conda_forge.tar.bz2 + - conda: https://conda.anaconda.org/conda-forge/linux-64/_openmp_mutex-4.5-2_gnu.tar.bz2 + - conda: https://conda.anaconda.org/conda-forge/linux-64/bzip2-1.0.8-h4bc722e_7.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/ca-certificates-2024.8.30-hbcca054_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/ld_impl_linux-64-2.40-hf3520f5_7.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libexpat-2.6.2-h59595ed_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libffi-3.4.2-h7f98852_5.tar.bz2 + - conda: https://conda.anaconda.org/conda-forge/linux-64/libgcc-14.1.0-h77fa898_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libgcc-ng-14.1.0-h69a702a_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libgomp-14.1.0-h77fa898_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libnsl-2.0.1-hd590300_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libsqlite-3.46.1-hadc24fc_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libuuid-2.38.1-h0b41bf4_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libxcrypt-4.4.36-hd590300_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libzlib-1.3.1-h4ab18f5_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/ncurses-6.5-he02047a_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/openssl-3.3.2-hb9d3cd8_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/python-3.12.5-h2ad013b_0_cpython.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/readline-8.2-h8228510_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/tk-8.6.13-noxft_h4845f30_101.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/tzdata-2024a-h8827d51_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/xz-5.2.6-h166bdaf_0.tar.bz2 + win-64: + - conda: https://conda.anaconda.org/conda-forge/win-64/bzip2-1.0.8-h2466b09_7.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/ca-certificates-2024.8.30-h56e8100_0.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/libexpat-2.6.2-h63175ca_0.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/libffi-3.4.2-h8ffe710_5.tar.bz2 + - conda: https://conda.anaconda.org/conda-forge/win-64/libsqlite-3.46.1-h2466b09_0.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/libzlib-1.3.1-h2466b09_1.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/openssl-3.3.2-h2466b09_0.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/python-3.12.5-h889d299_0_cpython.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/tk-8.6.13-h5226925_1.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/tzdata-2024a-h8827d51_1.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/ucrt-10.0.22621.0-h57928b3_0.tar.bz2 + - conda: https://conda.anaconda.org/conda-forge/win-64/vc-14.3-h8a93ad2_20.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/vc14_runtime-14.40.33810-hcc2c482_20.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/vs2015_runtime-14.40.33810-h3bf8584_20.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/xz-5.2.6-h8d14728_0.tar.bz2 + lint: + channels: + - url: https://conda.anaconda.org/conda-forge/ + packages: + linux-64: + - conda: https://conda.anaconda.org/conda-forge/linux-64/_libgcc_mutex-0.1-conda_forge.tar.bz2 + - conda: https://conda.anaconda.org/conda-forge/linux-64/_openmp_mutex-4.5-2_gnu.tar.bz2 + - conda: https://conda.anaconda.org/conda-forge/linux-64/black-24.4.2-py312h7900ff3_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/bzip2-1.0.8-h4bc722e_7.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/ca-certificates-2024.8.30-hbcca054_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/click-8.1.7-unix_pyh707e725_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/isort-5.13.2-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/ld_impl_linux-64-2.40-hf3520f5_7.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libexpat-2.6.2-h59595ed_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libffi-3.4.2-h7f98852_5.tar.bz2 + - conda: https://conda.anaconda.org/conda-forge/linux-64/libgcc-14.1.0-h77fa898_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libgcc-ng-14.1.0-h69a702a_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libgomp-14.1.0-h77fa898_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libnsl-2.0.1-hd590300_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libsqlite-3.46.1-hadc24fc_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libstdcxx-14.1.0-hc0a3c3a_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libstdcxx-ng-14.1.0-h4852527_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libuuid-2.38.1-h0b41bf4_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libxcrypt-4.4.36-hd590300_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/libzlib-1.3.1-h4ab18f5_1.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/mypy_extensions-1.0.0-pyha770c72_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/ncurses-6.5-he02047a_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/openssl-3.3.2-hb9d3cd8_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/packaging-24.1-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/pathspec-0.12.1-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/platformdirs-4.2.2-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/python-3.12.5-h2ad013b_0_cpython.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/python_abi-3.12-5_cp312.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/readline-8.2-h8228510_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/ruff-0.4.10-py312h5715c7c_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/setuptools-73.0.1-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/tk-8.6.13-noxft_h4845f30_101.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/tzdata-2024a-h8827d51_1.conda + - conda: https://conda.anaconda.org/conda-forge/linux-64/xz-5.2.6-h166bdaf_0.tar.bz2 + win-64: + - conda: https://conda.anaconda.org/conda-forge/win-64/black-24.4.2-py312h2e8e312_0.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/bzip2-1.0.8-h2466b09_7.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/ca-certificates-2024.8.30-h56e8100_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/click-8.1.7-win_pyh7428d3b_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/colorama-0.4.6-pyhd8ed1ab_0.tar.bz2 + - conda: https://conda.anaconda.org/conda-forge/noarch/isort-5.13.2-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/libexpat-2.6.2-h63175ca_0.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/libffi-3.4.2-h8ffe710_5.tar.bz2 + - conda: https://conda.anaconda.org/conda-forge/win-64/libsqlite-3.46.1-h2466b09_0.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/libzlib-1.3.1-h2466b09_1.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/mypy_extensions-1.0.0-pyha770c72_0.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/openssl-3.3.2-h2466b09_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/packaging-24.1-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/pathspec-0.12.1-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/platformdirs-4.2.2-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/python-3.12.5-h889d299_0_cpython.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/python_abi-3.12-5_cp312.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/ruff-0.4.10-py312h7a6832a_0.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/setuptools-73.0.1-pyhd8ed1ab_0.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/tk-8.6.13-h5226925_1.conda + - conda: https://conda.anaconda.org/conda-forge/noarch/tzdata-2024a-h8827d51_1.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/ucrt-10.0.22621.0-h57928b3_0.tar.bz2 + - conda: https://conda.anaconda.org/conda-forge/win-64/vc-14.3-h8a93ad2_20.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/vc14_runtime-14.40.33810-hcc2c482_20.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/vs2015_runtime-14.40.33810-h3bf8584_20.conda + - conda: https://conda.anaconda.org/conda-forge/win-64/xz-5.2.6-h8d14728_0.tar.bz2 +packages: +- kind: conda + name: _libgcc_mutex + version: '0.1' + build: conda_forge + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/_libgcc_mutex-0.1-conda_forge.tar.bz2 + sha256: fe51de6107f9edc7aa4f786a70f4a883943bc9d39b3bb7307c04c41410990726 + md5: d7c89558ba9fa0495403155b64376d81 + license: None + size: 2562 + timestamp: 1578324546067 +- kind: conda + name: _openmp_mutex + version: '4.5' + build: 2_gnu + build_number: 16 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/_openmp_mutex-4.5-2_gnu.tar.bz2 + sha256: fbe2c5e56a653bebb982eda4876a9178aedfc2b545f25d0ce9c4c0b508253d22 + md5: 73aaf86a425cc6e73fcf236a5a46396d + depends: + - _libgcc_mutex 0.1 conda_forge + - libgomp >=7.5.0 + constrains: + - openmp_impl 9999 + license: BSD-3-Clause + license_family: BSD + size: 23621 + timestamp: 1650670423406 +- kind: conda + name: black + version: 24.4.2 + build: py312h2e8e312_0 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/black-24.4.2-py312h2e8e312_0.conda + sha256: e96b5277eee85982ab2a0d2811829d544a8df8a903578ce410f8105049d8daee + md5: 1c22d45c6d43af563cd39c597226922d + depends: + - click >=8.0.0 + - mypy_extensions >=0.4.3 + - packaging >=22.0 + - pathspec >=0.9 + - platformdirs >=2 + - python >=3.12,<3.13.0a0 + - python_abi 3.12.* *_cp312 + license: MIT + license_family: MIT + size: 407116 + timestamp: 1714120180643 +- kind: conda + name: black + version: 24.4.2 + build: py312h7900ff3_0 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/black-24.4.2-py312h7900ff3_0.conda + sha256: 02e36917e82adf0b2929b6fc35e60d7df224621c2d0b0c5ef819a4fb016e0742 + md5: 777e84c9bef7349c8cee65cffb11f7c4 + depends: + - click >=8.0.0 + - mypy_extensions >=0.4.3 + - packaging >=22.0 + - pathspec >=0.9 + - platformdirs >=2 + - python >=3.12,<3.13.0a0 + - python_abi 3.12.* *_cp312 + license: MIT + license_family: MIT + size: 387770 + timestamp: 1714119755759 +- kind: conda + name: bzip2 + version: 1.0.8 + build: h2466b09_7 + build_number: 7 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/bzip2-1.0.8-h2466b09_7.conda + sha256: 35a5dad92e88fdd7fc405e864ec239486f4f31eec229e31686e61a140a8e573b + md5: 276e7ffe9ffe39688abc665ef0f45596 + depends: + - ucrt >=10.0.20348.0 + - vc >=14.2,<15 + - vc14_runtime >=14.29.30139 + license: bzip2-1.0.6 + license_family: BSD + size: 54927 + timestamp: 1720974860185 +- kind: conda + name: bzip2 + version: 1.0.8 + build: h4bc722e_7 + build_number: 7 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/bzip2-1.0.8-h4bc722e_7.conda + sha256: 5ced96500d945fb286c9c838e54fa759aa04a7129c59800f0846b4335cee770d + md5: 62ee74e96c5ebb0af99386de58cf9553 + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc-ng >=12 + license: bzip2-1.0.6 + license_family: BSD + size: 252783 + timestamp: 1720974456583 +- kind: conda + name: ca-certificates + version: 2024.8.30 + build: h56e8100_0 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/ca-certificates-2024.8.30-h56e8100_0.conda + sha256: 0fcac3a7ffcc556649e034a1802aedf795e64227eaa7194d207b01eaf26454c4 + md5: 4c4fd67c18619be5aa65dc5b6c72e490 + license: ISC + size: 158773 + timestamp: 1725019107649 +- kind: conda + name: ca-certificates + version: 2024.8.30 + build: hbcca054_0 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/ca-certificates-2024.8.30-hbcca054_0.conda + sha256: afee721baa6d988e27fef1832f68d6f32ac8cc99cdf6015732224c2841a09cea + md5: c27d1c142233b5bc9ca570c6e2e0c244 + license: ISC + size: 159003 + timestamp: 1725018903918 +- kind: conda + name: click + version: 8.1.7 + build: unix_pyh707e725_0 + subdir: noarch + noarch: python + url: https://conda.anaconda.org/conda-forge/noarch/click-8.1.7-unix_pyh707e725_0.conda + sha256: f0016cbab6ac4138a429e28dbcb904a90305b34b3fe41a9b89d697c90401caec + md5: f3ad426304898027fc619827ff428eca + depends: + - __unix + - python >=3.8 + license: BSD-3-Clause + license_family: BSD + size: 84437 + timestamp: 1692311973840 +- kind: conda + name: click + version: 8.1.7 + build: win_pyh7428d3b_0 + subdir: noarch + noarch: python + url: https://conda.anaconda.org/conda-forge/noarch/click-8.1.7-win_pyh7428d3b_0.conda + sha256: 90236b113b9a20041736e80b80ee965167f9aac0468315c55e2bad902d673fb0 + md5: 3549ecbceb6cd77b91a105511b7d0786 + depends: + - __win + - colorama + - python >=3.8 + license: BSD-3-Clause + license_family: BSD + size: 85051 + timestamp: 1692312207348 +- kind: conda + name: colorama + version: 0.4.6 + build: pyhd8ed1ab_0 + subdir: noarch + noarch: python + url: https://conda.anaconda.org/conda-forge/noarch/colorama-0.4.6-pyhd8ed1ab_0.tar.bz2 + sha256: 2c1b2e9755ce3102bca8d69e8f26e4f087ece73f50418186aee7c74bef8e1698 + md5: 3faab06a954c2a04039983f2c4a50d99 + depends: + - python >=3.7 + license: BSD-3-Clause + license_family: BSD + size: 25170 + timestamp: 1666700778190 +- kind: conda + name: isort + version: 5.13.2 + build: pyhd8ed1ab_0 + subdir: noarch + noarch: python + url: https://conda.anaconda.org/conda-forge/noarch/isort-5.13.2-pyhd8ed1ab_0.conda + sha256: 78a7e2037029366d2149f73c8d02e93cac903d535e208cc4517808b0b42e85f2 + md5: 1d25ed2b95b92b026aaa795eabec8d91 + depends: + - python >=3.8,<4.0 + - setuptools + license: MIT + license_family: MIT + size: 73783 + timestamp: 1702518633821 +- kind: conda + name: ld_impl_linux-64 + version: '2.40' + build: hf3520f5_7 + build_number: 7 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/ld_impl_linux-64-2.40-hf3520f5_7.conda + sha256: 764b6950aceaaad0c67ef925417594dd14cd2e22fff864aeef455ac259263d15 + md5: b80f2f396ca2c28b8c14c437a4ed1e74 + constrains: + - binutils_impl_linux-64 2.40 + license: GPL-3.0-only + license_family: GPL + size: 707602 + timestamp: 1718625640445 +- kind: conda + name: libexpat + version: 2.6.2 + build: h59595ed_0 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libexpat-2.6.2-h59595ed_0.conda + sha256: 331bb7c7c05025343ebd79f86ae612b9e1e74d2687b8f3179faec234f986ce19 + md5: e7ba12deb7020dd080c6c70e7b6f6a3d + depends: + - libgcc-ng >=12 + constrains: + - expat 2.6.2.* + license: MIT + license_family: MIT + size: 73730 + timestamp: 1710362120304 +- kind: conda + name: libexpat + version: 2.6.2 + build: h63175ca_0 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/libexpat-2.6.2-h63175ca_0.conda + sha256: 79f612f75108f3e16bbdc127d4885bb74729cf66a8702fca0373dad89d40c4b7 + md5: bc592d03f62779511d392c175dcece64 + constrains: + - expat 2.6.2.* + license: MIT + license_family: MIT + size: 139224 + timestamp: 1710362609641 +- kind: conda + name: libffi + version: 3.4.2 + build: h7f98852_5 + build_number: 5 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libffi-3.4.2-h7f98852_5.tar.bz2 + sha256: ab6e9856c21709b7b517e940ae7028ae0737546122f83c2aa5d692860c3b149e + md5: d645c6d2ac96843a2bfaccd2d62b3ac3 + depends: + - libgcc-ng >=9.4.0 + license: MIT + license_family: MIT + size: 58292 + timestamp: 1636488182923 +- kind: conda + name: libffi + version: 3.4.2 + build: h8ffe710_5 + build_number: 5 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/libffi-3.4.2-h8ffe710_5.tar.bz2 + sha256: 1951ab740f80660e9bc07d2ed3aefb874d78c107264fd810f24a1a6211d4b1a5 + md5: 2c96d1b6915b408893f9472569dee135 + depends: + - vc >=14.1,<15.0a0 + - vs2015_runtime >=14.16.27012 + license: MIT + license_family: MIT + size: 42063 + timestamp: 1636489106777 +- kind: conda + name: libgcc + version: 14.1.0 + build: h77fa898_1 + build_number: 1 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-14.1.0-h77fa898_1.conda + sha256: 10fa74b69266a2be7b96db881e18fa62cfa03082b65231e8d652e897c4b335a3 + md5: 002ef4463dd1e2b44a94a4ace468f5d2 + depends: + - _libgcc_mutex 0.1 conda_forge + - _openmp_mutex >=4.5 + constrains: + - libgomp 14.1.0 h77fa898_1 + - libgcc-ng ==14.1.0=*_1 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + size: 846380 + timestamp: 1724801836552 +- kind: conda + name: libgcc-ng + version: 14.1.0 + build: h69a702a_1 + build_number: 1 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libgcc-ng-14.1.0-h69a702a_1.conda + sha256: b91f7021e14c3d5c840fbf0dc75370d6e1f7c7ff4482220940eaafb9c64613b7 + md5: 1efc0ad219877a73ef977af7dbb51f17 + depends: + - libgcc 14.1.0 h77fa898_1 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + size: 52170 + timestamp: 1724801842101 +- kind: conda + name: libgomp + version: 14.1.0 + build: h77fa898_1 + build_number: 1 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libgomp-14.1.0-h77fa898_1.conda + sha256: c96724c8ae4ee61af7674c5d9e5a3fbcf6cd887a40ad5a52c99aa36f1d4f9680 + md5: 23c255b008c4f2ae008f81edcabaca89 + depends: + - _libgcc_mutex 0.1 conda_forge + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + size: 460218 + timestamp: 1724801743478 +- kind: conda + name: libnsl + version: 2.0.1 + build: hd590300_0 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libnsl-2.0.1-hd590300_0.conda + sha256: 26d77a3bb4dceeedc2a41bd688564fe71bf2d149fdcf117049970bc02ff1add6 + md5: 30fd6e37fe21f86f4bd26d6ee73eeec7 + depends: + - libgcc-ng >=12 + license: LGPL-2.1-only + license_family: GPL + size: 33408 + timestamp: 1697359010159 +- kind: conda + name: libsqlite + version: 3.46.1 + build: h2466b09_0 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/libsqlite-3.46.1-h2466b09_0.conda + sha256: ef83f90961630bc54a95e48062b05cf9c9173a822ea01784288029613a45eea4 + md5: 8a7c1ad01f58623bfbae8d601db7cf3b + depends: + - ucrt >=10.0.20348.0 + - vc >=14.2,<15 + - vc14_runtime >=14.29.30139 + license: Unlicense + size: 876666 + timestamp: 1725354171439 +- kind: conda + name: libsqlite + version: 3.46.1 + build: hadc24fc_0 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libsqlite-3.46.1-hadc24fc_0.conda + sha256: 9851c049abafed3ee329d6c7c2033407e2fc269d33a75c071110ab52300002b0 + md5: 36f79405ab16bf271edb55b213836dac + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc >=13 + - libzlib >=1.3.1,<2.0a0 + license: Unlicense + size: 865214 + timestamp: 1725353659783 +- kind: conda + name: libstdcxx + version: 14.1.0 + build: hc0a3c3a_1 + build_number: 1 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libstdcxx-14.1.0-hc0a3c3a_1.conda + sha256: 44decb3d23abacf1c6dd59f3c152a7101b7ca565b4ef8872804ceaedcc53a9cd + md5: 9dbb9699ea467983ba8a4ba89b08b066 + depends: + - libgcc 14.1.0 h77fa898_1 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + size: 3892781 + timestamp: 1724801863728 +- kind: conda + name: libstdcxx-ng + version: 14.1.0 + build: h4852527_1 + build_number: 1 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libstdcxx-ng-14.1.0-h4852527_1.conda + sha256: a2dc44f97290740cc187bfe94ce543e6eb3c2ea8964d99f189a1d8c97b419b8c + md5: bd2598399a70bb86d8218e95548d735e + depends: + - libstdcxx 14.1.0 hc0a3c3a_1 + license: GPL-3.0-only WITH GCC-exception-3.1 + license_family: GPL + size: 52219 + timestamp: 1724801897766 +- kind: conda + name: libuuid + version: 2.38.1 + build: h0b41bf4_0 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libuuid-2.38.1-h0b41bf4_0.conda + sha256: 787eb542f055a2b3de553614b25f09eefb0a0931b0c87dbcce6efdfd92f04f18 + md5: 40b61aab5c7ba9ff276c41cfffe6b80b + depends: + - libgcc-ng >=12 + license: BSD-3-Clause + license_family: BSD + size: 33601 + timestamp: 1680112270483 +- kind: conda + name: libxcrypt + version: 4.4.36 + build: hd590300_1 + build_number: 1 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libxcrypt-4.4.36-hd590300_1.conda + sha256: 6ae68e0b86423ef188196fff6207ed0c8195dd84273cb5623b85aa08033a410c + md5: 5aa797f8787fe7a17d1b0821485b5adc + depends: + - libgcc-ng >=12 + license: LGPL-2.1-or-later + size: 100393 + timestamp: 1702724383534 +- kind: conda + name: libzlib + version: 1.3.1 + build: h2466b09_1 + build_number: 1 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/libzlib-1.3.1-h2466b09_1.conda + sha256: b13846a54a15243e15f96fec06b526d8155adc6a1ac2b6ed47a88f6a71a94b68 + md5: d4483ca8afc57ddf1f6dded53b36c17f + depends: + - ucrt >=10.0.20348.0 + - vc >=14.2,<15 + - vc14_runtime >=14.29.30139 + constrains: + - zlib 1.3.1 *_1 + license: Zlib + license_family: Other + size: 56186 + timestamp: 1716874730539 +- kind: conda + name: libzlib + version: 1.3.1 + build: h4ab18f5_1 + build_number: 1 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/libzlib-1.3.1-h4ab18f5_1.conda + sha256: adf6096f98b537a11ae3729eaa642b0811478f0ea0402ca67b5108fe2cb0010d + md5: 57d7dc60e9325e3de37ff8dffd18e814 + depends: + - libgcc-ng >=12 + constrains: + - zlib 1.3.1 *_1 + license: Zlib + license_family: Other + size: 61574 + timestamp: 1716874187109 +- kind: conda + name: mypy_extensions + version: 1.0.0 + build: pyha770c72_0 + subdir: noarch + noarch: python + url: https://conda.anaconda.org/conda-forge/noarch/mypy_extensions-1.0.0-pyha770c72_0.conda + sha256: f240217476e148e825420c6bc3a0c0efb08c0718b7042fae960400c02af858a3 + md5: 4eccaeba205f0aed9ac3a9ea58568ca3 + depends: + - python >=3.5 + license: MIT + license_family: MIT + size: 10492 + timestamp: 1675543414256 +- kind: conda + name: ncurses + version: '6.5' + build: he02047a_1 + build_number: 1 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/ncurses-6.5-he02047a_1.conda + sha256: 6a1d5d8634c1a07913f1c525db6455918cbc589d745fac46d9d6e30340c8731a + md5: 70caf8bb6cf39a0b6b7efc885f51c0fe + depends: + - __glibc >=2.17,<3.0.a0 + - libgcc-ng >=12 + license: X11 AND BSD-3-Clause + size: 889086 + timestamp: 1724658547447 +- kind: conda + name: openssl + version: 3.3.2 + build: h2466b09_0 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/openssl-3.3.2-h2466b09_0.conda + sha256: a45c42f3577294e22ac39ddb6ef5a64fd5322e8a6725afefbf4f2b4109340bf9 + md5: 1dc86753693df5e3326bb8a85b74c589 + depends: + - ca-certificates + - ucrt >=10.0.20348.0 + - vc >=14.2,<15 + - vc14_runtime >=14.29.30139 + license: Apache-2.0 + license_family: Apache + size: 8396053 + timestamp: 1725412961673 +- kind: conda + name: openssl + version: 3.3.2 + build: hb9d3cd8_0 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/openssl-3.3.2-hb9d3cd8_0.conda + sha256: cee91036686419f6dd6086902acf7142b4916e1c4ba042e9ca23e151da012b6d + md5: 4d638782050ab6faa27275bed57e9b4e + depends: + - __glibc >=2.17,<3.0.a0 + - ca-certificates + - libgcc >=13 + license: Apache-2.0 + license_family: Apache + size: 2891789 + timestamp: 1725410790053 +- kind: conda + name: packaging + version: '24.1' + build: pyhd8ed1ab_0 + subdir: noarch + noarch: python + url: https://conda.anaconda.org/conda-forge/noarch/packaging-24.1-pyhd8ed1ab_0.conda + sha256: 36aca948219e2c9fdd6d80728bcc657519e02f06c2703d8db3446aec67f51d81 + md5: cbe1bb1f21567018ce595d9c2be0f0db + depends: + - python >=3.8 + license: Apache-2.0 + license_family: APACHE + size: 50290 + timestamp: 1718189540074 +- kind: conda + name: pathspec + version: 0.12.1 + build: pyhd8ed1ab_0 + subdir: noarch + noarch: python + url: https://conda.anaconda.org/conda-forge/noarch/pathspec-0.12.1-pyhd8ed1ab_0.conda + sha256: 4e534e66bfe8b1e035d2169d0e5b185450546b17e36764272863e22e0370be4d + md5: 17064acba08d3686f1135b5ec1b32b12 + depends: + - python >=3.7 + license: MPL-2.0 + license_family: MOZILLA + size: 41173 + timestamp: 1702250135032 +- kind: conda + name: platformdirs + version: 4.2.2 + build: pyhd8ed1ab_0 + subdir: noarch + noarch: python + url: https://conda.anaconda.org/conda-forge/noarch/platformdirs-4.2.2-pyhd8ed1ab_0.conda + sha256: adc59384cf0b2fc6dc7362840151e8cb076349197a38f7230278252698a88442 + md5: 6f6cf28bf8e021933869bae3f84b8fc9 + depends: + - python >=3.8 + license: MIT + license_family: MIT + size: 20572 + timestamp: 1715777739019 +- kind: conda + name: python + version: 3.12.5 + build: h2ad013b_0_cpython + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/python-3.12.5-h2ad013b_0_cpython.conda + sha256: e2aad83838988725d4ffba4e9717b9328054fd18a668cff3377e0c50f109e8bd + md5: 9c56c4df45f6571b13111d8df2448692 + depends: + - __glibc >=2.17,<3.0.a0 + - bzip2 >=1.0.8,<2.0a0 + - ld_impl_linux-64 >=2.36.1 + - libexpat >=2.6.2,<3.0a0 + - libffi >=3.4,<4.0a0 + - libgcc-ng >=12 + - libnsl >=2.0.1,<2.1.0a0 + - libsqlite >=3.46.0,<4.0a0 + - libuuid >=2.38.1,<3.0a0 + - libxcrypt >=4.4.36 + - libzlib >=1.3.1,<2.0a0 + - ncurses >=6.5,<7.0a0 + - openssl >=3.3.1,<4.0a0 + - readline >=8.2,<9.0a0 + - tk >=8.6.13,<8.7.0a0 + - tzdata + - xz >=5.2.6,<6.0a0 + constrains: + - python_abi 3.12.* *_cp312 + license: Python-2.0 + size: 31663253 + timestamp: 1723143721353 +- kind: conda + name: python + version: 3.12.5 + build: h889d299_0_cpython + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/python-3.12.5-h889d299_0_cpython.conda + sha256: 4cef304eb8877fd3094c14b57097ccc1b817b4afbf2223dd45d2b61e44064740 + md5: db056d8b140ab2edd56a2f9bdb203dcd + depends: + - bzip2 >=1.0.8,<2.0a0 + - libexpat >=2.6.2,<3.0a0 + - libffi >=3.4,<4.0a0 + - libsqlite >=3.46.0,<4.0a0 + - libzlib >=1.3.1,<2.0a0 + - openssl >=3.3.1,<4.0a0 + - tk >=8.6.13,<8.7.0a0 + - tzdata + - ucrt >=10.0.20348.0 + - vc >=14.2,<15 + - vc14_runtime >=14.29.30139 + - xz >=5.2.6,<6.0a0 + constrains: + - python_abi 3.12.* *_cp312 + license: Python-2.0 + size: 15897752 + timestamp: 1723141830317 +- kind: conda + name: python_abi + version: '3.12' + build: 5_cp312 + build_number: 5 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/python_abi-3.12-5_cp312.conda + sha256: d10e93d759931ffb6372b45d65ff34d95c6000c61a07e298d162a3bc2accebb0 + md5: 0424ae29b104430108f5218a66db7260 + constrains: + - python 3.12.* *_cpython + license: BSD-3-Clause + license_family: BSD + size: 6238 + timestamp: 1723823388266 +- kind: conda + name: python_abi + version: '3.12' + build: 5_cp312 + build_number: 5 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/python_abi-3.12-5_cp312.conda + sha256: 9486662af81a219e96d343449eff242f38d7c5128ced5ce5acf85857265058d6 + md5: e8681f534453af7afab4cd2bc1423eec + constrains: + - python 3.12.* *_cpython + license: BSD-3-Clause + license_family: BSD + size: 6730 + timestamp: 1723823139725 +- kind: conda + name: readline + version: '8.2' + build: h8228510_1 + build_number: 1 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/readline-8.2-h8228510_1.conda + sha256: 5435cf39d039387fbdc977b0a762357ea909a7694d9528ab40f005e9208744d7 + md5: 47d31b792659ce70f470b5c82fdfb7a4 + depends: + - libgcc-ng >=12 + - ncurses >=6.3,<7.0a0 + license: GPL-3.0-only + license_family: GPL + size: 281456 + timestamp: 1679532220005 +- kind: conda + name: ruff + version: 0.4.10 + build: py312h5715c7c_0 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/ruff-0.4.10-py312h5715c7c_0.conda + sha256: d7f056febfb41a141f51e0ae7ea8ba28bc486a86556f378598280b97c5761d2d + md5: 3d07021d1d84de1caf6dbc02e5aea12a + depends: + - libgcc-ng >=12 + - libstdcxx-ng >=12 + - python >=3.12,<3.13.0a0 + - python_abi 3.12.* *_cp312 + license: MIT + license_family: MIT + size: 6375100 + timestamp: 1718950300298 +- kind: conda + name: ruff + version: 0.4.10 + build: py312h7a6832a_0 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/ruff-0.4.10-py312h7a6832a_0.conda + sha256: fa69621a30c533349cc110bd1d2956189d92c11c15bc1a6520ed0a82b4f8f900 + md5: 858969a5841ede4dbeb9f929962cd606 + depends: + - python >=3.12,<3.13.0a0 + - python_abi 3.12.* *_cp312 + - ucrt >=10.0.20348.0 + - vc >=14.2,<15 + - vc14_runtime >=14.29.30139 + license: MIT + license_family: MIT + size: 6273796 + timestamp: 1718951278593 +- kind: conda + name: setuptools + version: 73.0.1 + build: pyhd8ed1ab_0 + subdir: noarch + noarch: python + url: https://conda.anaconda.org/conda-forge/noarch/setuptools-73.0.1-pyhd8ed1ab_0.conda + sha256: c9f5e110e3fe5a7c4cd5b9da445c05a1fae000b43ab3a97cb6a501f4267515fc + md5: f0b618d7673d1b2464f600b34d912f6f + depends: + - python >=3.8 + license: MIT + license_family: MIT + size: 1460460 + timestamp: 1725348602179 +- kind: conda + name: tk + version: 8.6.13 + build: h5226925_1 + build_number: 1 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/tk-8.6.13-h5226925_1.conda + sha256: 2c4e914f521ccb2718946645108c9bd3fc3216ba69aea20c2c3cedbd8db32bb1 + md5: fc048363eb8f03cd1737600a5d08aafe + depends: + - ucrt >=10.0.20348.0 + - vc >=14.2,<15 + - vc14_runtime >=14.29.30139 + license: TCL + license_family: BSD + size: 3503410 + timestamp: 1699202577803 +- kind: conda + name: tk + version: 8.6.13 + build: noxft_h4845f30_101 + build_number: 101 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/tk-8.6.13-noxft_h4845f30_101.conda + sha256: e0569c9caa68bf476bead1bed3d79650bb080b532c64a4af7d8ca286c08dea4e + md5: d453b98d9c83e71da0741bb0ff4d76bc + depends: + - libgcc-ng >=12 + - libzlib >=1.2.13,<2.0.0a0 + license: TCL + license_family: BSD + size: 3318875 + timestamp: 1699202167581 +- kind: conda + name: tzdata + version: 2024a + build: h8827d51_1 + build_number: 1 + subdir: noarch + noarch: generic + url: https://conda.anaconda.org/conda-forge/noarch/tzdata-2024a-h8827d51_1.conda + sha256: 7d21c95f61319dba9209ca17d1935e6128af4235a67ee4e57a00908a1450081e + md5: 8bfdead4e0fff0383ae4c9c50d0531bd + license: LicenseRef-Public-Domain + size: 124164 + timestamp: 1724736371498 +- kind: conda + name: ucrt + version: 10.0.22621.0 + build: h57928b3_0 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/ucrt-10.0.22621.0-h57928b3_0.tar.bz2 + sha256: f29cdaf8712008f6b419b8b1a403923b00ab2504bfe0fb2ba8eb60e72d4f14c6 + md5: 72608f6cd3e5898229c3ea16deb1ac43 + constrains: + - vs2015_runtime >=14.29.30037 + license: LicenseRef-Proprietary + license_family: PROPRIETARY + size: 1283972 + timestamp: 1666630199266 +- kind: conda + name: vc + version: '14.3' + build: h8a93ad2_20 + build_number: 20 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/vc-14.3-h8a93ad2_20.conda + sha256: 23ac5feb15a9adf3ab2b8c4dcd63650f8b7ae860c5ceb073e49cf71d203eddef + md5: 8558f367e1d7700554f7cdb823c46faf + depends: + - vc14_runtime >=14.40.33810 + track_features: + - vc14 + license: BSD-3-Clause + license_family: BSD + size: 17391 + timestamp: 1717709040616 +- kind: conda + name: vc14_runtime + version: 14.40.33810 + build: hcc2c482_20 + build_number: 20 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/vc14_runtime-14.40.33810-hcc2c482_20.conda + sha256: bba8daa6f78b26b48fb7e1377eb52160e25495710bf53146c5f405bd50565982 + md5: ad33c7cd933d69b9dee0f48317cdf137 + depends: + - ucrt >=10.0.20348.0 + constrains: + - vs2015_runtime 14.40.33810.* *_20 + license: LicenseRef-ProprietaryMicrosoft + license_family: Proprietary + size: 751028 + timestamp: 1724712684919 +- kind: conda + name: vs2015_runtime + version: 14.40.33810 + build: h3bf8584_20 + build_number: 20 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/vs2015_runtime-14.40.33810-h3bf8584_20.conda + sha256: 0c2803f7a788c51f28235a7228dc2ab3f107b4b16ab0845a3e595c8c51e50a7a + md5: c21f1b4a3a30bbc3ef35a50957578e0e + depends: + - vc14_runtime >=14.40.33810 + license: BSD-3-Clause + license_family: BSD + size: 17395 + timestamp: 1717709043353 +- kind: conda + name: xz + version: 5.2.6 + build: h166bdaf_0 + subdir: linux-64 + url: https://conda.anaconda.org/conda-forge/linux-64/xz-5.2.6-h166bdaf_0.tar.bz2 + sha256: 03a6d28ded42af8a347345f82f3eebdd6807a08526d47899a42d62d319609162 + md5: 2161070d867d1b1204ea749c8eec4ef0 + depends: + - libgcc-ng >=12 + license: LGPL-2.1 and GPL-2.0 + size: 418368 + timestamp: 1660346797927 +- kind: conda + name: xz + version: 5.2.6 + build: h8d14728_0 + subdir: win-64 + url: https://conda.anaconda.org/conda-forge/win-64/xz-5.2.6-h8d14728_0.tar.bz2 + sha256: 54d9778f75a02723784dc63aff4126ff6e6749ba21d11a6d03c1f4775f269fe0 + md5: 515d77642eaa3639413c6b1bc3f94219 + depends: + - vc >=14.1,<15 + - vs2015_runtime >=14.16.27033 + license: LGPL-2.1 and GPL-2.0 + size: 217804 + timestamp: 1660346976440 diff --git a/pyproject.toml b/pyproject.toml index a6014b1..57bb550 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,8 +51,27 @@ line-length = 120 [tool.ruff] line-length = 120 +exclude = ["examples/", ".pixi/", "temp/"] + +[tool.ruff.lint] ignore = ["E741"] -exclude = ["examples/experiments/"] + [tool.isort] -profile = "black" \ No newline at end of file +profile = "black" +skip = [".pixi", "node_modules", "temp"] +skip_glob=["**/node_modules/**", "**/temp/**"] + +[tool.pixi.project] +channels = ["conda-forge"] +platforms = ["win-64", "linux-64"] + +[tool.pixi.environments] +lint = { features = ["lint"], no-default-feature = true} +[tool.pixi.feature.lint.dependencies] +black = "24.4.2" +isort = "5.13.2" +ruff = "0.4.10" + +[tool.pixi.feature.lint.tasks] +lint = "isort . && black . --config pyproject.toml && ruff check ." \ No newline at end of file diff --git a/src/adacpp/cadit/__init__.py b/src/adacpp/cadit/__init__.py index 8b1deeb..f780730 100644 --- a/src/adacpp/cadit/__init__.py +++ b/src/adacpp/cadit/__init__.py @@ -1,4 +1,6 @@ from adacpp._ada_cpp_ext_impl.cadit import ( + STEPCAFControl_Writer, + step_writer_to_string, write_box_to_step, write_boxes_to_gltf, write_boxes_to_step, @@ -12,7 +14,9 @@ write_boxes_to_gltf, write_mesh_to_gltf, write_boxes_to_step, + step_writer_to_string, occt, ifc, conversion, + STEPCAFControl_Writer, ] diff --git a/src/cadit/ifc/ifcop.cpp b/src/cadit/ifc/ifcop.cpp index d6b2bad..9ca9cf7 100644 --- a/src/cadit/ifc/ifcop.cpp +++ b/src/cadit/ifc/ifcop.cpp @@ -23,9 +23,13 @@ int read_ifc_file(const std::string &file_name) { std::cout << "Found " << elements->size() << " elements in " << file_name << ":" << std::endl; + std::ostringstream oss; for (auto element : *elements) { - - std::cout << element->data().toString() << std::endl; + element->data().toString(oss); + oss << "\n"; + std::cout << oss.str(); + oss.str(""); // Clear the contents of the stringstream + oss.clear(); // Reset any error flags } return 0; diff --git a/src/cadit/occt/step_writer.cpp b/src/cadit/occt/step_writer.cpp index ae70fd3..5f7b1e0 100644 --- a/src/cadit/occt/step_writer.cpp +++ b/src/cadit/occt/step_writer.cpp @@ -1,4 +1,5 @@ #include +#include #include #include @@ -15,7 +16,7 @@ #include #include "../../binding_core.h" #include "../../helpers/helpers.h" - +#include class AdaCPPStepWriter { @@ -113,9 +114,31 @@ void write_box_to_step(const std::string &filename, const std::vector &bo writer.Write(filename.c_str()); } +std::string step_writer_to_string(STEPCAFControl_Writer& writer) { + std::ostringstream stream; + writer.WriteStream(stream); // Write to the string stream + return stream.str(); // Convert the stream to a string and return it +} + void step_writer_module(nb::module_ &m) { m.def("write_box_to_step", &write_box_to_step, "filename"_a, "box_origin"_a, "box_dims"_a, "Write a box to a step file"); m.def("write_boxes_to_step", &write_boxes_to_step, "filename"_a, "box_origins"_a, "box_dims"_a, "Write a list of boxes to a step file"); + m.def("step_writer_to_string", &step_writer_to_string, "writer"_a); + + nanobind::class_(m, "STEPCAFControl_Writer") + .def_static("from_ptr", [](uintptr_t ptr) { + // Return a shared_ptr to manage the lifetime of the object + return std::shared_ptr( + reinterpret_cast(ptr), + [](STEPCAFControl_Writer *p) { + // Custom deleter (can be empty if you want to avoid deletion) + // But in most cases, deleting the object should be safe if it’s properly managed + // delete p; + // Chose to not delete because this object will always grab the ptr from an existing + // swig object and should not be responsible for deleting it + } + ); + }); } \ No newline at end of file diff --git a/tests/py/test_ada_integration.py b/tests/py/test_ada_integration.py new file mode 100644 index 0000000..1e41296 --- /dev/null +++ b/tests/py/test_ada_integration.py @@ -0,0 +1,48 @@ + +import OCC.Core.Interface as OCCInterface +import pytest +from OCC.Core.STEPCAFControl import STEPCAFControl_Writer as OCC_STEPCAFControl_Writer +from OCC.Core.STEPControl import STEPControl_AsIs +from OCC.Core.XSControl import XSControl_WorkSession + +from adacpp.cadit import STEPCAFControl_Writer, step_writer_to_string + +try: + import ada + from ada.occ.store import OCCStore + + has_ada = True +except ModuleNotFoundError: + has_ada = False + + +@pytest.fixture +def beams_model(): + beams = [] + for i in range(0, 5): + bm = ada.Beam(f"bm{i}", (i, 0, 0), (i + 1, 0, 0), "IPE300") + beams.append(bm) + return ada.Assembly() / beams + + +@pytest.mark.skipif(not has_ada, reason="ada is not installed") +def test_ada_integration(beams_model): + step_writer = OCCStore.get_step_writer() + shape_iter = OCCStore.shape_iterator(beams_model) + for i, (obj, shape) in enumerate(shape_iter, start=1): + step_writer.add_shape(shape, obj.name, rgb_color=obj.color.rgb) + + session = XSControl_WorkSession() + SetCVal = OCCInterface.Interface_Static.SetCVal + SetCVal("write.step.unit", step_writer.units.value.upper()) + SetCVal("write.step.schema", step_writer.schema.value.upper()) + + writer = OCC_STEPCAFControl_Writer(session, False) + writer.SetColorMode(True) + writer.SetNameMode(True) + writer.Transfer(step_writer.doc, STEPControl_AsIs) + + writer_pointer = int(writer.this) + ada_cpp_writer = STEPCAFControl_Writer.from_ptr(writer_pointer) + result = step_writer_to_string(ada_cpp_writer) + assert len(result) == 227399 diff --git a/tests/py/test_basic.py b/tests/py/test_basic.py index 2d4851b..587d7ba 100644 --- a/tests/py/test_basic.py +++ b/tests/py/test_basic.py @@ -21,40 +21,42 @@ def create_box_grid(grid_size): return origins, dimensions -def test_basic_write_step(): - adacpp.cadit.write_box_to_step("mybox.stp", (0, 0, 0), (10, 10, 10)) +def test_basic_write_step(tmp_path): + adacpp.cadit.write_box_to_step(str(tmp_path / "mybox.stp"), (0, 0, 0), (10, 10, 10)) -def test_convert_step_to_glb(files_dir): - adacpp.cadit.conversion.stp_to_glb(str(files_dir / "flat_plate_abaqus_10x10_m_wColors.stp"), - str("temp/flat_plate_abaqus_10x10_m_wColors.glb")) +def test_convert_step_to_glb(files_dir, tmp_path): + adacpp.cadit.conversion.stp_to_glb( + str(files_dir / "flat_plate_abaqus_10x10_m_wColors.stp"), + str(tmp_path / "flat_plate_abaqus_10x10_m_wColors.glb"), + ) -def test_basic_write_list_of_boxes_to_step(): +def test_basic_write_list_of_boxes_to_step(tmp_path): origins, dimensions = create_box_grid(10) - adacpp.cadit.write_boxes_to_step("myboxes.stp", origins, dimensions) + adacpp.cadit.write_boxes_to_step(str(tmp_path / "myboxes.stp"), origins, dimensions) - adacpp.cadit.conversion.stp_to_glb("myboxes.stp", "myboxes_convert.glb") + adacpp.cadit.conversion.stp_to_glb(str(tmp_path / "myboxes.stp"), str(tmp_path / "myboxes_convert.glb")) -def test_basic_mesh(): +def test_basic_mesh(tmp_path): mesh = adacpp.visit.get_box_mesh((0, 0, 0), (10, 10, 10)) assert mesh.__class__.__name__ == "Mesh" assert hasattr(mesh, "positions") assert hasattr(mesh, "normals") assert hasattr(mesh, "indices") - adacpp.cadit.write_mesh_to_gltf("mybox.gltf", mesh) + adacpp.cadit.write_mesh_to_gltf(str(tmp_path / "mybox.gltf"), mesh) print(mesh) -def test_boxes_mesh_gltf(): +def test_boxes_mesh_gltf(tmp_path): origins, dimensions = create_box_grid(10) - adacpp.cadit.write_boxes_to_gltf("myboxes.glb", origins, dimensions) + adacpp.cadit.write_boxes_to_gltf(str(tmp_path / "myboxes.glb"), origins, dimensions) -def test_simple_gmsh(): - adacpp.fem.create_gmesh("my_fem_mesh.msh") +def test_simple_gmsh(tmp_path): + adacpp.fem.create_gmesh(str(tmp_path / "my_fem_mesh.msh")) def test_tess_factory():