diff --git a/.bazelrc b/.bazelrc index 9f494eb..c776487 100644 --- a/.bazelrc +++ b/.bazelrc @@ -11,4 +11,3 @@ run --macos_minimum_os=10.12 test --macos_minimum_os=10.12 # FIXME: Temporary workaround for pyo3 stubgen issues. See ticket #45 -build --@rules_rust_pyo3//settings:experimental_stubgen=False diff --git a/.github/workflows/_python.yaml b/.github/workflows/_python.yaml index 3910ca2..fb98223 100644 --- a/.github/workflows/_python.yaml +++ b/.github/workflows/_python.yaml @@ -12,59 +12,76 @@ jobs: # ---------------------------------------------------------------------------- python-build-wheels: - name: Build wheels on ${{ matrix.platform.os }} (${{ matrix.platform.target }}) + name: Build wheels on ${{ matrix.platform.runner }} runs-on: ${{ matrix.platform.runner }} strategy: fail-fast: false matrix: platform: - # Linux + - { runner: ubuntu-latest, artifact: linux-x86_64 } + - { runner: macos-14, artifact: macos-arm64 } + - { runner: windows-latest, artifact: windows-x86_64 } + python: - { - os: linux, - runner: ubuntu-latest, - target: x86_64-unknown-linux-gnu, - } # x86 64-bit + version: "3.10", + target: wheel_cp310, + tag: cp310, + dist: dist_cp310, + } - { - os: linux, - runner: ubuntu-latest, - target: aarch64-unknown-linux-gnu, - } # Arm 64-bit - - { - os: linux, - runner: ubuntu-latest, - target: armv7-unknown-linux-gnueabihf, - } # Arm 32-bit - # macOS - - { os: macos, runner: macos-latest, target: universal2-apple-darwin } # MacOS Universal - # Windows - - { - os: windows, - runner: windows-latest, - target: x86_64-pc-windows-msvc, - } # x86 64-bit + version: "3.11", + target: wheel_cp311, + tag: cp311, + dist: dist_cp311, + } + - { version: "3.12+", target: wheel_abi3, tag: abi3, dist: dist_abi3 } + env: + CI: true + BAZELISK_ALLOW_ENVS: Y steps: - name: Checkout repository uses: actions/checkout@v4 with: fetch-depth: 0 - - name: Setup Python - uses: actions/setup-python@v4 + - name: Cache Bazel + uses: actions/cache@v4 with: - python-version: "3.12" + path: | + ~/.cache/bazel + C:\bzl + key: bazel-${{ runner.os }} + restore-keys: bazel-${{ runner.os }} + + - name: Build wheels (Unix) + if: runner.os != 'Windows' + shell: bash + env: + MSYS2_ARG_CONV_EXCL: "*" + run: | + bazel build //python:${{ matrix.python.target }}.dist + BAZEL_BIN="$(bazel info bazel-bin)" + mkdir -p dist + cp "${BAZEL_BIN}/python/${{ matrix.python.dist }}/"*.whl dist/ + + - name: Build wheels (Windows) + if: runner.os == 'Windows' + shell: pwsh + run: | + $ErrorActionPreference = 'Stop' + $bazelArgs = @("--output_user_root=C:/bzl") + bazel @bazelArgs build //python:${{ matrix.python.target }}.dist + if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE } + $bazelBin = bazel @bazelArgs info bazel-bin + if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE } + New-Item -ItemType Directory -Force -Path dist | Out-Null + Copy-Item "$bazelBin/python/${{ matrix.python.dist }}/*.whl" dist/ - - name: Build wheels - uses: PyO3/maturin-action@v1 - with: - working-directory: python - target: ${{ matrix.platform.target }} - args: --release --strip --out dist --compatibility pypi - manylinux: ${{ matrix.platform.os == 'linux' && 'auto' || null }} - name: Upload wheels uses: actions/upload-artifact@v4 with: - name: wheels-${{ matrix.platform.os }}-${{ matrix.platform.target }} - path: python/dist/*.whl + name: wheels-${{ matrix.platform.artifact }}-${{ matrix.python.tag }} + path: dist/*.whl # ---------------------------------------------------------------------------- # Test Python Bindings @@ -74,6 +91,14 @@ jobs: name: Test Python Bindings runs-on: ubuntu-latest needs: python-build-wheels + strategy: + fail-fast: false + matrix: + python: + - { version: "3.10", tag: cp310 } + - { version: "3.11", tag: cp311 } + - { version: "3.12", tag: abi3 } + - { version: "3.13", tag: abi3 } env: CI: true BAZELISK_ALLOW_ENVS: Y @@ -90,6 +115,23 @@ jobs: key: bazel-${{ runner.os }} restore-keys: bazel-${{ runner.os }} + - name: Setup Python ${{ matrix.python.version }} + uses: actions/setup-python@v5 + with: + python-version: ${{ matrix.python.version }} + + - name: Download Linux wheel + uses: actions/download-artifact@v4 + with: + name: wheels-linux-x86_64-${{ matrix.python.tag }} + path: dist/ + + - name: Smoke test built wheel + run: | + python -m pip install --upgrade pip + python -m pip install dist/*.whl + python -c "import dv_py; value = dv_py.DimensionalVariable(10, 'm').value(); print(value)" + - name: Test Python Bindings run: bazel test //python/... --test_output=errors --keep_going diff --git a/.gitignore b/.gitignore index 7575804..1039c7d 100644 --- a/.gitignore +++ b/.gitignore @@ -18,6 +18,7 @@ __pycache__/ # CMake Build Directories build/ +build-*/ # VSCode Settings -.vscode/ \ No newline at end of file +.vscode/ diff --git a/AGENTS.md b/AGENTS.md index 2d8c3a6..e05357e 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -93,9 +93,9 @@ This project is a library in multiple languages for handling units and checking - Raise and assert `DVError` for invalid operations. ### C/C++ (bindings) -- Headers live in `cpp/include`: - - `dv_c.h` for C API - - `dv.hpp` for C++ RAII wrapper +- The Rust Diplomat bridge lives under `core/ffi/diplomat`. +- Bazel-facing generated bindings live in the language directories: `c/`, `cpp/`, and `python/`. +- `cpp/include/dv.hpp` is a thin compatibility wrapper over the generated Diplomat C++ bindings. - CMake support is minimal; prefer Bazel for consistency. ### Docs (Docusaurus) diff --git a/CMakeLists.txt b/CMakeLists.txt index 52202c4..4d18a6c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,52 +1,89 @@ cmake_minimum_required(VERSION 3.20) project(dv LANGUAGES C CXX) -# Options -option(DV_BUILD_SHARED "Build shared library" ON) - -# Build Rust C-ABI via Cargo. We use ExternalProject for portability. include(ExternalProject) -set(DV_RUST_DIR ${CMAKE_CURRENT_LIST_DIR}/cpp/capi) -set(DV_BUILD_CMD cargo build --manifest-path ${DV_RUST_DIR}/Cargo.toml --release) -ExternalProject_Add(dv_capi_ext - SOURCE_DIR ${DV_RUST_DIR} +find_program(BAZEL_EXECUTABLE bazel REQUIRED) +find_program(CARGO_EXECUTABLE cargo REQUIRED) + +set(DV_BRIDGE_DIR ${CMAKE_CURRENT_LIST_DIR}/core/ffi/diplomat) +set(DV_BRIDGE_ENTRY ${DV_BRIDGE_DIR}/src/lib.rs) +set(DV_CODEGEN_ROOT ${CMAKE_BINARY_DIR}/generated/diplomat) +set(DV_CODEGEN_C_DIR ${DV_CODEGEN_ROOT}/c) +set(DV_CODEGEN_CPP_DIR ${DV_CODEGEN_ROOT}/cpp) + +file(MAKE_DIRECTORY ${DV_CODEGEN_C_DIR} ${DV_CODEGEN_CPP_DIR}) + +set(DV_GEN_C_HEADERS + ${DV_CODEGEN_C_DIR}/BaseUnits.d.h + ${DV_CODEGEN_C_DIR}/BaseUnits.h + ${DV_CODEGEN_C_DIR}/DvError.d.h + ${DV_CODEGEN_C_DIR}/DvError.h + ${DV_CODEGEN_C_DIR}/DimensionalVariable.d.h + ${DV_CODEGEN_C_DIR}/DimensionalVariable.h + ${DV_CODEGEN_C_DIR}/diplomat_runtime.h +) +set(DV_GEN_CPP_HEADERS + ${DV_CODEGEN_CPP_DIR}/BaseUnits.d.hpp + ${DV_CODEGEN_CPP_DIR}/BaseUnits.hpp + ${DV_CODEGEN_CPP_DIR}/DvError.d.hpp + ${DV_CODEGEN_CPP_DIR}/DvError.hpp + ${DV_CODEGEN_CPP_DIR}/DimensionalVariable.d.hpp + ${DV_CODEGEN_CPP_DIR}/DimensionalVariable.hpp + ${DV_CODEGEN_CPP_DIR}/diplomat_runtime.hpp +) + +add_custom_command( + OUTPUT ${DV_GEN_C_HEADERS} + COMMAND ${CMAKE_COMMAND} -E make_directory ${DV_CODEGEN_C_DIR} + COMMAND ${BAZEL_EXECUTABLE} run //tools/diplomat_codegen:diplomat_codegen -- c ${DV_CODEGEN_C_DIR} --entry ${DV_BRIDGE_ENTRY} + DEPENDS ${DV_BRIDGE_ENTRY} + WORKING_DIRECTORY ${CMAKE_CURRENT_LIST_DIR} + VERBATIM +) + +add_custom_command( + OUTPUT ${DV_GEN_CPP_HEADERS} + COMMAND ${CMAKE_COMMAND} -E make_directory ${DV_CODEGEN_CPP_DIR} + COMMAND ${BAZEL_EXECUTABLE} run //tools/diplomat_codegen:diplomat_codegen -- cpp ${DV_CODEGEN_CPP_DIR} --entry ${DV_BRIDGE_ENTRY} + DEPENDS ${DV_BRIDGE_ENTRY} + WORKING_DIRECTORY ${CMAKE_CURRENT_LIST_DIR} + VERBATIM +) + +add_custom_target(dv_diplomat_codegen DEPENDS ${DV_GEN_C_HEADERS} ${DV_GEN_CPP_HEADERS}) + +set(DV_CARGO_TARGET_DIR ${DV_BRIDGE_DIR}/target) +set(DV_CARGO_BUILD_CMD + ${CARGO_EXECUTABLE} build + --manifest-path ${DV_BRIDGE_DIR}/Cargo.toml + --release +) + +ExternalProject_Add(dv_diplomat_bridge_ext + SOURCE_DIR ${DV_BRIDGE_DIR} BUILD_IN_SOURCE 1 CONFIGURE_COMMAND "" - BUILD_COMMAND ${DV_BUILD_CMD} + BUILD_COMMAND ${DV_CARGO_BUILD_CMD} INSTALL_COMMAND "" - BUILD_BYPRODUCTS - ${DV_RUST_DIR}/target/release/libdv_capi.a - ${DV_RUST_DIR}/target/release/libdv_capi.dylib + BUILD_BYPRODUCTS + ${DV_BRIDGE_DIR}/target/release/libdv_diplomat_bridge.a ) -# Library artifact path -if(APPLE) - set(DV_CAPI_SHARED ${DV_RUST_DIR}/target/release/libdv_capi.dylib) -elseif(UNIX) - set(DV_CAPI_SHARED ${DV_RUST_DIR}/target/release/libdv_capi.so) -elseif(WIN32) - set(DV_CAPI_SHARED ${DV_RUST_DIR}/target/release/dv_capi.dll) -endif() -set(DV_CAPI_STATIC ${DV_RUST_DIR}/target/release/libdv_capi.a) +set(DV_DIPLOMAT_STATIC ${DV_BRIDGE_DIR}/target/release/libdv_diplomat_bridge.a) add_library(dv_c STATIC IMPORTED GLOBAL) set_target_properties(dv_c PROPERTIES - IMPORTED_LOCATION ${DV_CAPI_STATIC} - INTERFACE_INCLUDE_DIRECTORIES ${CMAKE_CURRENT_LIST_DIR}/cpp/include + IMPORTED_LOCATION ${DV_DIPLOMAT_STATIC} + INTERFACE_INCLUDE_DIRECTORIES ${DV_CODEGEN_C_DIR} ) -add_dependencies(dv_c dv_capi_ext) - -# Help executables find the dylib at runtime on macOS when running from build tree -if(APPLE) - set_property(TARGET dv_c PROPERTY INTERFACE_LINK_DIRECTORIES ${DV_RUST_DIR}/target/release) -endif() +target_link_libraries(dv_c INTERFACE $<$:m>) +add_dependencies(dv_c dv_diplomat_bridge_ext dv_diplomat_codegen) add_library(dv_cpp INTERFACE) -target_include_directories(dv_cpp INTERFACE ${CMAKE_CURRENT_LIST_DIR}/cpp/include) +target_include_directories(dv_cpp INTERFACE ${DV_CODEGEN_CPP_DIR}) target_link_libraries(dv_cpp INTERFACE dv_c) - -add_subdirectory(cpp) +add_dependencies(dv_cpp dv_diplomat_codegen) add_subdirectory(examples/c) add_subdirectory(examples/cpp) diff --git a/MODULE.bazel b/MODULE.bazel index 8faafc4..35912b6 100644 --- a/MODULE.bazel +++ b/MODULE.bazel @@ -9,9 +9,8 @@ module(name = "dv") # Import Bazel Dependencies # ============================================================================= -bazel_dep(name = "platforms", version="1.0.0") +bazel_dep(name = "platforms", version = "1.0.0") bazel_dep(name = "rules_rust", version = "0.67.0") -bazel_dep(name = "rules_rust_pyo3", version = "0.67.0") bazel_dep(name = "rules_cc", version = "0.2.8") bazel_dep(name = "rules_python", version = "1.6.3") bazel_dep(name = "rules_uv", version = "0.88.0") @@ -32,23 +31,28 @@ crate.spec( package = "serde_json", version = "1.0", ) +crate.spec( + package = "diplomat", + version = "0.14.0", +) +crate.spec( + package = "diplomat-runtime", + version = "0.14.0", +) +crate.spec( + package = "diplomat-tool", + version = "0.14.1", +) crate.from_specs() use_repo(crate, "crates") -# ============================================================================== -# PyO3 Setup -# ============================================================================== -register_toolchains( - "@rules_rust_pyo3//toolchains:toolchain", - "@rules_rust_pyo3//toolchains:rust_toolchain", -) - # ============================================================================== # C/C++ Setup # ============================================================================== # Hermetic C/C++ toolchains (LLVM/Clang) bazel_dep(name = "toolchains_llvm", version = "1.5.0") + llvm = use_extension("@toolchains_llvm//toolchain/extensions:llvm.bzl", "llvm") llvm.toolchain( name = "llvm_toolchain", @@ -65,12 +69,26 @@ register_toolchains( # Python Setup # ============================================================================== -# Register Python 3.12 toolchain +# Register Python toolchains for supported wheel builds python = use_extension("@rules_python//python/extensions:python.bzl", "python") +python.defaults( + python_version = "3.12", +) +python.toolchain( + python_version = "3.10", +) +python.toolchain( + python_version = "3.11", +) python.toolchain( python_version = "3.12", ) -use_repo(python, "python_3_12") +use_repo( + python, + "python_3_10", + "python_3_11", + "python_3_12", +) # Set up pip dependencies pip = use_extension("@rules_python//python/extensions:pip.bzl", "pip") @@ -79,7 +97,22 @@ pip.parse( python_version = "3.12", requirements_lock = "//:tools/requirements.txt", ) -use_repo(pip, "pypi") +pip.parse( + hub_name = "pypi_310", + python_version = "3.10", + requirements_lock = "//:tools/requirements.txt", +) +pip.parse( + hub_name = "pypi_311", + python_version = "3.11", + requirements_lock = "//:tools/requirements.txt", +) +pip.parse( + hub_name = "pypi_312", + python_version = "3.12", + requirements_lock = "//:tools/requirements.txt", +) +use_repo(pip, "pypi", "pypi_310", "pypi_311", "pypi_312") # ============================================================================== # JavaScript / Node.js Setup @@ -89,6 +122,7 @@ use_repo(pip, "pypi") # By default you get the node version from DEFAULT_NODE_VERSION in @rules_nodejs//nodejs:repositories.bzl # Optionally you can pin a different node version: bazel_dep(name = "rules_nodejs", version = "6.3.0") + node = use_extension("@rules_nodejs//nodejs:extensions.bzl", "node", dev_dependency = True) node.toolchain(node_version = "20.13.1") diff --git a/MODULE.bazel.lock b/MODULE.bazel.lock index 8cc0053..cef85d6 100644 --- a/MODULE.bazel.lock +++ b/MODULE.bazel.lock @@ -161,8 +161,6 @@ "https://bcr.bazel.build/modules/rules_python/1.6.3/source.json": "f0be74977e5604a6526c8a416cda22985093ff7d5d380d41722d7e44015cc419", "https://bcr.bazel.build/modules/rules_rust/0.67.0/MODULE.bazel": "87c3816c4321352dcfd9e9e26b58e84efc5b21351ae3ef8fb5d0d57bde7237f5", "https://bcr.bazel.build/modules/rules_rust/0.67.0/source.json": "a8ef4d3be30eb98e060cad9e5875a55b603195487f76e01b619b51a1df4641cc", - "https://bcr.bazel.build/modules/rules_rust_pyo3/0.67.0/MODULE.bazel": "52d069a749a163092b7c4b3b64ba513b942d53faf0515a6f60edc2c99ec42210", - "https://bcr.bazel.build/modules/rules_rust_pyo3/0.67.0/source.json": "fbac254181d020283453e515c8206760f1059ce48689553a9e289b6a3a56bf71", "https://bcr.bazel.build/modules/rules_shell/0.2.0/MODULE.bazel": "fda8a652ab3c7d8fee214de05e7a9916d8b28082234e8d2c0094505c5268ed3c", "https://bcr.bazel.build/modules/rules_shell/0.6.1/MODULE.bazel": "72e76b0eea4e81611ef5452aa82b3da34caca0c8b7b5c0c9584338aa93bae26b", "https://bcr.bazel.build/modules/rules_shell/0.6.1/source.json": "20ec05cd5e592055e214b2da8ccb283c7f2a421ea0dc2acbf1aa792e11c03d0c", @@ -188,6 +186,126 @@ }, "selectedYankedVersions": {}, "moduleExtensions": { + "@@aspect_rules_js+//npm:extensions.bzl%pnpm": { + "general": { + "bzlTransitiveDigest": "hayesuSMre0bdf1Oyb2NQRQGTj1fzjyjE3sxlqlzlYM=", + "usagesDigest": "BBPrPIaT5exyvlLOE9kinBChl4NlhfgJuX8ztyq8nH4=", + "recordedFileInputs": {}, + "recordedDirentsInputs": {}, + "envVariables": {}, + "generatedRepoSpecs": { + "pnpm": { + "repoRuleId": "@@aspect_rules_js+//npm/private:npm_import.bzl%npm_import_rule", + "attributes": { + "package": "pnpm", + "version": "8.6.7", + "root_package": "", + "link_workspace": "", + "link_packages": {}, + "integrity": "sha512-vRIWpD/L4phf9Bk2o/O2TDR8fFoJnpYrp2TKqTIZF/qZ2/rgL3qKXzHofHgbXsinwMoSEigz28sqk3pQ+yMEQQ==", + "url": "", + "commit": "", + "patch_args": [ + "-p0" + ], + "patches": [], + "custom_postinstall": "", + "npm_auth": "", + "npm_auth_basic": "", + "npm_auth_username": "", + "npm_auth_password": "", + "lifecycle_hooks": [], + "extra_build_content": "load(\"@aspect_rules_js//js:defs.bzl\", \"js_binary\")\njs_binary(name = \"pnpm\", data = glob([\"package/**\"]), entry_point = \"package/dist/pnpm.cjs\", visibility = [\"//visibility:public\"])", + "generate_bzl_library_targets": false, + "extract_full_archive": true, + "exclude_package_contents": [], + "system_tar": "auto" + } + }, + "pnpm__links": { + "repoRuleId": "@@aspect_rules_js+//npm/private:npm_import.bzl%npm_import_links", + "attributes": { + "package": "pnpm", + "version": "8.6.7", + "dev": false, + "root_package": "", + "link_packages": {}, + "deps": {}, + "transitive_closure": {}, + "lifecycle_build_target": false, + "lifecycle_hooks_env": [], + "lifecycle_hooks_execution_requirements": [ + "no-sandbox" + ], + "lifecycle_hooks_use_default_shell_env": false, + "bins": {}, + "package_visibility": [ + "//visibility:public" + ], + "replace_package": "", + "exclude_package_contents": [] + } + } + }, + "recordedRepoMappingEntries": [ + [ + "aspect_bazel_lib+", + "aspect_bazel_lib", + "aspect_bazel_lib+" + ], + [ + "aspect_bazel_lib+", + "bazel_skylib", + "bazel_skylib+" + ], + [ + "aspect_bazel_lib+", + "bazel_tools", + "bazel_tools" + ], + [ + "aspect_rules_js+", + "aspect_bazel_lib", + "aspect_bazel_lib+" + ], + [ + "aspect_rules_js+", + "aspect_rules_js", + "aspect_rules_js+" + ], + [ + "aspect_rules_js+", + "aspect_tools_telemetry_report", + "aspect_tools_telemetry++telemetry+aspect_tools_telemetry_report" + ], + [ + "aspect_rules_js+", + "bazel_features", + "bazel_features+" + ], + [ + "aspect_rules_js+", + "bazel_skylib", + "bazel_skylib+" + ], + [ + "aspect_rules_js+", + "bazel_tools", + "bazel_tools" + ], + [ + "bazel_features+", + "bazel_features_globals", + "bazel_features++version_extension+bazel_features_globals" + ], + [ + "bazel_features+", + "bazel_features_version", + "bazel_features++version_extension+bazel_features_version" + ] + ] + } + }, "@@aspect_tools_telemetry+//:extension.bzl%telemetry": { "general": { "bzlTransitiveDigest": "gA7tPEdJXhskzPIEUxjX9IdDrM6+WjfbgXJ8Ez47umk=", @@ -684,7 +802,7 @@ "@@rules_rust+//crate_universe:extensions.bzl%crate": { "general": { "bzlTransitiveDigest": "24f89aZmQ72kZSapU+kl1MImmOMesD/oSwUItDmPu/Y=", - "usagesDigest": "VtuXxCm1hBObZsgKy+1BQ5XFuJvwK5I4l6pdTRAJ9es=", + "usagesDigest": "UJld+3fhkayro0teBjub+ThgZ/ZCcQ/CM0rDeNxz79Y=", "recordedFileInputs": {}, "recordedDirentsInputs": {}, "envVariables": { @@ -702,682 +820,1036 @@ "repoRuleId": "@@rules_rust+//crate_universe:extensions.bzl%_generate_repo", "attributes": { "contents": { - "BUILD.bazel": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\npackage(default_visibility = [\"//visibility:public\"])\n\nexports_files(\n [\n \"cargo-bazel.json\",\n \"crates.bzl\",\n \"defs.bzl\",\n ] + glob(\n allow_empty = True,\n include = [\"*.bazel\"],\n ),\n)\n\nfilegroup(\n name = \"srcs\",\n srcs = glob(\n allow_empty = True,\n include = [\n \"*.bazel\",\n \"*.bzl\",\n ],\n ),\n)\n\n# Workspace Member Dependencies\nalias(\n name = \"serde_json-1.0.149\",\n actual = \"@crates__serde_json-1.0.149//:serde_json\",\n tags = [\"manual\"],\n)\n\nalias(\n name = \"serde_json\",\n actual = \"@crates__serde_json-1.0.149//:serde_json\",\n tags = [\"manual\"],\n)\n", + "BUILD.bazel": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\npackage(default_visibility = [\"//visibility:public\"])\n\nexports_files(\n [\n \"cargo-bazel.json\",\n \"crates.bzl\",\n \"defs.bzl\",\n ] + glob(\n allow_empty = True,\n include = [\"*.bazel\"],\n ),\n)\n\nfilegroup(\n name = \"srcs\",\n srcs = glob(\n allow_empty = True,\n include = [\n \"*.bazel\",\n \"*.bzl\",\n ],\n ),\n)\n\n# Workspace Member Dependencies\nalias(\n name = \"diplomat-0.14.0\",\n actual = \"@crates__diplomat-0.14.0//:diplomat\",\n tags = [\"manual\"],\n)\n\nalias(\n name = \"diplomat\",\n actual = \"@crates__diplomat-0.14.0//:diplomat\",\n tags = [\"manual\"],\n)\n\nalias(\n name = \"diplomat-runtime-0.14.0\",\n actual = \"@crates__diplomat-runtime-0.14.0//:diplomat_runtime\",\n tags = [\"manual\"],\n)\n\nalias(\n name = \"diplomat-runtime\",\n actual = \"@crates__diplomat-runtime-0.14.0//:diplomat_runtime\",\n tags = [\"manual\"],\n)\n\nalias(\n name = \"diplomat-tool-0.14.1\",\n actual = \"@crates__diplomat-tool-0.14.1//:diplomat_tool\",\n tags = [\"manual\"],\n)\n\nalias(\n name = \"diplomat-tool\",\n actual = \"@crates__diplomat-tool-0.14.1//:diplomat_tool\",\n tags = [\"manual\"],\n)\n\nalias(\n name = \"serde_json-1.0.149\",\n actual = \"@crates__serde_json-1.0.149//:serde_json\",\n tags = [\"manual\"],\n)\n\nalias(\n name = \"serde_json\",\n actual = \"@crates__serde_json-1.0.149//:serde_json\",\n tags = [\"manual\"],\n)\n", "alias_rules.bzl": "\"\"\"Alias that transitions its target to `compilation_mode=opt`. Use `transition_alias=\"opt\"` to enable.\"\"\"\n\nload(\"@rules_cc//cc:defs.bzl\", \"CcInfo\")\nload(\"@rules_rust//rust:rust_common.bzl\", \"COMMON_PROVIDERS\")\n\ndef _transition_alias_impl(ctx):\n # `ctx.attr.actual` is a list of 1 item due to the transition\n providers = [ctx.attr.actual[0][provider] for provider in COMMON_PROVIDERS]\n if CcInfo in ctx.attr.actual[0]:\n providers.append(ctx.attr.actual[0][CcInfo])\n return providers\n\ndef _change_compilation_mode(compilation_mode):\n def _change_compilation_mode_impl(_settings, _attr):\n return {\n \"//command_line_option:compilation_mode\": compilation_mode,\n }\n\n return transition(\n implementation = _change_compilation_mode_impl,\n inputs = [],\n outputs = [\n \"//command_line_option:compilation_mode\",\n ],\n )\n\ndef _transition_alias_rule(compilation_mode):\n return rule(\n implementation = _transition_alias_impl,\n provides = COMMON_PROVIDERS,\n attrs = {\n \"actual\": attr.label(\n mandatory = True,\n doc = \"`rust_library()` target to transition to `compilation_mode=opt`.\",\n providers = COMMON_PROVIDERS,\n cfg = _change_compilation_mode(compilation_mode),\n ),\n \"_allowlist_function_transition\": attr.label(\n default = \"@bazel_tools//tools/allowlists/function_transition_allowlist\",\n ),\n },\n doc = \"Transitions a Rust library crate to the `compilation_mode=opt`.\",\n )\n\ntransition_alias_dbg = _transition_alias_rule(\"dbg\")\ntransition_alias_fastbuild = _transition_alias_rule(\"fastbuild\")\ntransition_alias_opt = _transition_alias_rule(\"opt\")\n", - "defs.bzl": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\"\"\"\n# `crates_repository` API\n\n- [aliases](#aliases)\n- [crate_deps](#crate_deps)\n- [all_crate_deps](#all_crate_deps)\n- [crate_repositories](#crate_repositories)\n\n\"\"\"\n\nload(\"@bazel_tools//tools/build_defs/repo:git.bzl\", \"new_git_repository\")\nload(\"@bazel_tools//tools/build_defs/repo:http.bzl\", \"http_archive\")\nload(\"@bazel_tools//tools/build_defs/repo:utils.bzl\", \"maybe\")\nload(\"@bazel_skylib//lib:selects.bzl\", \"selects\")\nload(\"@rules_rust//crate_universe/private:local_crate_mirror.bzl\", \"local_crate_mirror\")\n\n###############################################################################\n# MACROS API\n###############################################################################\n\n# An identifier that represent common dependencies (unconditional).\n_COMMON_CONDITION = \"\"\n\ndef _flatten_dependency_maps(all_dependency_maps):\n \"\"\"Flatten a list of dependency maps into one dictionary.\n\n Dependency maps have the following structure:\n\n ```python\n DEPENDENCIES_MAP = {\n # The first key in the map is a Bazel package\n # name of the workspace this file is defined in.\n \"workspace_member_package\": {\n\n # Not all dependencies are supported for all platforms.\n # the condition key is the condition required to be true\n # on the host platform.\n \"condition\": {\n\n # An alias to a crate target. # The label of the crate target the\n # Aliases are only crate names. # package name refers to.\n \"package_name\": \"@full//:label\",\n }\n }\n }\n ```\n\n Args:\n all_dependency_maps (list): A list of dicts as described above\n\n Returns:\n dict: A dictionary as described above\n \"\"\"\n dependencies = {}\n\n for workspace_deps_map in all_dependency_maps:\n for pkg_name, conditional_deps_map in workspace_deps_map.items():\n if pkg_name not in dependencies:\n non_frozen_map = dict()\n for key, values in conditional_deps_map.items():\n non_frozen_map.update({key: dict(values.items())})\n dependencies.setdefault(pkg_name, non_frozen_map)\n continue\n\n for condition, deps_map in conditional_deps_map.items():\n # If the condition has not been recorded, do so and continue\n if condition not in dependencies[pkg_name]:\n dependencies[pkg_name].setdefault(condition, dict(deps_map.items()))\n continue\n\n # Alert on any miss-matched dependencies\n inconsistent_entries = []\n for crate_name, crate_label in deps_map.items():\n existing = dependencies[pkg_name][condition].get(crate_name)\n if existing and existing != crate_label:\n inconsistent_entries.append((crate_name, existing, crate_label))\n dependencies[pkg_name][condition].update({crate_name: crate_label})\n\n return dependencies\n\ndef crate_deps(deps, package_name = None):\n \"\"\"Finds the fully qualified label of the requested crates for the package where this macro is called.\n\n Args:\n deps (list): The desired list of crate targets.\n package_name (str, optional): The package name of the set of dependencies to look up.\n Defaults to `native.package_name()`.\n\n Returns:\n list: A list of labels to generated rust targets (str)\n \"\"\"\n\n if not deps:\n return []\n\n if package_name == None:\n package_name = native.package_name()\n\n # Join both sets of dependencies\n dependencies = _flatten_dependency_maps([\n _NORMAL_DEPENDENCIES,\n _NORMAL_DEV_DEPENDENCIES,\n _PROC_MACRO_DEPENDENCIES,\n _PROC_MACRO_DEV_DEPENDENCIES,\n _BUILD_DEPENDENCIES,\n _BUILD_PROC_MACRO_DEPENDENCIES,\n ]).pop(package_name, {})\n\n # Combine all conditional packages so we can easily index over a flat list\n # TODO: Perhaps this should actually return select statements and maintain\n # the conditionals of the dependencies\n flat_deps = {}\n for deps_set in dependencies.values():\n for crate_name, crate_label in deps_set.items():\n flat_deps.update({crate_name: crate_label})\n\n missing_crates = []\n crate_targets = []\n for crate_target in deps:\n if crate_target not in flat_deps:\n missing_crates.append(crate_target)\n else:\n crate_targets.append(flat_deps[crate_target])\n\n if missing_crates:\n fail(\"Could not find crates `{}` among dependencies of `{}`. Available dependencies were `{}`\".format(\n missing_crates,\n package_name,\n dependencies,\n ))\n\n return crate_targets\n\ndef all_crate_deps(\n normal = False, \n normal_dev = False, \n proc_macro = False, \n proc_macro_dev = False,\n build = False,\n build_proc_macro = False,\n package_name = None):\n \"\"\"Finds the fully qualified label of all requested direct crate dependencies \\\n for the package where this macro is called.\n\n If no parameters are set, all normal dependencies are returned. Setting any one flag will\n otherwise impact the contents of the returned list.\n\n Args:\n normal (bool, optional): If True, normal dependencies are included in the\n output list.\n normal_dev (bool, optional): If True, normal dev dependencies will be\n included in the output list..\n proc_macro (bool, optional): If True, proc_macro dependencies are included\n in the output list.\n proc_macro_dev (bool, optional): If True, dev proc_macro dependencies are\n included in the output list.\n build (bool, optional): If True, build dependencies are included\n in the output list.\n build_proc_macro (bool, optional): If True, build proc_macro dependencies are\n included in the output list.\n package_name (str, optional): The package name of the set of dependencies to look up.\n Defaults to `native.package_name()` when unset.\n\n Returns:\n list: A list of labels to generated rust targets (str)\n \"\"\"\n\n if package_name == None:\n package_name = native.package_name()\n\n # Determine the relevant maps to use\n all_dependency_maps = []\n if normal:\n all_dependency_maps.append(_NORMAL_DEPENDENCIES)\n if normal_dev:\n all_dependency_maps.append(_NORMAL_DEV_DEPENDENCIES)\n if proc_macro:\n all_dependency_maps.append(_PROC_MACRO_DEPENDENCIES)\n if proc_macro_dev:\n all_dependency_maps.append(_PROC_MACRO_DEV_DEPENDENCIES)\n if build:\n all_dependency_maps.append(_BUILD_DEPENDENCIES)\n if build_proc_macro:\n all_dependency_maps.append(_BUILD_PROC_MACRO_DEPENDENCIES)\n\n # Default to always using normal dependencies\n if not all_dependency_maps:\n all_dependency_maps.append(_NORMAL_DEPENDENCIES)\n\n dependencies = _flatten_dependency_maps(all_dependency_maps).pop(package_name, None)\n\n if not dependencies:\n if dependencies == None:\n fail(\"Tried to get all_crate_deps for package \" + package_name + \" but that package had no Cargo.toml file\")\n else:\n return []\n\n crate_deps = list(dependencies.pop(_COMMON_CONDITION, {}).values())\n for condition, deps in dependencies.items():\n crate_deps += selects.with_or({\n tuple(_CONDITIONS[condition]): deps.values(),\n \"//conditions:default\": [],\n })\n\n return crate_deps\n\ndef aliases(\n normal = False,\n normal_dev = False,\n proc_macro = False,\n proc_macro_dev = False,\n build = False,\n build_proc_macro = False,\n package_name = None):\n \"\"\"Produces a map of Crate alias names to their original label\n\n If no dependency kinds are specified, `normal` and `proc_macro` are used by default.\n Setting any one flag will otherwise determine the contents of the returned dict.\n\n Args:\n normal (bool, optional): If True, normal dependencies are included in the\n output list.\n normal_dev (bool, optional): If True, normal dev dependencies will be\n included in the output list..\n proc_macro (bool, optional): If True, proc_macro dependencies are included\n in the output list.\n proc_macro_dev (bool, optional): If True, dev proc_macro dependencies are\n included in the output list.\n build (bool, optional): If True, build dependencies are included\n in the output list.\n build_proc_macro (bool, optional): If True, build proc_macro dependencies are\n included in the output list.\n package_name (str, optional): The package name of the set of dependencies to look up.\n Defaults to `native.package_name()` when unset.\n\n Returns:\n dict: The aliases of all associated packages\n \"\"\"\n if package_name == None:\n package_name = native.package_name()\n\n # Determine the relevant maps to use\n all_aliases_maps = []\n if normal:\n all_aliases_maps.append(_NORMAL_ALIASES)\n if normal_dev:\n all_aliases_maps.append(_NORMAL_DEV_ALIASES)\n if proc_macro:\n all_aliases_maps.append(_PROC_MACRO_ALIASES)\n if proc_macro_dev:\n all_aliases_maps.append(_PROC_MACRO_DEV_ALIASES)\n if build:\n all_aliases_maps.append(_BUILD_ALIASES)\n if build_proc_macro:\n all_aliases_maps.append(_BUILD_PROC_MACRO_ALIASES)\n\n # Default to always using normal aliases\n if not all_aliases_maps:\n all_aliases_maps.append(_NORMAL_ALIASES)\n all_aliases_maps.append(_PROC_MACRO_ALIASES)\n\n aliases = _flatten_dependency_maps(all_aliases_maps).pop(package_name, None)\n\n if not aliases:\n return dict()\n\n common_items = aliases.pop(_COMMON_CONDITION, {}).items()\n\n # If there are only common items in the dictionary, immediately return them\n if not len(aliases.keys()) == 1:\n return dict(common_items)\n\n # Build a single select statement where each conditional has accounted for the\n # common set of aliases.\n crate_aliases = {\"//conditions:default\": dict(common_items)}\n for condition, deps in aliases.items():\n condition_triples = _CONDITIONS[condition]\n for triple in condition_triples:\n if triple in crate_aliases:\n crate_aliases[triple].update(deps)\n else:\n crate_aliases.update({triple: dict(deps.items() + common_items)})\n\n return select(crate_aliases)\n\n###############################################################################\n# WORKSPACE MEMBER DEPS AND ALIASES\n###############################################################################\n\n_NORMAL_DEPENDENCIES = {\n \"\": {\n _COMMON_CONDITION: {\n \"serde_json\": Label(\"@crates//:serde_json-1.0.149\"),\n },\n },\n}\n\n\n_NORMAL_ALIASES = {\n \"\": {\n _COMMON_CONDITION: {\n },\n },\n}\n\n\n_NORMAL_DEV_DEPENDENCIES = {\n \"\": {\n },\n}\n\n\n_NORMAL_DEV_ALIASES = {\n \"\": {\n },\n}\n\n\n_PROC_MACRO_DEPENDENCIES = {\n \"\": {\n },\n}\n\n\n_PROC_MACRO_ALIASES = {\n \"\": {\n },\n}\n\n\n_PROC_MACRO_DEV_DEPENDENCIES = {\n \"\": {\n },\n}\n\n\n_PROC_MACRO_DEV_ALIASES = {\n \"\": {\n },\n}\n\n\n_BUILD_DEPENDENCIES = {\n \"\": {\n },\n}\n\n\n_BUILD_ALIASES = {\n \"\": {\n },\n}\n\n\n_BUILD_PROC_MACRO_DEPENDENCIES = {\n \"\": {\n },\n}\n\n\n_BUILD_PROC_MACRO_ALIASES = {\n \"\": {\n },\n}\n\n\n_CONDITIONS = {\n \"aarch64-apple-darwin\": [\"@rules_rust//rust/platform:aarch64-apple-darwin\"],\n \"aarch64-unknown-linux-gnu\": [\"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\"],\n \"cfg(any())\": [],\n \"wasm32-unknown-unknown\": [\"@rules_rust//rust/platform:wasm32-unknown-unknown\"],\n \"wasm32-wasip1\": [\"@rules_rust//rust/platform:wasm32-wasip1\"],\n \"x86_64-pc-windows-msvc\": [\"@rules_rust//rust/platform:x86_64-pc-windows-msvc\"],\n \"x86_64-unknown-linux-gnu\": [\"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\"],\n \"x86_64-unknown-nixos-gnu\": [\"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\"],\n}\n\n###############################################################################\n\ndef crate_repositories():\n \"\"\"A macro for defining repositories for all generated crates.\n\n Returns:\n A list of repos visible to the module through the module extension.\n \"\"\"\n maybe(\n http_archive,\n name = \"crates__itoa-1.0.17\",\n sha256 = \"92ecc6618181def0457392ccd0ee51198e065e016d1d527a7ac1b6dc7c1f09d2\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/itoa/1.0.17/download\"],\n strip_prefix = \"itoa-1.0.17\",\n build_file = Label(\"@crates//crates:BUILD.itoa-1.0.17.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__memchr-2.8.0\",\n sha256 = \"f8ca58f447f06ed17d5fc4043ce1b10dd205e060fb3ce5b979b8ed8e59ff3f79\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/memchr/2.8.0/download\"],\n strip_prefix = \"memchr-2.8.0\",\n build_file = Label(\"@crates//crates:BUILD.memchr-2.8.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__proc-macro2-1.0.106\",\n sha256 = \"8fd00f0bb2e90d81d1044c2b32617f68fcb9fa3bb7640c23e9c748e53fb30934\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/proc-macro2/1.0.106/download\"],\n strip_prefix = \"proc-macro2-1.0.106\",\n build_file = Label(\"@crates//crates:BUILD.proc-macro2-1.0.106.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__quote-1.0.44\",\n sha256 = \"21b2ebcf727b7760c461f091f9f0f539b77b8e87f2fd88131e7f1b433b3cece4\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/quote/1.0.44/download\"],\n strip_prefix = \"quote-1.0.44\",\n build_file = Label(\"@crates//crates:BUILD.quote-1.0.44.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__serde-1.0.228\",\n sha256 = \"9a8e94ea7f378bd32cbbd37198a4a91436180c5bb472411e48b5ec2e2124ae9e\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/serde/1.0.228/download\"],\n strip_prefix = \"serde-1.0.228\",\n build_file = Label(\"@crates//crates:BUILD.serde-1.0.228.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__serde_core-1.0.228\",\n sha256 = \"41d385c7d4ca58e59fc732af25c3983b67ac852c1a25000afe1175de458b67ad\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/serde_core/1.0.228/download\"],\n strip_prefix = \"serde_core-1.0.228\",\n build_file = Label(\"@crates//crates:BUILD.serde_core-1.0.228.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__serde_derive-1.0.228\",\n sha256 = \"d540f220d3187173da220f885ab66608367b6574e925011a9353e4badda91d79\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/serde_derive/1.0.228/download\"],\n strip_prefix = \"serde_derive-1.0.228\",\n build_file = Label(\"@crates//crates:BUILD.serde_derive-1.0.228.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__serde_json-1.0.149\",\n sha256 = \"83fc039473c5595ace860d8c4fafa220ff474b3fc6bfdb4293327f1a37e94d86\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/serde_json/1.0.149/download\"],\n strip_prefix = \"serde_json-1.0.149\",\n build_file = Label(\"@crates//crates:BUILD.serde_json-1.0.149.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__syn-2.0.117\",\n sha256 = \"e665b8803e7b1d2a727f4023456bbbbe74da67099c585258af0ad9c5013b9b99\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/syn/2.0.117/download\"],\n strip_prefix = \"syn-2.0.117\",\n build_file = Label(\"@crates//crates:BUILD.syn-2.0.117.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__unicode-ident-1.0.24\",\n sha256 = \"e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/unicode-ident/1.0.24/download\"],\n strip_prefix = \"unicode-ident-1.0.24\",\n build_file = Label(\"@crates//crates:BUILD.unicode-ident-1.0.24.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__zmij-1.0.21\",\n sha256 = \"b8848ee67ecc8aedbaf3e4122217aff892639231befc6a1b58d29fff4c2cabaa\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/zmij/1.0.21/download\"],\n strip_prefix = \"zmij-1.0.21\",\n build_file = Label(\"@crates//crates:BUILD.zmij-1.0.21.bazel\"),\n )\n\n return [\n struct(repo=\"crates__serde_json-1.0.149\", is_dev_dep = False),\n ]\n" + "defs.bzl": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\"\"\"\n# `crates_repository` API\n\n- [aliases](#aliases)\n- [crate_deps](#crate_deps)\n- [all_crate_deps](#all_crate_deps)\n- [crate_repositories](#crate_repositories)\n\n\"\"\"\n\nload(\"@bazel_tools//tools/build_defs/repo:git.bzl\", \"new_git_repository\")\nload(\"@bazel_tools//tools/build_defs/repo:http.bzl\", \"http_archive\")\nload(\"@bazel_tools//tools/build_defs/repo:utils.bzl\", \"maybe\")\nload(\"@bazel_skylib//lib:selects.bzl\", \"selects\")\nload(\"@rules_rust//crate_universe/private:local_crate_mirror.bzl\", \"local_crate_mirror\")\n\n###############################################################################\n# MACROS API\n###############################################################################\n\n# An identifier that represent common dependencies (unconditional).\n_COMMON_CONDITION = \"\"\n\ndef _flatten_dependency_maps(all_dependency_maps):\n \"\"\"Flatten a list of dependency maps into one dictionary.\n\n Dependency maps have the following structure:\n\n ```python\n DEPENDENCIES_MAP = {\n # The first key in the map is a Bazel package\n # name of the workspace this file is defined in.\n \"workspace_member_package\": {\n\n # Not all dependencies are supported for all platforms.\n # the condition key is the condition required to be true\n # on the host platform.\n \"condition\": {\n\n # An alias to a crate target. # The label of the crate target the\n # Aliases are only crate names. # package name refers to.\n \"package_name\": \"@full//:label\",\n }\n }\n }\n ```\n\n Args:\n all_dependency_maps (list): A list of dicts as described above\n\n Returns:\n dict: A dictionary as described above\n \"\"\"\n dependencies = {}\n\n for workspace_deps_map in all_dependency_maps:\n for pkg_name, conditional_deps_map in workspace_deps_map.items():\n if pkg_name not in dependencies:\n non_frozen_map = dict()\n for key, values in conditional_deps_map.items():\n non_frozen_map.update({key: dict(values.items())})\n dependencies.setdefault(pkg_name, non_frozen_map)\n continue\n\n for condition, deps_map in conditional_deps_map.items():\n # If the condition has not been recorded, do so and continue\n if condition not in dependencies[pkg_name]:\n dependencies[pkg_name].setdefault(condition, dict(deps_map.items()))\n continue\n\n # Alert on any miss-matched dependencies\n inconsistent_entries = []\n for crate_name, crate_label in deps_map.items():\n existing = dependencies[pkg_name][condition].get(crate_name)\n if existing and existing != crate_label:\n inconsistent_entries.append((crate_name, existing, crate_label))\n dependencies[pkg_name][condition].update({crate_name: crate_label})\n\n return dependencies\n\ndef crate_deps(deps, package_name = None):\n \"\"\"Finds the fully qualified label of the requested crates for the package where this macro is called.\n\n Args:\n deps (list): The desired list of crate targets.\n package_name (str, optional): The package name of the set of dependencies to look up.\n Defaults to `native.package_name()`.\n\n Returns:\n list: A list of labels to generated rust targets (str)\n \"\"\"\n\n if not deps:\n return []\n\n if package_name == None:\n package_name = native.package_name()\n\n # Join both sets of dependencies\n dependencies = _flatten_dependency_maps([\n _NORMAL_DEPENDENCIES,\n _NORMAL_DEV_DEPENDENCIES,\n _PROC_MACRO_DEPENDENCIES,\n _PROC_MACRO_DEV_DEPENDENCIES,\n _BUILD_DEPENDENCIES,\n _BUILD_PROC_MACRO_DEPENDENCIES,\n ]).pop(package_name, {})\n\n # Combine all conditional packages so we can easily index over a flat list\n # TODO: Perhaps this should actually return select statements and maintain\n # the conditionals of the dependencies\n flat_deps = {}\n for deps_set in dependencies.values():\n for crate_name, crate_label in deps_set.items():\n flat_deps.update({crate_name: crate_label})\n\n missing_crates = []\n crate_targets = []\n for crate_target in deps:\n if crate_target not in flat_deps:\n missing_crates.append(crate_target)\n else:\n crate_targets.append(flat_deps[crate_target])\n\n if missing_crates:\n fail(\"Could not find crates `{}` among dependencies of `{}`. Available dependencies were `{}`\".format(\n missing_crates,\n package_name,\n dependencies,\n ))\n\n return crate_targets\n\ndef all_crate_deps(\n normal = False, \n normal_dev = False, \n proc_macro = False, \n proc_macro_dev = False,\n build = False,\n build_proc_macro = False,\n package_name = None):\n \"\"\"Finds the fully qualified label of all requested direct crate dependencies \\\n for the package where this macro is called.\n\n If no parameters are set, all normal dependencies are returned. Setting any one flag will\n otherwise impact the contents of the returned list.\n\n Args:\n normal (bool, optional): If True, normal dependencies are included in the\n output list.\n normal_dev (bool, optional): If True, normal dev dependencies will be\n included in the output list..\n proc_macro (bool, optional): If True, proc_macro dependencies are included\n in the output list.\n proc_macro_dev (bool, optional): If True, dev proc_macro dependencies are\n included in the output list.\n build (bool, optional): If True, build dependencies are included\n in the output list.\n build_proc_macro (bool, optional): If True, build proc_macro dependencies are\n included in the output list.\n package_name (str, optional): The package name of the set of dependencies to look up.\n Defaults to `native.package_name()` when unset.\n\n Returns:\n list: A list of labels to generated rust targets (str)\n \"\"\"\n\n if package_name == None:\n package_name = native.package_name()\n\n # Determine the relevant maps to use\n all_dependency_maps = []\n if normal:\n all_dependency_maps.append(_NORMAL_DEPENDENCIES)\n if normal_dev:\n all_dependency_maps.append(_NORMAL_DEV_DEPENDENCIES)\n if proc_macro:\n all_dependency_maps.append(_PROC_MACRO_DEPENDENCIES)\n if proc_macro_dev:\n all_dependency_maps.append(_PROC_MACRO_DEV_DEPENDENCIES)\n if build:\n all_dependency_maps.append(_BUILD_DEPENDENCIES)\n if build_proc_macro:\n all_dependency_maps.append(_BUILD_PROC_MACRO_DEPENDENCIES)\n\n # Default to always using normal dependencies\n if not all_dependency_maps:\n all_dependency_maps.append(_NORMAL_DEPENDENCIES)\n\n dependencies = _flatten_dependency_maps(all_dependency_maps).pop(package_name, None)\n\n if not dependencies:\n if dependencies == None:\n fail(\"Tried to get all_crate_deps for package \" + package_name + \" but that package had no Cargo.toml file\")\n else:\n return []\n\n crate_deps = list(dependencies.pop(_COMMON_CONDITION, {}).values())\n for condition, deps in dependencies.items():\n crate_deps += selects.with_or({\n tuple(_CONDITIONS[condition]): deps.values(),\n \"//conditions:default\": [],\n })\n\n return crate_deps\n\ndef aliases(\n normal = False,\n normal_dev = False,\n proc_macro = False,\n proc_macro_dev = False,\n build = False,\n build_proc_macro = False,\n package_name = None):\n \"\"\"Produces a map of Crate alias names to their original label\n\n If no dependency kinds are specified, `normal` and `proc_macro` are used by default.\n Setting any one flag will otherwise determine the contents of the returned dict.\n\n Args:\n normal (bool, optional): If True, normal dependencies are included in the\n output list.\n normal_dev (bool, optional): If True, normal dev dependencies will be\n included in the output list..\n proc_macro (bool, optional): If True, proc_macro dependencies are included\n in the output list.\n proc_macro_dev (bool, optional): If True, dev proc_macro dependencies are\n included in the output list.\n build (bool, optional): If True, build dependencies are included\n in the output list.\n build_proc_macro (bool, optional): If True, build proc_macro dependencies are\n included in the output list.\n package_name (str, optional): The package name of the set of dependencies to look up.\n Defaults to `native.package_name()` when unset.\n\n Returns:\n dict: The aliases of all associated packages\n \"\"\"\n if package_name == None:\n package_name = native.package_name()\n\n # Determine the relevant maps to use\n all_aliases_maps = []\n if normal:\n all_aliases_maps.append(_NORMAL_ALIASES)\n if normal_dev:\n all_aliases_maps.append(_NORMAL_DEV_ALIASES)\n if proc_macro:\n all_aliases_maps.append(_PROC_MACRO_ALIASES)\n if proc_macro_dev:\n all_aliases_maps.append(_PROC_MACRO_DEV_ALIASES)\n if build:\n all_aliases_maps.append(_BUILD_ALIASES)\n if build_proc_macro:\n all_aliases_maps.append(_BUILD_PROC_MACRO_ALIASES)\n\n # Default to always using normal aliases\n if not all_aliases_maps:\n all_aliases_maps.append(_NORMAL_ALIASES)\n all_aliases_maps.append(_PROC_MACRO_ALIASES)\n\n aliases = _flatten_dependency_maps(all_aliases_maps).pop(package_name, None)\n\n if not aliases:\n return dict()\n\n common_items = aliases.pop(_COMMON_CONDITION, {}).items()\n\n # If there are only common items in the dictionary, immediately return them\n if not len(aliases.keys()) == 1:\n return dict(common_items)\n\n # Build a single select statement where each conditional has accounted for the\n # common set of aliases.\n crate_aliases = {\"//conditions:default\": dict(common_items)}\n for condition, deps in aliases.items():\n condition_triples = _CONDITIONS[condition]\n for triple in condition_triples:\n if triple in crate_aliases:\n crate_aliases[triple].update(deps)\n else:\n crate_aliases.update({triple: dict(deps.items() + common_items)})\n\n return select(crate_aliases)\n\n###############################################################################\n# WORKSPACE MEMBER DEPS AND ALIASES\n###############################################################################\n\n_NORMAL_DEPENDENCIES = {\n \"\": {\n _COMMON_CONDITION: {\n \"diplomat-runtime\": Label(\"@crates//:diplomat-runtime-0.14.0\"),\n \"diplomat-tool\": Label(\"@crates//:diplomat-tool-0.14.1\"),\n \"serde_json\": Label(\"@crates//:serde_json-1.0.149\"),\n },\n },\n}\n\n\n_NORMAL_ALIASES = {\n \"\": {\n _COMMON_CONDITION: {\n },\n },\n}\n\n\n_NORMAL_DEV_DEPENDENCIES = {\n \"\": {\n },\n}\n\n\n_NORMAL_DEV_ALIASES = {\n \"\": {\n },\n}\n\n\n_PROC_MACRO_DEPENDENCIES = {\n \"\": {\n _COMMON_CONDITION: {\n \"diplomat\": Label(\"@crates//:diplomat-0.14.0\"),\n },\n },\n}\n\n\n_PROC_MACRO_ALIASES = {\n \"\": {\n },\n}\n\n\n_PROC_MACRO_DEV_DEPENDENCIES = {\n \"\": {\n },\n}\n\n\n_PROC_MACRO_DEV_ALIASES = {\n \"\": {\n },\n}\n\n\n_BUILD_DEPENDENCIES = {\n \"\": {\n },\n}\n\n\n_BUILD_ALIASES = {\n \"\": {\n },\n}\n\n\n_BUILD_PROC_MACRO_DEPENDENCIES = {\n \"\": {\n },\n}\n\n\n_BUILD_PROC_MACRO_ALIASES = {\n \"\": {\n },\n}\n\n\n_CONDITIONS = {\n \"aarch64-apple-darwin\": [\"@rules_rust//rust/platform:aarch64-apple-darwin\"],\n \"aarch64-unknown-linux-gnu\": [\"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\"],\n \"cfg(any())\": [],\n \"cfg(windows)\": [\"@rules_rust//rust/platform:x86_64-pc-windows-msvc\"],\n \"wasm32-unknown-unknown\": [\"@rules_rust//rust/platform:wasm32-unknown-unknown\"],\n \"wasm32-wasip1\": [\"@rules_rust//rust/platform:wasm32-wasip1\"],\n \"x86_64-pc-windows-msvc\": [\"@rules_rust//rust/platform:x86_64-pc-windows-msvc\"],\n \"x86_64-unknown-linux-gnu\": [\"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\"],\n \"x86_64-unknown-nixos-gnu\": [\"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\"],\n}\n\n###############################################################################\n\ndef crate_repositories():\n \"\"\"A macro for defining repositories for all generated crates.\n\n Returns:\n A list of repos visible to the module through the module extension.\n \"\"\"\n maybe(\n http_archive,\n name = \"crates__anstream-0.6.21\",\n sha256 = \"43d5b281e737544384e969a5ccad3f1cdd24b48086a0fc1b2a5262a26b8f4f4a\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/anstream/0.6.21/download\"],\n strip_prefix = \"anstream-0.6.21\",\n build_file = Label(\"@crates//crates:BUILD.anstream-0.6.21.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__anstyle-1.0.13\",\n sha256 = \"5192cca8006f1fd4f7237516f40fa183bb07f8fbdfedaa0036de5ea9b0b45e78\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/anstyle/1.0.13/download\"],\n strip_prefix = \"anstyle-1.0.13\",\n build_file = Label(\"@crates//crates:BUILD.anstyle-1.0.13.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__anstyle-parse-0.2.7\",\n sha256 = \"4e7644824f0aa2c7b9384579234ef10eb7efb6a0deb83f9630a49594dd9c15c2\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/anstyle-parse/0.2.7/download\"],\n strip_prefix = \"anstyle-parse-0.2.7\",\n build_file = Label(\"@crates//crates:BUILD.anstyle-parse-0.2.7.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__anstyle-query-1.1.5\",\n sha256 = \"40c48f72fd53cd289104fc64099abca73db4166ad86ea0b4341abe65af83dadc\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/anstyle-query/1.1.5/download\"],\n strip_prefix = \"anstyle-query-1.1.5\",\n build_file = Label(\"@crates//crates:BUILD.anstyle-query-1.1.5.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__anstyle-wincon-3.0.11\",\n sha256 = \"291e6a250ff86cd4a820112fb8898808a366d8f9f58ce16d1f538353ad55747d\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/anstyle-wincon/3.0.11/download\"],\n strip_prefix = \"anstyle-wincon-3.0.11\",\n build_file = Label(\"@crates//crates:BUILD.anstyle-wincon-3.0.11.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__askama-0.14.0\",\n sha256 = \"f75363874b771be265f4ffe307ca705ef6f3baa19011c149da8674a87f1b75c4\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/askama/0.14.0/download\"],\n strip_prefix = \"askama-0.14.0\",\n build_file = Label(\"@crates//crates:BUILD.askama-0.14.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__askama_derive-0.14.0\",\n sha256 = \"129397200fe83088e8a68407a8e2b1f826cf0086b21ccdb866a722c8bcd3a94f\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/askama_derive/0.14.0/download\"],\n strip_prefix = \"askama_derive-0.14.0\",\n build_file = Label(\"@crates//crates:BUILD.askama_derive-0.14.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__askama_parser-0.14.0\",\n sha256 = \"d6ab5630b3d5eaf232620167977f95eb51f3432fc76852328774afbd242d4358\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/askama_parser/0.14.0/download\"],\n strip_prefix = \"askama_parser-0.14.0\",\n build_file = Label(\"@crates//crates:BUILD.askama_parser-0.14.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__basic-toml-0.1.10\",\n sha256 = \"ba62675e8242a4c4e806d12f11d136e626e6c8361d6b829310732241652a178a\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/basic-toml/0.1.10/download\"],\n strip_prefix = \"basic-toml-0.1.10\",\n build_file = Label(\"@crates//crates:BUILD.basic-toml-0.1.10.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__bitflags-2.11.0\",\n sha256 = \"843867be96c8daad0d758b57df9392b6d8d271134fce549de6ce169ff98a92af\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/bitflags/2.11.0/download\"],\n strip_prefix = \"bitflags-2.11.0\",\n build_file = Label(\"@crates//crates:BUILD.bitflags-2.11.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__clap-4.5.60\",\n sha256 = \"2797f34da339ce31042b27d23607e051786132987f595b02ba4f6a6dffb7030a\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/clap/4.5.60/download\"],\n strip_prefix = \"clap-4.5.60\",\n build_file = Label(\"@crates//crates:BUILD.clap-4.5.60.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__clap_builder-4.5.60\",\n sha256 = \"24a241312cea5059b13574bb9b3861cabf758b879c15190b37b6d6fd63ab6876\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/clap_builder/4.5.60/download\"],\n strip_prefix = \"clap_builder-4.5.60\",\n build_file = Label(\"@crates//crates:BUILD.clap_builder-4.5.60.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__clap_derive-4.5.55\",\n sha256 = \"a92793da1a46a5f2a02a6f4c46c6496b28c43638adea8306fcb0caa1634f24e5\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/clap_derive/4.5.55/download\"],\n strip_prefix = \"clap_derive-4.5.55\",\n build_file = Label(\"@crates//crates:BUILD.clap_derive-4.5.55.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__clap_lex-1.0.0\",\n sha256 = \"3a822ea5bc7590f9d40f1ba12c0dc3c2760f3482c6984db1573ad11031420831\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/clap_lex/1.0.0/download\"],\n strip_prefix = \"clap_lex-1.0.0\",\n build_file = Label(\"@crates//crates:BUILD.clap_lex-1.0.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__colorchoice-1.0.4\",\n sha256 = \"b05b61dc5112cbb17e4b6cd61790d9845d13888356391624cbe7e41efeac1e75\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/colorchoice/1.0.4/download\"],\n strip_prefix = \"colorchoice-1.0.4\",\n build_file = Label(\"@crates//crates:BUILD.colorchoice-1.0.4.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__colored-3.1.1\",\n sha256 = \"faf9468729b8cbcea668e36183cb69d317348c2e08e994829fb56ebfdfbaac34\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/colored/3.1.1/download\"],\n strip_prefix = \"colored-3.1.1\",\n build_file = Label(\"@crates//crates:BUILD.colored-3.1.1.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__diplomat-0.14.0\",\n sha256 = \"9adb46b05e2f53dcf6a7dfc242e4ce9eb60c369b6b6eb10826a01e93167f59c6\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/diplomat/0.14.0/download\"],\n strip_prefix = \"diplomat-0.14.0\",\n build_file = Label(\"@crates//crates:BUILD.diplomat-0.14.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__diplomat-runtime-0.14.0\",\n sha256 = \"0569bd3caaf13829da7ee4e83dbf9197a0e1ecd72772da6d08f0b4c9285c8d29\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/diplomat-runtime/0.14.0/download\"],\n strip_prefix = \"diplomat-runtime-0.14.0\",\n build_file = Label(\"@crates//crates:BUILD.diplomat-runtime-0.14.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__diplomat-tool-0.14.1\",\n sha256 = \"a69fa451d9a76f2c17bb0dd37603825a71f8199f64eb9bf9d2b6664695efe1e4\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/diplomat-tool/0.14.1/download\"],\n strip_prefix = \"diplomat-tool-0.14.1\",\n build_file = Label(\"@crates//crates:BUILD.diplomat-tool-0.14.1.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__diplomat_core-0.14.0\",\n sha256 = \"51731530ed7f2d4495019abc7df3744f53338e69e2863a6a64ae91821c763df1\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/diplomat_core/0.14.0/download\"],\n strip_prefix = \"diplomat_core-0.14.0\",\n build_file = Label(\"@crates//crates:BUILD.diplomat_core-0.14.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__displaydoc-0.2.5\",\n sha256 = \"97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/displaydoc/0.2.5/download\"],\n strip_prefix = \"displaydoc-0.2.5\",\n build_file = Label(\"@crates//crates:BUILD.displaydoc-0.2.5.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__either-1.15.0\",\n sha256 = \"48c757948c5ede0e46177b7add2e67155f70e33c07fea8284df6576da70b3719\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/either/1.15.0/download\"],\n strip_prefix = \"either-1.15.0\",\n build_file = Label(\"@crates//crates:BUILD.either-1.15.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__equivalent-1.0.2\",\n sha256 = \"877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/equivalent/1.0.2/download\"],\n strip_prefix = \"equivalent-1.0.2\",\n build_file = Label(\"@crates//crates:BUILD.equivalent-1.0.2.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__getopts-0.2.24\",\n sha256 = \"cfe4fbac503b8d1f88e6676011885f34b7174f46e59956bba534ba83abded4df\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/getopts/0.2.24/download\"],\n strip_prefix = \"getopts-0.2.24\",\n build_file = Label(\"@crates//crates:BUILD.getopts-0.2.24.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__hashbrown-0.16.1\",\n sha256 = \"841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/hashbrown/0.16.1/download\"],\n strip_prefix = \"hashbrown-0.16.1\",\n build_file = Label(\"@crates//crates:BUILD.hashbrown-0.16.1.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__heck-0.5.0\",\n sha256 = \"2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/heck/0.5.0/download\"],\n strip_prefix = \"heck-0.5.0\",\n build_file = Label(\"@crates//crates:BUILD.heck-0.5.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__indenter-0.3.4\",\n sha256 = \"964de6e86d545b246d84badc0fef527924ace5134f30641c203ef52ba83f58d5\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/indenter/0.3.4/download\"],\n strip_prefix = \"indenter-0.3.4\",\n build_file = Label(\"@crates//crates:BUILD.indenter-0.3.4.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__indexmap-2.13.0\",\n sha256 = \"7714e70437a7dc3ac8eb7e6f8df75fd8eb422675fc7678aff7364301092b1017\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/indexmap/2.13.0/download\"],\n strip_prefix = \"indexmap-2.13.0\",\n build_file = Label(\"@crates//crates:BUILD.indexmap-2.13.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__is_terminal_polyfill-1.70.2\",\n sha256 = \"a6cb138bb79a146c1bd460005623e142ef0181e3d0219cb493e02f7d08a35695\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/is_terminal_polyfill/1.70.2/download\"],\n strip_prefix = \"is_terminal_polyfill-1.70.2\",\n build_file = Label(\"@crates//crates:BUILD.is_terminal_polyfill-1.70.2.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__itertools-0.14.0\",\n sha256 = \"2b192c782037fadd9cfa75548310488aabdbf3d2da73885b31bd0abd03351285\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/itertools/0.14.0/download\"],\n strip_prefix = \"itertools-0.14.0\",\n build_file = Label(\"@crates//crates:BUILD.itertools-0.14.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__itoa-1.0.17\",\n sha256 = \"92ecc6618181def0457392ccd0ee51198e065e016d1d527a7ac1b6dc7c1f09d2\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/itoa/1.0.17/download\"],\n strip_prefix = \"itoa-1.0.17\",\n build_file = Label(\"@crates//crates:BUILD.itoa-1.0.17.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__memchr-2.8.0\",\n sha256 = \"f8ca58f447f06ed17d5fc4043ce1b10dd205e060fb3ce5b979b8ed8e59ff3f79\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/memchr/2.8.0/download\"],\n strip_prefix = \"memchr-2.8.0\",\n build_file = Label(\"@crates//crates:BUILD.memchr-2.8.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__once_cell_polyfill-1.70.2\",\n sha256 = \"384b8ab6d37215f3c5301a95a4accb5d64aa607f1fcb26a11b5303878451b4fe\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/once_cell_polyfill/1.70.2/download\"],\n strip_prefix = \"once_cell_polyfill-1.70.2\",\n build_file = Label(\"@crates//crates:BUILD.once_cell_polyfill-1.70.2.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__percent-encoding-2.3.2\",\n sha256 = \"9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/percent-encoding/2.3.2/download\"],\n strip_prefix = \"percent-encoding-2.3.2\",\n build_file = Label(\"@crates//crates:BUILD.percent-encoding-2.3.2.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__proc-macro2-1.0.106\",\n sha256 = \"8fd00f0bb2e90d81d1044c2b32617f68fcb9fa3bb7640c23e9c748e53fb30934\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/proc-macro2/1.0.106/download\"],\n strip_prefix = \"proc-macro2-1.0.106\",\n build_file = Label(\"@crates//crates:BUILD.proc-macro2-1.0.106.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__pulldown-cmark-0.13.0\",\n sha256 = \"1e8bbe1a966bd2f362681a44f6edce3c2310ac21e4d5067a6e7ec396297a6ea0\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/pulldown-cmark/0.13.0/download\"],\n strip_prefix = \"pulldown-cmark-0.13.0\",\n build_file = Label(\"@crates//crates:BUILD.pulldown-cmark-0.13.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__pulldown-cmark-escape-0.11.0\",\n sha256 = \"007d8adb5ddab6f8e3f491ac63566a7d5002cc7ed73901f72057943fa71ae1ae\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/pulldown-cmark-escape/0.11.0/download\"],\n strip_prefix = \"pulldown-cmark-escape-0.11.0\",\n build_file = Label(\"@crates//crates:BUILD.pulldown-cmark-escape-0.11.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__quote-1.0.44\",\n sha256 = \"21b2ebcf727b7760c461f091f9f0f539b77b8e87f2fd88131e7f1b433b3cece4\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/quote/1.0.44/download\"],\n strip_prefix = \"quote-1.0.44\",\n build_file = Label(\"@crates//crates:BUILD.quote-1.0.44.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__rustc-hash-2.1.1\",\n sha256 = \"357703d41365b4b27c590e3ed91eabb1b663f07c4c084095e60cbed4362dff0d\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/rustc-hash/2.1.1/download\"],\n strip_prefix = \"rustc-hash-2.1.1\",\n build_file = Label(\"@crates//crates:BUILD.rustc-hash-2.1.1.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__serde-1.0.228\",\n sha256 = \"9a8e94ea7f378bd32cbbd37198a4a91436180c5bb472411e48b5ec2e2124ae9e\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/serde/1.0.228/download\"],\n strip_prefix = \"serde-1.0.228\",\n build_file = Label(\"@crates//crates:BUILD.serde-1.0.228.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__serde_core-1.0.228\",\n sha256 = \"41d385c7d4ca58e59fc732af25c3983b67ac852c1a25000afe1175de458b67ad\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/serde_core/1.0.228/download\"],\n strip_prefix = \"serde_core-1.0.228\",\n build_file = Label(\"@crates//crates:BUILD.serde_core-1.0.228.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__serde_derive-1.0.228\",\n sha256 = \"d540f220d3187173da220f885ab66608367b6574e925011a9353e4badda91d79\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/serde_derive/1.0.228/download\"],\n strip_prefix = \"serde_derive-1.0.228\",\n build_file = Label(\"@crates//crates:BUILD.serde_derive-1.0.228.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__serde_json-1.0.149\",\n sha256 = \"83fc039473c5595ace860d8c4fafa220ff474b3fc6bfdb4293327f1a37e94d86\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/serde_json/1.0.149/download\"],\n strip_prefix = \"serde_json-1.0.149\",\n build_file = Label(\"@crates//crates:BUILD.serde_json-1.0.149.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__serde_spanned-0.6.9\",\n sha256 = \"bf41e0cfaf7226dca15e8197172c295a782857fcb97fad1808a166870dee75a3\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/serde_spanned/0.6.9/download\"],\n strip_prefix = \"serde_spanned-0.6.9\",\n build_file = Label(\"@crates//crates:BUILD.serde_spanned-0.6.9.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__smallvec-1.15.1\",\n sha256 = \"67b1b7a3b5fe4f1376887184045fcf45c69e92af734b7aaddc05fb777b6fbd03\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/smallvec/1.15.1/download\"],\n strip_prefix = \"smallvec-1.15.1\",\n build_file = Label(\"@crates//crates:BUILD.smallvec-1.15.1.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__strck-1.0.0\",\n sha256 = \"42316e70da376f3d113a68d138a60d8a9883c604fe97942721ec2068dab13a9f\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/strck/1.0.0/download\"],\n strip_prefix = \"strck-1.0.0\",\n build_file = Label(\"@crates//crates:BUILD.strck-1.0.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__strsim-0.11.1\",\n sha256 = \"7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/strsim/0.11.1/download\"],\n strip_prefix = \"strsim-0.11.1\",\n build_file = Label(\"@crates//crates:BUILD.strsim-0.11.1.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__syn-2.0.117\",\n sha256 = \"e665b8803e7b1d2a727f4023456bbbbe74da67099c585258af0ad9c5013b9b99\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/syn/2.0.117/download\"],\n strip_prefix = \"syn-2.0.117\",\n build_file = Label(\"@crates//crates:BUILD.syn-2.0.117.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__syn-inline-mod-0.6.0\",\n sha256 = \"2fa6dca1fdb7b2ed46dd534a326725419d4fb10f23d8c85a8b2860e5eb25d0f9\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/syn-inline-mod/0.6.0/download\"],\n strip_prefix = \"syn-inline-mod-0.6.0\",\n build_file = Label(\"@crates//crates:BUILD.syn-inline-mod-0.6.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__toml-0.8.23\",\n sha256 = \"dc1beb996b9d83529a9e75c17a1686767d148d70663143c7854d8b4a09ced362\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/toml/0.8.23/download\"],\n strip_prefix = \"toml-0.8.23\",\n build_file = Label(\"@crates//crates:BUILD.toml-0.8.23.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__toml_datetime-0.6.11\",\n sha256 = \"22cddaf88f4fbc13c51aebbf5f8eceb5c7c5a9da2ac40a13519eb5b0a0e8f11c\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/toml_datetime/0.6.11/download\"],\n strip_prefix = \"toml_datetime-0.6.11\",\n build_file = Label(\"@crates//crates:BUILD.toml_datetime-0.6.11.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__toml_edit-0.22.27\",\n sha256 = \"41fe8c660ae4257887cf66394862d21dbca4a6ddd26f04a3560410406a2f819a\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/toml_edit/0.22.27/download\"],\n strip_prefix = \"toml_edit-0.22.27\",\n build_file = Label(\"@crates//crates:BUILD.toml_edit-0.22.27.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__toml_write-0.1.2\",\n sha256 = \"5d99f8c9a7727884afe522e9bd5edbfc91a3312b36a77b5fb8926e4c31a41801\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/toml_write/0.1.2/download\"],\n strip_prefix = \"toml_write-0.1.2\",\n build_file = Label(\"@crates//crates:BUILD.toml_write-0.1.2.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__unicase-2.9.0\",\n sha256 = \"dbc4bc3a9f746d862c45cb89d705aa10f187bb96c76001afab07a0d35ce60142\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/unicase/2.9.0/download\"],\n strip_prefix = \"unicase-2.9.0\",\n build_file = Label(\"@crates//crates:BUILD.unicase-2.9.0.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__unicode-ident-1.0.24\",\n sha256 = \"e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/unicode-ident/1.0.24/download\"],\n strip_prefix = \"unicode-ident-1.0.24\",\n build_file = Label(\"@crates//crates:BUILD.unicode-ident-1.0.24.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__unicode-width-0.2.2\",\n sha256 = \"b4ac048d71ede7ee76d585517add45da530660ef4390e49b098733c6e897f254\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/unicode-width/0.2.2/download\"],\n strip_prefix = \"unicode-width-0.2.2\",\n build_file = Label(\"@crates//crates:BUILD.unicode-width-0.2.2.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__utf8parse-0.2.2\",\n sha256 = \"06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/utf8parse/0.2.2/download\"],\n strip_prefix = \"utf8parse-0.2.2\",\n build_file = Label(\"@crates//crates:BUILD.utf8parse-0.2.2.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__windows-link-0.2.1\",\n sha256 = \"f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/windows-link/0.2.1/download\"],\n strip_prefix = \"windows-link-0.2.1\",\n build_file = Label(\"@crates//crates:BUILD.windows-link-0.2.1.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__windows-sys-0.61.2\",\n sha256 = \"ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/windows-sys/0.61.2/download\"],\n strip_prefix = \"windows-sys-0.61.2\",\n build_file = Label(\"@crates//crates:BUILD.windows-sys-0.61.2.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__winnow-0.7.14\",\n sha256 = \"5a5364e9d77fcdeeaa6062ced926ee3381faa2ee02d3eb83a5c27a8825540829\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/winnow/0.7.14/download\"],\n strip_prefix = \"winnow-0.7.14\",\n build_file = Label(\"@crates//crates:BUILD.winnow-0.7.14.bazel\"),\n )\n\n maybe(\n http_archive,\n name = \"crates__zmij-1.0.21\",\n sha256 = \"b8848ee67ecc8aedbaf3e4122217aff892639231befc6a1b58d29fff4c2cabaa\",\n type = \"tar.gz\",\n urls = [\"https://static.crates.io/crates/zmij/1.0.21/download\"],\n strip_prefix = \"zmij-1.0.21\",\n build_file = Label(\"@crates//crates:BUILD.zmij-1.0.21.bazel\"),\n )\n\n return [\n struct(repo=\"crates__diplomat-0.14.0\", is_dev_dep = False),\n struct(repo=\"crates__diplomat-runtime-0.14.0\", is_dev_dep = False),\n struct(repo=\"crates__diplomat-tool-0.14.1\", is_dev_dep = False),\n struct(repo=\"crates__serde_json-1.0.149\", is_dev_dep = False),\n ]\n" } } }, - "crates__itoa-1.0.17": { + "crates__anstream-0.6.21": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { "patch_args": [], "patch_tool": "", "patches": [], "remote_patch_strip": 1, - "sha256": "92ecc6618181def0457392ccd0ee51198e065e016d1d527a7ac1b6dc7c1f09d2", + "sha256": "43d5b281e737544384e969a5ccad3f1cdd24b48086a0fc1b2a5262a26b8f4f4a", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/itoa/1.0.17/download" + "https://static.crates.io/crates/anstream/0.6.21/download" ], - "strip_prefix": "itoa-1.0.17", - "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"itoa\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=itoa\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.17\",\n)\n" + "strip_prefix": "anstream-0.6.21", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"anstream\",\n deps = [\n \"@crates__anstyle-1.0.13//:anstyle\",\n \"@crates__anstyle-parse-0.2.7//:anstyle_parse\",\n \"@crates__anstyle-query-1.1.5//:anstyle_query\",\n \"@crates__colorchoice-1.0.4//:colorchoice\",\n \"@crates__is_terminal_polyfill-1.70.2//:is_terminal_polyfill\",\n \"@crates__utf8parse-0.2.2//:utf8parse\",\n ] + select({\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [\n \"@crates__anstyle-wincon-3.0.11//:anstyle_wincon\", # x86_64-pc-windows-msvc\n ],\n \"//conditions:default\": [],\n }),\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"auto\",\n \"default\",\n \"wincon\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=anstream\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.6.21\",\n)\n" } }, - "crates__memchr-2.8.0": { + "crates__anstyle-1.0.13": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { "patch_args": [], "patch_tool": "", "patches": [], "remote_patch_strip": 1, - "sha256": "f8ca58f447f06ed17d5fc4043ce1b10dd205e060fb3ce5b979b8ed8e59ff3f79", + "sha256": "5192cca8006f1fd4f7237516f40fa183bb07f8fbdfedaa0036de5ea9b0b45e78", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/memchr/2.8.0/download" + "https://static.crates.io/crates/anstyle/1.0.13/download" ], - "strip_prefix": "memchr-2.8.0", - "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"memchr\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"alloc\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=memchr\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"2.8.0\",\n)\n" + "strip_prefix": "anstyle-1.0.13", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"anstyle\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=anstyle\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.13\",\n)\n" } }, - "crates__proc-macro2-1.0.106": { + "crates__anstyle-parse-0.2.7": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { "patch_args": [], "patch_tool": "", "patches": [], "remote_patch_strip": 1, - "sha256": "8fd00f0bb2e90d81d1044c2b32617f68fcb9fa3bb7640c23e9c748e53fb30934", + "sha256": "4e7644824f0aa2c7b9384579234ef10eb7efb6a0deb83f9630a49594dd9c15c2", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/proc-macro2/1.0.106/download" + "https://static.crates.io/crates/anstyle-parse/0.2.7/download" ], - "strip_prefix": "proc-macro2-1.0.106", - "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"proc_macro2\",\n deps = [\n \"@crates__proc-macro2-1.0.106//:build_script_build\",\n \"@crates__unicode-ident-1.0.24//:unicode_ident\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"proc-macro\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=proc-macro2\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.106\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"proc-macro\",\n ],\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"proc-macro2\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=proc-macro2\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.106\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" + "strip_prefix": "anstyle-parse-0.2.7", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"anstyle_parse\",\n deps = [\n \"@crates__utf8parse-0.2.2//:utf8parse\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"utf8\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=anstyle-parse\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.2.7\",\n)\n" } }, - "crates__quote-1.0.44": { + "crates__anstyle-query-1.1.5": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { "patch_args": [], "patch_tool": "", "patches": [], "remote_patch_strip": 1, - "sha256": "21b2ebcf727b7760c461f091f9f0f539b77b8e87f2fd88131e7f1b433b3cece4", + "sha256": "40c48f72fd53cd289104fc64099abca73db4166ad86ea0b4341abe65af83dadc", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/quote/1.0.44/download" + "https://static.crates.io/crates/anstyle-query/1.1.5/download" ], - "strip_prefix": "quote-1.0.44", - "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"quote\",\n deps = [\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__quote-1.0.44//:build_script_build\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"proc-macro\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=quote\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.44\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"proc-macro\",\n ],\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"quote\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=quote\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.44\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" + "strip_prefix": "anstyle-query-1.1.5", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"anstyle_query\",\n deps = select({\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [\n \"@crates__windows-sys-0.61.2//:windows_sys\", # cfg(windows)\n ],\n \"//conditions:default\": [],\n }),\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=anstyle-query\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.1.5\",\n)\n" } }, - "crates__serde-1.0.228": { + "crates__anstyle-wincon-3.0.11": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { "patch_args": [], "patch_tool": "", "patches": [], "remote_patch_strip": 1, - "sha256": "9a8e94ea7f378bd32cbbd37198a4a91436180c5bb472411e48b5ec2e2124ae9e", + "sha256": "291e6a250ff86cd4a820112fb8898808a366d8f9f58ce16d1f538353ad55747d", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/serde/1.0.228/download" + "https://static.crates.io/crates/anstyle-wincon/3.0.11/download" ], - "strip_prefix": "serde-1.0.228", - "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"serde\",\n deps = [\n \"@crates__serde-1.0.228//:build_script_build\",\n \"@crates__serde_core-1.0.228//:serde_core\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.228\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"serde\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.228\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" + "strip_prefix": "anstyle-wincon-3.0.11", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"anstyle_wincon\",\n deps = [\n \"@crates__anstyle-1.0.13//:anstyle\",\n ] + select({\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [\n \"@crates__once_cell_polyfill-1.70.2//:once_cell_polyfill\", # cfg(windows)\n \"@crates__windows-sys-0.61.2//:windows_sys\", # cfg(windows)\n ],\n \"//conditions:default\": [],\n }),\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=anstyle-wincon\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"3.0.11\",\n)\n" } }, - "crates__serde_core-1.0.228": { + "crates__askama-0.14.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { "patch_args": [], "patch_tool": "", "patches": [], "remote_patch_strip": 1, - "sha256": "41d385c7d4ca58e59fc732af25c3983b67ac852c1a25000afe1175de458b67ad", + "sha256": "f75363874b771be265f4ffe307ca705ef6f3baa19011c149da8674a87f1b75c4", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/serde_core/1.0.228/download" + "https://static.crates.io/crates/askama/0.14.0/download" ], - "strip_prefix": "serde_core-1.0.228", - "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"serde_core\",\n deps = [\n \"@crates__serde_core-1.0.228//:build_script_build\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde_core\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.228\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"std\",\n ],\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"serde_core\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde_core\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.228\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" + "strip_prefix": "askama-0.14.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"askama\",\n deps = [\n \"@crates__itoa-1.0.17//:itoa\",\n \"@crates__percent-encoding-2.3.2//:percent_encoding\",\n ],\n proc_macro_deps = [\n \"@crates__askama_derive-0.14.0//:askama_derive\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"alloc\",\n \"config\",\n \"default\",\n \"derive\",\n \"std\",\n \"urlencode\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=askama\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.14.0\",\n)\n" } }, - "crates__serde_derive-1.0.228": { + "crates__askama_derive-0.14.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { "patch_args": [], "patch_tool": "", "patches": [], "remote_patch_strip": 1, - "sha256": "d540f220d3187173da220f885ab66608367b6574e925011a9353e4badda91d79", + "sha256": "129397200fe83088e8a68407a8e2b1f826cf0086b21ccdb866a722c8bcd3a94f", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/serde_derive/1.0.228/download" + "https://static.crates.io/crates/askama_derive/0.14.0/download" ], - "strip_prefix": "serde_derive-1.0.228", - "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_proc_macro\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_proc_macro(\n name = \"serde_derive\",\n deps = [\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__quote-1.0.44//:quote\",\n \"@crates__syn-2.0.117//:syn\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde_derive\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.228\",\n)\n" + "strip_prefix": "askama_derive-0.14.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_proc_macro\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_proc_macro(\n name = \"askama_derive\",\n deps = [\n \"@crates__askama_parser-0.14.0//:askama_parser\",\n \"@crates__basic-toml-0.1.10//:basic_toml\",\n \"@crates__memchr-2.8.0//:memchr\",\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__quote-1.0.44//:quote\",\n \"@crates__rustc-hash-2.1.1//:rustc_hash\",\n \"@crates__serde-1.0.228//:serde\",\n \"@crates__syn-2.0.117//:syn\",\n ],\n proc_macro_deps = [\n \"@crates__serde_derive-1.0.228//:serde_derive\",\n ],\n aliases = {\n \"@crates__askama_parser-0.14.0//:askama_parser\": \"parser\",\n },\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"alloc\",\n \"config\",\n \"default\",\n \"derive\",\n \"std\",\n \"urlencode\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=askama_derive\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.14.0\",\n)\n" } }, - "crates__serde_json-1.0.149": { + "crates__askama_parser-0.14.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { "patch_args": [], "patch_tool": "", "patches": [], "remote_patch_strip": 1, - "sha256": "83fc039473c5595ace860d8c4fafa220ff474b3fc6bfdb4293327f1a37e94d86", + "sha256": "d6ab5630b3d5eaf232620167977f95eb51f3432fc76852328774afbd242d4358", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/serde_json/1.0.149/download" + "https://static.crates.io/crates/askama_parser/0.14.0/download" ], - "strip_prefix": "serde_json-1.0.149", - "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"serde_json\",\n deps = [\n \"@crates__itoa-1.0.17//:itoa\",\n \"@crates__memchr-2.8.0//:memchr\",\n \"@crates__serde_core-1.0.228//:serde_core\",\n \"@crates__serde_json-1.0.149//:build_script_build\",\n \"@crates__zmij-1.0.21//:zmij\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde_json\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.149\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"std\",\n ],\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"serde_json\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde_json\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.149\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" + "strip_prefix": "askama_parser-0.14.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"askama_parser\",\n deps = [\n \"@crates__memchr-2.8.0//:memchr\",\n \"@crates__serde-1.0.228//:serde\",\n \"@crates__winnow-0.7.14//:winnow\",\n ],\n proc_macro_deps = [\n \"@crates__serde_derive-1.0.228//:serde_derive\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"config\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=askama_parser\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.14.0\",\n)\n" } }, - "crates__syn-2.0.117": { + "crates__basic-toml-0.1.10": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { "patch_args": [], "patch_tool": "", "patches": [], "remote_patch_strip": 1, - "sha256": "e665b8803e7b1d2a727f4023456bbbbe74da67099c585258af0ad9c5013b9b99", + "sha256": "ba62675e8242a4c4e806d12f11d136e626e6c8361d6b829310732241652a178a", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/syn/2.0.117/download" + "https://static.crates.io/crates/basic-toml/0.1.10/download" ], - "strip_prefix": "syn-2.0.117", - "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"syn\",\n deps = [\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__quote-1.0.44//:quote\",\n \"@crates__unicode-ident-1.0.24//:unicode_ident\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"clone-impls\",\n \"derive\",\n \"parsing\",\n \"printing\",\n \"proc-macro\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=syn\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"2.0.117\",\n)\n" + "strip_prefix": "basic-toml-0.1.10", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"basic_toml\",\n deps = [\n \"@crates__serde-1.0.228//:serde\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=basic-toml\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.1.10\",\n)\n" } }, - "crates__unicode-ident-1.0.24": { + "crates__bitflags-2.11.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { "patch_args": [], "patch_tool": "", "patches": [], "remote_patch_strip": 1, - "sha256": "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75", + "sha256": "843867be96c8daad0d758b57df9392b6d8d271134fce549de6ce169ff98a92af", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/unicode-ident/1.0.24/download" + "https://static.crates.io/crates/bitflags/2.11.0/download" ], - "strip_prefix": "unicode-ident-1.0.24", - "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"unicode_ident\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=unicode-ident\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.24\",\n)\n" + "strip_prefix": "bitflags-2.11.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"bitflags\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=bitflags\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"2.11.0\",\n)\n" } }, - "crates__zmij-1.0.21": { + "crates__clap-4.5.60": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { "patch_args": [], "patch_tool": "", "patches": [], "remote_patch_strip": 1, - "sha256": "b8848ee67ecc8aedbaf3e4122217aff892639231befc6a1b58d29fff4c2cabaa", + "sha256": "2797f34da339ce31042b27d23607e051786132987f595b02ba4f6a6dffb7030a", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/zmij/1.0.21/download" + "https://static.crates.io/crates/clap/4.5.60/download" ], - "strip_prefix": "zmij-1.0.21", - "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"zmij\",\n deps = [\n \"@crates__zmij-1.0.21//:build_script_build\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=zmij\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.21\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"zmij\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=zmij\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.21\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" - } - } - }, - "moduleExtensionMetadata": { - "useAllRepos": "NO", - "reproducible": false - }, - "recordedRepoMappingEntries": [ - [ - "bazel_features+", - "bazel_features_globals", - "bazel_features++version_extension+bazel_features_globals" - ], - [ - "bazel_features+", - "bazel_features_version", - "bazel_features++version_extension+bazel_features_version" - ], - [ - "rules_cc+", - "bazel_tools", - "bazel_tools" - ], - [ - "rules_cc+", - "rules_cc", - "rules_cc+" - ], - [ - "rules_rust+", - "bazel_features", - "bazel_features+" - ], - [ - "rules_rust+", - "bazel_skylib", - "bazel_skylib+" - ], - [ - "rules_rust+", - "bazel_tools", - "bazel_tools" - ], - [ - "rules_rust+", - "rules_cc", - "rules_cc+" - ], - [ - "rules_rust+", - "rules_rust", - "rules_rust+" - ] - ] - } - }, - "@@rules_rust_pyo3+//private:internal_extensions.bzl%rust_ext": { - "general": { - "bzlTransitiveDigest": "mplWnTye6O3jkHSbTUhWt4BLjkwzs8HGGqF011UFz8Q=", - "usagesDigest": "rnHKoNtVZJoyWkyB/t+nXUGsKOy2Z7tAFDc5sSwvxy8=", - "recordedFileInputs": {}, - "recordedDirentsInputs": {}, - "envVariables": {}, - "generatedRepoSpecs": { - "rpyo3c": { - "repoRuleId": "@@rules_rust+//crate_universe/private:crates_vendor.bzl%crates_vendor_remote_repository", - "attributes": { - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.bazel", - "defs_module": "@@rules_rust_pyo3+//3rdparty/crates:defs.bzl" + "strip_prefix": "clap-4.5.60", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"clap\",\n deps = [\n \"@crates__clap_builder-4.5.60//:clap_builder\",\n ],\n proc_macro_deps = [\n \"@crates__clap_derive-4.5.55//:clap_derive\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"color\",\n \"default\",\n \"derive\",\n \"error-context\",\n \"help\",\n \"std\",\n \"suggestions\",\n \"usage\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=clap\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"4.5.60\",\n)\n" } }, - "rpyo3c__anyhow-1.0.100": { + "crates__clap_builder-4.5.60": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "a23eb6b1614318a8071c9b2521f36b424b2c83db5eb3a0fead4a6c0809af6e61", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "24a241312cea5059b13574bb9b3861cabf758b879c15190b37b6d6fd63ab6876", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/anyhow/1.0.100/download" + "https://static.crates.io/crates/clap_builder/4.5.60/download" ], - "strip_prefix": "anyhow-1.0.100", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.anyhow-1.0.100.bazel" + "strip_prefix": "clap_builder-4.5.60", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"clap_builder\",\n deps = [\n \"@crates__anstream-0.6.21//:anstream\",\n \"@crates__anstyle-1.0.13//:anstyle\",\n \"@crates__clap_lex-1.0.0//:clap_lex\",\n \"@crates__strsim-0.11.1//:strsim\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"color\",\n \"error-context\",\n \"help\",\n \"std\",\n \"suggestions\",\n \"usage\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=clap_builder\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"4.5.60\",\n)\n" } }, - "rpyo3c__autocfg-1.5.0": { + "crates__clap_derive-4.5.55": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "c08606f8c3cbf4ce6ec8e28fb0014a2c086708fe954eaa885384a6165172e7e8", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "a92793da1a46a5f2a02a6f4c46c6496b28c43638adea8306fcb0caa1634f24e5", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/autocfg/1.5.0/download" + "https://static.crates.io/crates/clap_derive/4.5.55/download" ], - "strip_prefix": "autocfg-1.5.0", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.autocfg-1.5.0.bazel" + "strip_prefix": "clap_derive-4.5.55", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_proc_macro\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_proc_macro(\n name = \"clap_derive\",\n deps = [\n \"@crates__heck-0.5.0//:heck\",\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__quote-1.0.44//:quote\",\n \"@crates__syn-2.0.117//:syn\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=clap_derive\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"4.5.55\",\n)\n" } }, - "rpyo3c__goblin-0.10.1": { + "crates__clap_lex-1.0.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "d6a80adfd63bd7ffd94fefc3d22167880c440a724303080e5aa686fa36abaa96", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "3a822ea5bc7590f9d40f1ba12c0dc3c2760f3482c6984db1573ad11031420831", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/goblin/0.10.1/download" + "https://static.crates.io/crates/clap_lex/1.0.0/download" ], - "strip_prefix": "goblin-0.10.1", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.goblin-0.10.1.bazel" + "strip_prefix": "clap_lex-1.0.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"clap_lex\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=clap_lex\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.0\",\n)\n" } }, - "rpyo3c__heck-0.5.0": { + "crates__colorchoice-1.0.4": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "b05b61dc5112cbb17e4b6cd61790d9845d13888356391624cbe7e41efeac1e75", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/heck/0.5.0/download" + "https://static.crates.io/crates/colorchoice/1.0.4/download" ], - "strip_prefix": "heck-0.5.0", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.heck-0.5.0.bazel" + "strip_prefix": "colorchoice-1.0.4", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"colorchoice\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=colorchoice\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.4\",\n)\n" } }, - "rpyo3c__indoc-2.0.6": { + "crates__colored-3.1.1": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "f4c7245a08504955605670dbf141fceab975f15ca21570696aebe9d2e71576bd", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "faf9468729b8cbcea668e36183cb69d317348c2e08e994829fb56ebfdfbaac34", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/indoc/2.0.6/download" + "https://static.crates.io/crates/colored/3.1.1/download" ], - "strip_prefix": "indoc-2.0.6", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.indoc-2.0.6.bazel" + "strip_prefix": "colored-3.1.1", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"colored\",\n deps = select({\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [\n \"@crates__windows-sys-0.61.2//:windows_sys\", # cfg(windows)\n ],\n \"//conditions:default\": [],\n }),\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=colored\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"3.1.1\",\n)\n" } }, - "rpyo3c__itoa-1.0.15": { + "crates__diplomat-0.14.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "4a5f13b858c8d314ee3e8f639011f7ccefe71f97f96e50151fb991f267928e2c", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "9adb46b05e2f53dcf6a7dfc242e4ce9eb60c369b6b6eb10826a01e93167f59c6", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/itoa/1.0.15/download" + "https://static.crates.io/crates/diplomat/0.14.0/download" ], - "strip_prefix": "itoa-1.0.15", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.itoa-1.0.15.bazel" + "strip_prefix": "diplomat-0.14.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_proc_macro\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_proc_macro(\n name = \"diplomat\",\n deps = [\n \"@crates__diplomat_core-0.14.0//:diplomat_core\",\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__quote-1.0.44//:quote\",\n \"@crates__syn-2.0.117//:syn\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=diplomat\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.14.0\",\n)\n" } }, - "rpyo3c__libc-0.2.176": { + "crates__diplomat-runtime-0.14.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "58f929b4d672ea937a23a1ab494143d968337a5f47e56d0815df1e0890ddf174", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "0569bd3caaf13829da7ee4e83dbf9197a0e1ecd72772da6d08f0b4c9285c8d29", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/libc/0.2.176/download" + "https://static.crates.io/crates/diplomat-runtime/0.14.0/download" ], - "strip_prefix": "libc-0.2.176", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.libc-0.2.176.bazel" + "strip_prefix": "diplomat-runtime-0.14.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"diplomat_runtime\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=diplomat-runtime\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.14.0\",\n)\n" } }, - "rpyo3c__log-0.4.28": { + "crates__diplomat-tool-0.14.1": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "34080505efa8e45a4b816c349525ebe327ceaa8559756f0356cba97ef3bf7432", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "a69fa451d9a76f2c17bb0dd37603825a71f8199f64eb9bf9d2b6664695efe1e4", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/log/0.4.28/download" + "https://static.crates.io/crates/diplomat-tool/0.14.1/download" ], - "strip_prefix": "log-0.4.28", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.log-0.4.28.bazel" + "strip_prefix": "diplomat-tool-0.14.1", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"diplomat_tool\",\n deps = [\n \"@crates__askama-0.14.0//:askama\",\n \"@crates__clap-4.5.60//:clap\",\n \"@crates__colored-3.1.1//:colored\",\n \"@crates__diplomat_core-0.14.0//:diplomat_core\",\n \"@crates__heck-0.5.0//:heck\",\n \"@crates__indenter-0.3.4//:indenter\",\n \"@crates__itertools-0.14.0//:itertools\",\n \"@crates__pulldown-cmark-0.13.0//:pulldown_cmark\",\n \"@crates__quote-1.0.44//:quote\",\n \"@crates__serde-1.0.228//:serde\",\n \"@crates__syn-2.0.117//:syn\",\n \"@crates__syn-inline-mod-0.6.0//:syn_inline_mod\",\n \"@crates__toml-0.8.23//:toml\",\n ],\n proc_macro_deps = [\n \"@crates__displaydoc-0.2.5//:displaydoc\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=diplomat-tool\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.14.1\",\n)\n" } }, - "rpyo3c__memchr-2.7.6": { + "crates__diplomat_core-0.14.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "f52b00d39961fc5b2736ea853c9cc86238e165017a493d1d5c8eac6bdc4cc273", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "51731530ed7f2d4495019abc7df3744f53338e69e2863a6a64ae91821c763df1", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/memchr/2.7.6/download" + "https://static.crates.io/crates/diplomat_core/0.14.0/download" ], - "strip_prefix": "memchr-2.7.6", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.memchr-2.7.6.bazel" + "strip_prefix": "diplomat_core-0.14.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"diplomat_core\",\n deps = [\n \"@crates__either-1.15.0//:either\",\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__quote-1.0.44//:quote\",\n \"@crates__serde-1.0.228//:serde\",\n \"@crates__smallvec-1.15.1//:smallvec\",\n \"@crates__strck-1.0.0//:strck\",\n \"@crates__syn-2.0.117//:syn\",\n ],\n proc_macro_deps = [\n \"@crates__displaydoc-0.2.5//:displaydoc\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"displaydoc\",\n \"either\",\n \"hir\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=diplomat_core\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.14.0\",\n)\n" } }, - "rpyo3c__memoffset-0.9.1": { + "crates__displaydoc-0.2.5": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/memoffset/0.9.1/download" + "https://static.crates.io/crates/displaydoc/0.2.5/download" ], - "strip_prefix": "memoffset-0.9.1", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.memoffset-0.9.1.bazel" + "strip_prefix": "displaydoc-0.2.5", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_proc_macro\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_proc_macro(\n name = \"displaydoc\",\n deps = [\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__quote-1.0.44//:quote\",\n \"@crates__syn-2.0.117//:syn\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=displaydoc\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.2.5\",\n)\n" } }, - "rpyo3c__once_cell-1.21.3": { + "crates__either-1.15.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "42f5e15c9953c5e4ccceeb2e7382a716482c34515315f7b03532b8b4e8393d2d", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "48c757948c5ede0e46177b7add2e67155f70e33c07fea8284df6576da70b3719", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/once_cell/1.21.3/download" + "https://static.crates.io/crates/either/1.15.0/download" ], - "strip_prefix": "once_cell-1.21.3", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.once_cell-1.21.3.bazel" + "strip_prefix": "either-1.15.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"either\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"std\",\n \"use_std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=either\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.15.0\",\n)\n" } }, - "rpyo3c__plain-0.2.3": { + "crates__equivalent-1.0.2": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "b4596b6d070b27117e987119b4dac604f3c58cfb0b191112e24771b2faeac1a6", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/plain/0.2.3/download" + "https://static.crates.io/crates/equivalent/1.0.2/download" ], - "strip_prefix": "plain-0.2.3", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.plain-0.2.3.bazel" + "strip_prefix": "equivalent-1.0.2", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"equivalent\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2015\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=equivalent\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.2\",\n)\n" } }, - "rpyo3c__portable-atomic-1.11.1": { + "crates__getopts-0.2.24": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "f84267b20a16ea918e43c6a88433c2d54fa145c92a811b5b047ccbe153674483", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "cfe4fbac503b8d1f88e6676011885f34b7174f46e59956bba534ba83abded4df", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/portable-atomic/1.11.1/download" + "https://static.crates.io/crates/getopts/0.2.24/download" ], - "strip_prefix": "portable-atomic-1.11.1", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.portable-atomic-1.11.1.bazel" + "strip_prefix": "getopts-0.2.24", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"getopts\",\n deps = [\n \"@crates__unicode-width-0.2.2//:unicode_width\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"unicode\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=getopts\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.2.24\",\n)\n" } }, - "rpyo3c__proc-macro2-1.0.101": { + "crates__hashbrown-0.16.1": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "89ae43fd86e4158d6db51ad8e2b80f313af9cc74f5c0e03ccb87de09998732de", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/proc-macro2/1.0.101/download" + "https://static.crates.io/crates/hashbrown/0.16.1/download" ], - "strip_prefix": "proc-macro2-1.0.101", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.proc-macro2-1.0.101.bazel" + "strip_prefix": "hashbrown-0.16.1", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"hashbrown\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=hashbrown\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.16.1\",\n)\n" } }, - "rpyo3c__pyo3-0.26.0": { + "crates__heck-0.5.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "7ba0117f4212101ee6544044dae45abe1083d30ce7b29c4b5cbdfa2354e07383", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/pyo3/0.26.0/download" + "https://static.crates.io/crates/heck/0.5.0/download" ], - "strip_prefix": "pyo3-0.26.0", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.pyo3-0.26.0.bazel" + "strip_prefix": "heck-0.5.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"heck\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=heck\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.5.0\",\n)\n" } }, - "rpyo3c__pyo3-build-config-0.26.0": { + "crates__indenter-0.3.4": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "patch_args": [ - "-p1" - ], - "patches": [ - "@@rules_rust_pyo3+//3rdparty/patches:resolve_cross_compile_config_path.patch" - ], - "sha256": "4fc6ddaf24947d12a9aa31ac65431fb1b851b8f4365426e182901eabfb87df5f", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "964de6e86d545b246d84badc0fef527924ace5134f30641c203ef52ba83f58d5", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/pyo3-build-config/0.26.0/download" + "https://static.crates.io/crates/indenter/0.3.4/download" ], - "strip_prefix": "pyo3-build-config-0.26.0", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.pyo3-build-config-0.26.0.bazel" + "strip_prefix": "indenter-0.3.4", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"indenter\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2018\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=indenter\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.3.4\",\n)\n" } }, - "rpyo3c__pyo3-ffi-0.26.0": { + "crates__indexmap-2.13.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "025474d3928738efb38ac36d4744a74a400c901c7596199e20e45d98eb194105", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "7714e70437a7dc3ac8eb7e6f8df75fd8eb422675fc7678aff7364301092b1017", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/pyo3-ffi/0.26.0/download" + "https://static.crates.io/crates/indexmap/2.13.0/download" ], - "strip_prefix": "pyo3-ffi-0.26.0", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.pyo3-ffi-0.26.0.bazel" + "strip_prefix": "indexmap-2.13.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"indexmap\",\n deps = [\n \"@crates__equivalent-1.0.2//:equivalent\",\n \"@crates__hashbrown-0.16.1//:hashbrown\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=indexmap\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"2.13.0\",\n)\n" } }, - "rpyo3c__pyo3-introspection-0.26.0": { + "crates__is_terminal_polyfill-1.70.2": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "0c3470294ce4d56fa74c996e4244ec3ac04db0c621975993e62ff725844ab509", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "a6cb138bb79a146c1bd460005623e142ef0181e3d0219cb493e02f7d08a35695", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/pyo3-introspection/0.26.0/download" + "https://static.crates.io/crates/is_terminal_polyfill/1.70.2/download" ], - "strip_prefix": "pyo3-introspection-0.26.0", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.pyo3-introspection-0.26.0.bazel" + "strip_prefix": "is_terminal_polyfill-1.70.2", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"is_terminal_polyfill\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=is_terminal_polyfill\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.70.2\",\n)\n" } }, - "rpyo3c__pyo3-macros-0.26.0": { + "crates__itertools-0.14.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "2e64eb489f22fe1c95911b77c44cc41e7c19f3082fc81cce90f657cdc42ffded", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "2b192c782037fadd9cfa75548310488aabdbf3d2da73885b31bd0abd03351285", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/pyo3-macros/0.26.0/download" + "https://static.crates.io/crates/itertools/0.14.0/download" ], - "strip_prefix": "pyo3-macros-0.26.0", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.pyo3-macros-0.26.0.bazel" + "strip_prefix": "itertools-0.14.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"itertools\",\n deps = [\n \"@crates__either-1.15.0//:either\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"use_alloc\",\n \"use_std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2018\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=itertools\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.14.0\",\n)\n" } }, - "rpyo3c__pyo3-macros-backend-0.26.0": { + "crates__itoa-1.0.17": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "100246c0ecf400b475341b8455a9213344569af29a3c841d29270e53102e0fcf", - "type": "tar.gz", - "urls": [ - "https://static.crates.io/crates/pyo3-macros-backend/0.26.0/download" - ], - "strip_prefix": "pyo3-macros-backend-0.26.0", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.pyo3-macros-backend-0.26.0.bazel" + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "92ecc6618181def0457392ccd0ee51198e065e016d1d527a7ac1b6dc7c1f09d2", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/itoa/1.0.17/download" + ], + "strip_prefix": "itoa-1.0.17", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"itoa\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=itoa\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.17\",\n)\n" + } + }, + "crates__memchr-2.8.0": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "f8ca58f447f06ed17d5fc4043ce1b10dd205e060fb3ce5b979b8ed8e59ff3f79", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/memchr/2.8.0/download" + ], + "strip_prefix": "memchr-2.8.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"memchr\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"alloc\",\n \"default\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=memchr\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"2.8.0\",\n)\n" + } + }, + "crates__once_cell_polyfill-1.70.2": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "384b8ab6d37215f3c5301a95a4accb5d64aa607f1fcb26a11b5303878451b4fe", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/once_cell_polyfill/1.70.2/download" + ], + "strip_prefix": "once_cell_polyfill-1.70.2", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"once_cell_polyfill\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=once_cell_polyfill\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.70.2\",\n)\n" + } + }, + "crates__percent-encoding-2.3.2": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/percent-encoding/2.3.2/download" + ], + "strip_prefix": "percent-encoding-2.3.2", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"percent_encoding\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"alloc\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2018\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=percent-encoding\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"2.3.2\",\n)\n" + } + }, + "crates__proc-macro2-1.0.106": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "8fd00f0bb2e90d81d1044c2b32617f68fcb9fa3bb7640c23e9c748e53fb30934", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/proc-macro2/1.0.106/download" + ], + "strip_prefix": "proc-macro2-1.0.106", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"proc_macro2\",\n deps = [\n \"@crates__proc-macro2-1.0.106//:build_script_build\",\n \"@crates__unicode-ident-1.0.24//:unicode_ident\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"proc-macro\",\n \"span-locations\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=proc-macro2\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.106\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"proc-macro\",\n \"span-locations\",\n ],\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"proc-macro2\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=proc-macro2\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.106\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" } }, - "rpyo3c__quote-1.0.41": { + "crates__pulldown-cmark-0.13.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "ce25767e7b499d1b604768e7cde645d14cc8584231ea6b295e9c9eb22c02e1d1", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "1e8bbe1a966bd2f362681a44f6edce3c2310ac21e4d5067a6e7ec396297a6ea0", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/quote/1.0.41/download" + "https://static.crates.io/crates/pulldown-cmark/0.13.0/download" ], - "strip_prefix": "quote-1.0.41", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.quote-1.0.41.bazel" + "strip_prefix": "pulldown-cmark-0.13.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"pulldown_cmark\",\n deps = [\n \"@crates__bitflags-2.11.0//:bitflags\",\n \"@crates__getopts-0.2.24//:getopts\",\n \"@crates__memchr-2.8.0//:memchr\",\n \"@crates__pulldown-cmark-0.13.0//:build_script_build\",\n \"@crates__pulldown-cmark-escape-0.11.0//:pulldown_cmark_escape\",\n \"@crates__unicase-2.9.0//:unicase\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"getopts\",\n \"html\",\n \"pulldown-cmark-escape\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=pulldown-cmark\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.13.0\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"getopts\",\n \"html\",\n \"pulldown-cmark-escape\",\n ],\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"pulldown-cmark\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=pulldown-cmark\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"0.13.0\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" } }, - "rpyo3c__ryu-1.0.20": { + "crates__pulldown-cmark-escape-0.11.0": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "28d3b2b1366ec20994f1fd18c3c594f05c5dd4bc44d8bb0c1c632c8d6829481f", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "007d8adb5ddab6f8e3f491ac63566a7d5002cc7ed73901f72057943fa71ae1ae", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/ryu/1.0.20/download" + "https://static.crates.io/crates/pulldown-cmark-escape/0.11.0/download" ], - "strip_prefix": "ryu-1.0.20", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.ryu-1.0.20.bazel" + "strip_prefix": "pulldown-cmark-escape-0.11.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"pulldown_cmark_escape\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=pulldown-cmark-escape\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.11.0\",\n)\n" } }, - "rpyo3c__scroll-0.13.0": { + "crates__quote-1.0.44": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "c1257cd4248b4132760d6524d6dda4e053bc648c9070b960929bf50cfb1e7add", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "21b2ebcf727b7760c461f091f9f0f539b77b8e87f2fd88131e7f1b433b3cece4", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/scroll/0.13.0/download" + "https://static.crates.io/crates/quote/1.0.44/download" ], - "strip_prefix": "scroll-0.13.0", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.scroll-0.13.0.bazel" + "strip_prefix": "quote-1.0.44", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"quote\",\n deps = [\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__quote-1.0.44//:build_script_build\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"proc-macro\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=quote\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.44\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"proc-macro\",\n ],\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"quote\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=quote\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.44\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" } }, - "rpyo3c__scroll_derive-0.13.1": { + "crates__rustc-hash-2.1.1": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "ed76efe62313ab6610570951494bdaa81568026e0318eaa55f167de70eeea67d", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "357703d41365b4b27c590e3ed91eabb1b663f07c4c084095e60cbed4362dff0d", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/scroll_derive/0.13.1/download" + "https://static.crates.io/crates/rustc-hash/2.1.1/download" ], - "strip_prefix": "scroll_derive-0.13.1", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.scroll_derive-0.13.1.bazel" + "strip_prefix": "rustc-hash-2.1.1", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"rustc_hash\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=rustc-hash\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"2.1.1\",\n)\n" } }, - "rpyo3c__serde-1.0.228": { + "crates__serde-1.0.228": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, "sha256": "9a8e94ea7f378bd32cbbd37198a4a91436180c5bb472411e48b5ec2e2124ae9e", "type": "tar.gz", "urls": [ "https://static.crates.io/crates/serde/1.0.228/download" ], "strip_prefix": "serde-1.0.228", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.serde-1.0.228.bazel" + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"serde\",\n deps = [\n \"@crates__serde-1.0.228//:build_script_build\",\n \"@crates__serde_core-1.0.228//:serde_core\",\n ],\n proc_macro_deps = [\n \"@crates__serde_derive-1.0.228//:serde_derive\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"alloc\",\n \"default\",\n \"derive\",\n \"serde_derive\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.228\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"alloc\",\n \"default\",\n \"derive\",\n \"serde_derive\",\n \"std\",\n ],\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"serde\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.228\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" } }, - "rpyo3c__serde_core-1.0.228": { + "crates__serde_core-1.0.228": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, "sha256": "41d385c7d4ca58e59fc732af25c3983b67ac852c1a25000afe1175de458b67ad", "type": "tar.gz", "urls": [ "https://static.crates.io/crates/serde_core/1.0.228/download" ], "strip_prefix": "serde_core-1.0.228", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.serde_core-1.0.228.bazel" + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"serde_core\",\n deps = [\n \"@crates__serde_core-1.0.228//:build_script_build\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"alloc\",\n \"result\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde_core\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.228\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"alloc\",\n \"result\",\n \"std\",\n ],\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"serde_core\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde_core\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.228\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" } }, - "rpyo3c__serde_derive-1.0.228": { + "crates__serde_derive-1.0.228": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, "sha256": "d540f220d3187173da220f885ab66608367b6574e925011a9353e4badda91d79", "type": "tar.gz", "urls": [ "https://static.crates.io/crates/serde_derive/1.0.228/download" ], "strip_prefix": "serde_derive-1.0.228", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.serde_derive-1.0.228.bazel" + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_proc_macro\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_proc_macro(\n name = \"serde_derive\",\n deps = [\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__quote-1.0.44//:quote\",\n \"@crates__syn-2.0.117//:syn\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde_derive\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.228\",\n)\n" + } + }, + "crates__serde_json-1.0.149": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "83fc039473c5595ace860d8c4fafa220ff474b3fc6bfdb4293327f1a37e94d86", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/serde_json/1.0.149/download" + ], + "strip_prefix": "serde_json-1.0.149", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"serde_json\",\n deps = [\n \"@crates__itoa-1.0.17//:itoa\",\n \"@crates__memchr-2.8.0//:memchr\",\n \"@crates__serde_core-1.0.228//:serde_core\",\n \"@crates__serde_json-1.0.149//:build_script_build\",\n \"@crates__zmij-1.0.21//:zmij\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde_json\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.149\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"std\",\n ],\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"serde_json\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde_json\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.149\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" + } + }, + "crates__serde_spanned-0.6.9": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "bf41e0cfaf7226dca15e8197172c295a782857fcb97fad1808a166870dee75a3", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/serde_spanned/0.6.9/download" + ], + "strip_prefix": "serde_spanned-0.6.9", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"serde_spanned\",\n deps = [\n \"@crates__serde-1.0.228//:serde\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"serde\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=serde_spanned\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.6.9\",\n)\n" + } + }, + "crates__smallvec-1.15.1": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "67b1b7a3b5fe4f1376887184045fcf45c69e92af734b7aaddc05fb777b6fbd03", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/smallvec/1.15.1/download" + ], + "strip_prefix": "smallvec-1.15.1", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"smallvec\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2018\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=smallvec\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.15.1\",\n)\n" + } + }, + "crates__strck-1.0.0": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "42316e70da376f3d113a68d138a60d8a9883c604fe97942721ec2068dab13a9f", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/strck/1.0.0/download" + ], + "strip_prefix": "strck-1.0.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"strck\",\n deps = [\n \"@crates__unicode-ident-1.0.24//:unicode_ident\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"ident\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=strck\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.0\",\n)\n" + } + }, + "crates__strsim-0.11.1": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/strsim/0.11.1/download" + ], + "strip_prefix": "strsim-0.11.1", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"strsim\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2015\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=strsim\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.11.1\",\n)\n" + } + }, + "crates__syn-2.0.117": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "e665b8803e7b1d2a727f4023456bbbbe74da67099c585258af0ad9c5013b9b99", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/syn/2.0.117/download" + ], + "strip_prefix": "syn-2.0.117", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"syn\",\n deps = [\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__quote-1.0.44//:quote\",\n \"@crates__unicode-ident-1.0.24//:unicode_ident\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"clone-impls\",\n \"default\",\n \"derive\",\n \"extra-traits\",\n \"full\",\n \"parsing\",\n \"printing\",\n \"proc-macro\",\n \"visit-mut\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=syn\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"2.0.117\",\n)\n" + } + }, + "crates__syn-inline-mod-0.6.0": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "2fa6dca1fdb7b2ed46dd534a326725419d4fb10f23d8c85a8b2860e5eb25d0f9", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/syn-inline-mod/0.6.0/download" + ], + "strip_prefix": "syn-inline-mod-0.6.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"syn_inline_mod\",\n deps = [\n \"@crates__proc-macro2-1.0.106//:proc_macro2\",\n \"@crates__syn-2.0.117//:syn\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2018\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=syn-inline-mod\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.6.0\",\n)\n" + } + }, + "crates__toml-0.8.23": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "dc1beb996b9d83529a9e75c17a1686767d148d70663143c7854d8b4a09ced362", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/toml/0.8.23/download" + ], + "strip_prefix": "toml-0.8.23", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"toml\",\n deps = [\n \"@crates__serde-1.0.228//:serde\",\n \"@crates__serde_spanned-0.6.9//:serde_spanned\",\n \"@crates__toml_datetime-0.6.11//:toml_datetime\",\n \"@crates__toml_edit-0.22.27//:toml_edit\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n \"display\",\n \"parse\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=toml\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.8.23\",\n)\n" + } + }, + "crates__toml_datetime-0.6.11": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "22cddaf88f4fbc13c51aebbf5f8eceb5c7c5a9da2ac40a13519eb5b0a0e8f11c", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/toml_datetime/0.6.11/download" + ], + "strip_prefix": "toml_datetime-0.6.11", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"toml_datetime\",\n deps = [\n \"@crates__serde-1.0.228//:serde\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"serde\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=toml_datetime\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.6.11\",\n)\n" + } + }, + "crates__toml_edit-0.22.27": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "41fe8c660ae4257887cf66394862d21dbca4a6ddd26f04a3560410406a2f819a", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/toml_edit/0.22.27/download" + ], + "strip_prefix": "toml_edit-0.22.27", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"toml_edit\",\n deps = [\n \"@crates__indexmap-2.13.0//:indexmap\",\n \"@crates__serde-1.0.228//:serde\",\n \"@crates__serde_spanned-0.6.9//:serde_spanned\",\n \"@crates__toml_datetime-0.6.11//:toml_datetime\",\n \"@crates__toml_write-0.1.2//:toml_write\",\n \"@crates__winnow-0.7.14//:winnow\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"display\",\n \"parse\",\n \"serde\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=toml_edit\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.22.27\",\n)\n" + } + }, + "crates__toml_write-0.1.2": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "5d99f8c9a7727884afe522e9bd5edbfc91a3312b36a77b5fb8926e4c31a41801", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/toml_write/0.1.2/download" + ], + "strip_prefix": "toml_write-0.1.2", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"toml_write\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"alloc\",\n \"default\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=toml_write\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.1.2\",\n)\n" + } + }, + "crates__unicase-2.9.0": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "dbc4bc3a9f746d862c45cb89d705aa10f187bb96c76001afab07a0d35ce60142", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/unicase/2.9.0/download" + ], + "strip_prefix": "unicase-2.9.0", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"unicase\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2018\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=unicase\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"2.9.0\",\n)\n" + } + }, + "crates__unicode-ident-1.0.24": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/unicode-ident/1.0.24/download" + ], + "strip_prefix": "unicode-ident-1.0.24", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"unicode_ident\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=unicode-ident\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.24\",\n)\n" + } + }, + "crates__unicode-width-0.2.2": { + "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", + "attributes": { + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "b4ac048d71ede7ee76d585517add45da530660ef4390e49b098733c6e897f254", + "type": "tar.gz", + "urls": [ + "https://static.crates.io/crates/unicode-width/0.2.2/download" + ], + "strip_prefix": "unicode-width-0.2.2", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"unicode_width\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"cjk\",\n \"default\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=unicode-width\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.2.2\",\n)\n" } }, - "rpyo3c__serde_json-1.0.145": { + "crates__utf8parse-0.2.2": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "402a6f66d8c709116cf22f558eab210f5a50187f702eb4d7e5ef38d9a7f1c79c", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/serde_json/1.0.145/download" + "https://static.crates.io/crates/utf8parse/0.2.2/download" ], - "strip_prefix": "serde_json-1.0.145", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.serde_json-1.0.145.bazel" + "strip_prefix": "utf8parse-0.2.2", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"utf8parse\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"default\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2018\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=utf8parse\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.2.2\",\n)\n" } }, - "rpyo3c__syn-2.0.106": { + "crates__windows-link-0.2.1": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "ede7c438028d4436d71104916910f5bb611972c5cfd7f89b8300a8186e6fada6", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/syn/2.0.106/download" + "https://static.crates.io/crates/windows-link/0.2.1/download" ], - "strip_prefix": "syn-2.0.106", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.syn-2.0.106.bazel" + "strip_prefix": "windows-link-0.2.1", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"windows_link\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=windows-link\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.2.1\",\n)\n" } }, - "rpyo3c__target-lexicon-0.13.3": { + "crates__windows-sys-0.61.2": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "df7f62577c25e07834649fc3b39fafdc597c0a3527dc1c60129201ccfcbaa50c", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/target-lexicon/0.13.3/download" + "https://static.crates.io/crates/windows-sys/0.61.2/download" ], - "strip_prefix": "target-lexicon-0.13.3", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.target-lexicon-0.13.3.bazel" + "strip_prefix": "windows-sys-0.61.2", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"windows_sys\",\n deps = [\n \"@crates__windows-link-0.2.1//:windows_link\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"Win32\",\n \"Win32_Foundation\",\n \"Win32_System\",\n \"Win32_System_Console\",\n \"default\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=windows-sys\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.61.2\",\n)\n" } }, - "rpyo3c__unicode-ident-1.0.19": { + "crates__winnow-0.7.14": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "f63a545481291138910575129486daeaf8ac54aee4387fe7906919f7830c7d9d", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "5a5364e9d77fcdeeaa6062ced926ee3381faa2ee02d3eb83a5c27a8825540829", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/unicode-ident/1.0.19/download" + "https://static.crates.io/crates/winnow/0.7.14/download" ], - "strip_prefix": "unicode-ident-1.0.19", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.unicode-ident-1.0.19.bazel" + "strip_prefix": "winnow-0.7.14", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\"@rules_rust//cargo:defs.bzl\", \"cargo_toml_env_vars\")\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"winnow\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_features = [\n \"alloc\",\n \"default\",\n \"std\",\n ],\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=winnow\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"0.7.14\",\n)\n" } }, - "rpyo3c__unindent-0.2.4": { + "crates__zmij-1.0.21": { "repoRuleId": "@@bazel_tools//tools/build_defs/repo:http.bzl%http_archive", "attributes": { - "sha256": "7264e107f553ccae879d21fbea1d6724ac785e8c3bfc762137959b5802826ef3", + "patch_args": [], + "patch_tool": "", + "patches": [], + "remote_patch_strip": 1, + "sha256": "b8848ee67ecc8aedbaf3e4122217aff892639231befc6a1b58d29fff4c2cabaa", "type": "tar.gz", "urls": [ - "https://static.crates.io/crates/unindent/0.2.4/download" + "https://static.crates.io/crates/zmij/1.0.21/download" ], - "strip_prefix": "unindent-0.2.4", - "build_file": "@@rules_rust_pyo3+//3rdparty/crates:BUILD.unindent-0.2.4.bazel" + "strip_prefix": "zmij-1.0.21", + "build_file_content": "###############################################################################\n# @generated\n# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To \n# regenerate this file, run the following:\n#\n# bazel mod show_repo 'dv'\n###############################################################################\n\nload(\n \"@rules_rust//cargo:defs.bzl\",\n \"cargo_build_script\",\n \"cargo_toml_env_vars\",\n)\n\nload(\"@rules_rust//rust:defs.bzl\", \"rust_library\")\n\n# buildifier: disable=bzl-visibility\nload(\"@rules_rust//crate_universe/private:selects.bzl\", \"selects\")\n\npackage(default_visibility = [\"//visibility:public\"])\n\ncargo_toml_env_vars(\n name = \"cargo_toml_env_vars\",\n src = \"Cargo.toml\",\n)\n\nrust_library(\n name = \"zmij\",\n deps = [\n \"@crates__zmij-1.0.21//:build_script_build\",\n ],\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_root = \"src/lib.rs\",\n edition = \"2021\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=zmij\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n target_compatible_with = select({\n \"@rules_rust//rust/platform:aarch64-apple-darwin\": [],\n \"@rules_rust//rust/platform:aarch64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:wasm32-unknown-unknown\": [],\n \"@rules_rust//rust/platform:wasm32-wasip1\": [],\n \"@rules_rust//rust/platform:x86_64-pc-windows-msvc\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-linux-gnu\": [],\n \"@rules_rust//rust/platform:x86_64-unknown-nixos-gnu\": [],\n \"//conditions:default\": [\"@platforms//:incompatible\"],\n }),\n version = \"1.0.21\",\n)\n\ncargo_build_script(\n name = \"_bs\",\n compile_data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \"**/*.rs\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n crate_name = \"build_script_build\",\n crate_root = \"build.rs\",\n data = glob(\n allow_empty = True,\n include = [\"**\"],\n exclude = [\n \"**/* *\",\n \".tmp_git_root/**/*\",\n \"BUILD\",\n \"BUILD.bazel\",\n \"WORKSPACE\",\n \"WORKSPACE.bazel\",\n ],\n ),\n edition = \"2021\",\n pkg_name = \"zmij\",\n rustc_env_files = [\n \":cargo_toml_env_vars\",\n ],\n rustc_flags = [\n \"--cap-lints=allow\",\n ],\n srcs = glob(\n allow_empty = True,\n include = [\"**/*.rs\"],\n ),\n tags = [\n \"cargo-bazel\",\n \"crate-name=zmij\",\n \"manual\",\n \"noclippy\",\n \"norustfmt\",\n ],\n version = \"1.0.21\",\n visibility = [\"//visibility:private\"],\n)\n\nalias(\n name = \"build_script_build\",\n actual = \":_bs\",\n tags = [\"manual\"],\n)\n" } } }, "moduleExtensionMetadata": { - "explicitRootModuleDirectDeps": [ - "rpyo3c", - "rpyo3c__pyo3-0.26.0", - "rpyo3c__pyo3-ffi-0.26.0", - "rpyo3c__pyo3-introspection-0.26.0" - ], - "explicitRootModuleDirectDevDeps": [], "useAllRepos": "NO", "reproducible": false }, "recordedRepoMappingEntries": [ [ - "rules_rust+", + "bazel_features+", + "bazel_features_globals", + "bazel_features++version_extension+bazel_features_globals" + ], + [ + "bazel_features+", + "bazel_features_version", + "bazel_features++version_extension+bazel_features_version" + ], + [ + "rules_cc+", "bazel_tools", "bazel_tools" ], [ - "rules_rust_pyo3+", + "rules_cc+", + "rules_cc", + "rules_cc+" + ], + [ + "rules_rust+", + "bazel_features", + "bazel_features+" + ], + [ + "rules_rust+", "bazel_skylib", "bazel_skylib+" ], [ - "rules_rust_pyo3+", + "rules_rust+", "bazel_tools", "bazel_tools" ], [ - "rules_rust_pyo3+", - "rpyo3c", - "rules_rust_pyo3++rust_ext+rpyo3c" + "rules_rust+", + "rules_cc", + "rules_cc+" ], [ - "rules_rust_pyo3+", + "rules_rust+", "rules_rust", "rules_rust+" ] diff --git a/README.md b/README.md index 9765276..ef11653 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,14 @@ DV is a package that keeps track of units, and allows you to perform math while - Java (Planned on [GH-6](https://github.com/alextac98/dv/issues/6)) - Matlab (Planned on [GH-7](https://github.com/alextac98/dv/issues/7)) +## Repository structure + +- `core/`: Rust core logic and the published Rust crate +- `core/ffi/diplomat/`: Rust-owned Diplomat bridge crate +- `python/`: Python package, wrapper, tests, and Bazel Python binding targets +- `c/`: C binding targets +- `cpp/`: C++ binding targets and the `dv.hpp` compatibility wrapper + ## Contributing to the project This project is always a work in progress. We welcome contributions, small or large! Please visit this page to learn more! https://dv.alextac.com/docs/category/developers-guides @@ -27,4 +35,4 @@ This project is licensed under the Apache License, Version 2.0 (the "License"). Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. -Copyright © 2025 Alex Tacescu \ No newline at end of file +Copyright © 2026 Alex Tacescu diff --git a/VERSION.toml b/VERSION.toml index 0751cca..c908644 100644 --- a/VERSION.toml +++ b/VERSION.toml @@ -6,4 +6,4 @@ major = 0 minor = 3 -patch = 3 +patch = 4 diff --git a/c/BUILD.bazel b/c/BUILD.bazel new file mode 100644 index 0000000..5aee4ff --- /dev/null +++ b/c/BUILD.bazel @@ -0,0 +1,33 @@ +load("@rules_cc//cc:defs.bzl", "cc_library") + +package(default_visibility = ["//visibility:public"]) + +genrule( + name = "codegen_c", + srcs = ["//core/ffi/diplomat:src/lib.rs"], + outs = [ + "BaseUnits.d.h", + "BaseUnits.h", + "DvError.d.h", + "DvError.h", + "DimensionalVariable.d.h", + "DimensionalVariable.h", + "diplomat_runtime.h", + ], + tools = ["//tools/diplomat_codegen:diplomat_codegen"], + cmd = "$(location //tools/diplomat_codegen:diplomat_codegen) c $(RULEDIR) --entry $(location //core/ffi/diplomat:src/lib.rs)", +) + +filegroup( + name = "generated_headers", + srcs = [":codegen_c"], +) + +cc_library( + name = "dv_c", + hdrs = [":generated_headers"], + includes = ["."], + deps = [ + "//core/ffi/diplomat:dv_diplomat_capi_static", + ], +) diff --git a/c/README.md b/c/README.md new file mode 100644 index 0000000..ab668a2 --- /dev/null +++ b/c/README.md @@ -0,0 +1,5 @@ +# dv C Bindings + +The Rust Diplomat bridge lives in `core/ffi/diplomat/`, while the Bazel-facing C binding target lives in this directory. + +- C target: `//c:dv_c` diff --git a/core/Cargo.toml b/core/Cargo.toml index 17620b7..4c2294f 100644 --- a/core/Cargo.toml +++ b/core/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "dv" -version = "0.3.3" +version = "0.3.4" edition = "2021" authors = [ "Alex Tacescu ",] description = "Core Rust library for DimensionalVariable, a multi-language library for handling physical quantities with units." diff --git a/core/ffi/diplomat/BUILD.bazel b/core/ffi/diplomat/BUILD.bazel new file mode 100644 index 0000000..61836b0 --- /dev/null +++ b/core/ffi/diplomat/BUILD.bazel @@ -0,0 +1,35 @@ +load("@rules_rust//rust:defs.bzl", "rust_library", "rust_static_library") + +package(default_visibility = ["//visibility:public"]) + +exports_files([ + "Cargo.toml", + "src/lib.rs", +]) + +rust_library( + name = "dv_diplomat_bridge", + srcs = ["src/lib.rs"], + edition = "2021", + proc_macro_deps = [ + "@crates//:diplomat", + ], + deps = [ + "//core:dv_rs", + "@crates//:diplomat-runtime", + ], +) + +rust_static_library( + name = "dv_diplomat_capi_static", + srcs = ["src/lib.rs"], + crate_name = "dv_diplomat_bridge", + edition = "2021", + proc_macro_deps = [ + "@crates//:diplomat", + ], + deps = [ + "//core:dv_rs", + "@crates//:diplomat-runtime", + ], +) diff --git a/core/ffi/diplomat/Cargo.toml b/core/ffi/diplomat/Cargo.toml new file mode 100644 index 0000000..1751a3f --- /dev/null +++ b/core/ffi/diplomat/Cargo.toml @@ -0,0 +1,21 @@ +[package] +name = "dv_diplomat_bridge" +version = "0.1.0" +edition = "2021" +authors = ["Alex Tacescu "] +license = "Apache-2.0" +description = "Diplomat bridge for dv (DimensionalVariable)" +publish = false + +[lib] +name = "dv_diplomat_bridge" +path = "src/lib.rs" +crate-type = ["rlib", "staticlib", "cdylib"] + +[dependencies.dv_rs] +package = "dv" +path = "../.." + +[dependencies] +diplomat = "0.14.0" +diplomat-runtime = "0.14.0" diff --git a/core/ffi/diplomat/src/lib.rs b/core/ffi/diplomat/src/lib.rs new file mode 100644 index 0000000..3247936 --- /dev/null +++ b/core/ffi/diplomat/src/lib.rs @@ -0,0 +1,248 @@ +#![allow(clippy::needless_return)] + +#[diplomat::bridge] +pub mod ffi { + use core::fmt::Write as _; + use diplomat_runtime::DiplomatWrite; + use dv_rs::DimensionalVariable as CoreDV; + use dv_rs::units; + + fn into_boxed_dv(dv: CoreDV) -> Box { + Box::new(DimensionalVariable(dv)) + } + + fn into_boxed_error(error: String) -> Box { + Box::new(DvError(error)) + } + + fn clone_core(dv: &CoreDV) -> CoreDV { + CoreDV { + value: dv.value, + unit: dv.unit, + } + } + + #[diplomat::rust_link(dv_rs::units::BASE_UNITS_SIZE, Mod)] + pub struct BaseUnits { + pub m: f64, + pub kg: f64, + pub s: f64, + pub k: f64, + pub a: f64, + pub mol: f64, + pub cd: f64, + pub rad: f64, + } + + #[diplomat::opaque] + pub struct DimensionalVariable(CoreDV); + + #[diplomat::opaque] + pub struct DvError(String); + + impl DvError { + pub fn to_string(&self, to: &mut DiplomatWrite) -> Result<(), ()> { + write!(to, "{}", self.0).map_err(|_| ()) + } + } + + impl DimensionalVariable { + pub fn new(value: f64, unit: &str) -> Result, Box> { + CoreDV::new(value, unit).map(into_boxed_dv).map_err(into_boxed_error) + } + + pub fn asin_scalar(x: f64) -> Result, Box> { + dv_rs::asin(x).map(into_boxed_dv).map_err(into_boxed_error) + } + + pub fn acos_scalar(x: f64) -> Result, Box> { + dv_rs::acos(x).map(into_boxed_dv).map_err(into_boxed_error) + } + + pub fn atan_scalar(x: f64) -> Result, Box> { + dv_rs::atan(x).map(into_boxed_dv).map_err(into_boxed_error) + } + + pub fn base_units_size() -> usize { + units::BASE_UNITS_SIZE + } + + pub fn value(&self) -> f64 { + self.0.value() + } + + pub fn value_in(&self, unit: &str) -> Result> { + self.0.value_in(unit).map_err(into_boxed_error) + } + + pub fn is_unitless(&self) -> bool { + self.0.is_unitless() + } + + pub fn base_units(&self) -> BaseUnits { + let u = self.0.unit(); + BaseUnits { + m: u[0], + kg: u[1], + s: u[2], + k: u[3], + a: u[4], + mol: u[5], + cd: u[6], + rad: u[7], + } + } + + pub fn add(&self, other: &DimensionalVariable) -> Result, Box> { + self.0.try_add(&other.0).map(into_boxed_dv).map_err(into_boxed_error) + } + + pub fn sub(&self, other: &DimensionalVariable) -> Result, Box> { + self.0.try_sub(&other.0).map(into_boxed_dv).map_err(into_boxed_error) + } + + pub fn mul(&self, other: &DimensionalVariable) -> Box { + into_boxed_dv(&self.0 * &other.0) + } + + pub fn div(&self, other: &DimensionalVariable) -> Box { + into_boxed_dv(&self.0 / &other.0) + } + + pub fn mul_scalar(&self, scalar: f64) -> Box { + into_boxed_dv(&self.0 * scalar) + } + + pub fn div_scalar(&self, scalar: f64) -> Box { + into_boxed_dv(&self.0 / scalar) + } + + pub fn rdiv_scalar(&self, scalar: f64) -> Box { + into_boxed_dv(scalar / &self.0) + } + + pub fn powi(&self, exp: i32) -> Box { + into_boxed_dv(self.0.powi(exp)) + } + + pub fn powf(&self, exp: f64) -> Result, Box> { + self.0.powf(exp).map(into_boxed_dv).map_err(into_boxed_error) + } + + pub fn sqrt(&self) -> Result, Box> { + self.0.sqrt().map(into_boxed_dv).map_err(into_boxed_error) + } + + pub fn ln(&self) -> Result, Box> { + self.0 + .ln() + .map(|v| CoreDV { value: v, unit: [0.0; units::BASE_UNITS_SIZE] }) + .map(into_boxed_dv) + .map_err(into_boxed_error) + } + + pub fn log2(&self) -> Result, Box> { + self.0 + .log2() + .map(|v| CoreDV { value: v, unit: [0.0; units::BASE_UNITS_SIZE] }) + .map(into_boxed_dv) + .map_err(into_boxed_error) + } + + pub fn log10(&self) -> Result, Box> { + self.0 + .log10() + .map(|v| CoreDV { value: v, unit: [0.0; units::BASE_UNITS_SIZE] }) + .map(into_boxed_dv) + .map_err(into_boxed_error) + } + + pub fn sin(&self) -> Result, Box> { + self.0 + .sin() + .map(|v| CoreDV { value: v, unit: [0.0; units::BASE_UNITS_SIZE] }) + .map(into_boxed_dv) + .map_err(into_boxed_error) + } + + pub fn cos(&self) -> Result, Box> { + self.0 + .cos() + .map(|v| CoreDV { value: v, unit: [0.0; units::BASE_UNITS_SIZE] }) + .map(into_boxed_dv) + .map_err(into_boxed_error) + } + + pub fn tan(&self) -> Result, Box> { + self.0 + .tan() + .map(|v| CoreDV { value: v, unit: [0.0; units::BASE_UNITS_SIZE] }) + .map(into_boxed_dv) + .map_err(into_boxed_error) + } + + pub fn asin(&self) -> Result, Box> { + self.0.asin().map(into_boxed_dv).map_err(into_boxed_error) + } + + pub fn acos(&self) -> Result, Box> { + self.0.acos().map(into_boxed_dv).map_err(into_boxed_error) + } + + pub fn atan(&self) -> Result, Box> { + self.0.atan().map(into_boxed_dv).map_err(into_boxed_error) + } + + pub fn neg(&self) -> Box { + into_boxed_dv(self.0.neg()) + } + + pub fn abs(&self) -> Box { + into_boxed_dv(self.0.abs()) + } + + pub fn equals(&self, other: &DimensionalVariable) -> bool { + self.0 == other.0 + } + + pub fn not_equals(&self, other: &DimensionalVariable) -> bool { + self.0 != other.0 + } + + pub fn less_than(&self, other: &DimensionalVariable) -> Result> { + self.0 + .partial_cmp(&other.0) + .map(|o| o.is_lt()) + .ok_or_else(|| into_boxed_error("Incompatible units for comparison".to_string())) + } + + pub fn less_equal(&self, other: &DimensionalVariable) -> Result> { + self.0 + .partial_cmp(&other.0) + .map(|o| o.is_lt() || o.is_eq()) + .ok_or_else(|| into_boxed_error("Incompatible units for comparison".to_string())) + } + + pub fn greater_than(&self, other: &DimensionalVariable) -> Result> { + self.0 + .partial_cmp(&other.0) + .map(|o| o.is_gt()) + .ok_or_else(|| into_boxed_error("Incompatible units for comparison".to_string())) + } + + pub fn greater_equal(&self, other: &DimensionalVariable) -> Result> { + self.0 + .partial_cmp(&other.0) + .map(|o| o.is_gt() || o.is_eq()) + .ok_or_else(|| into_boxed_error("Incompatible units for comparison".to_string())) + } + + pub fn clone_var(&self) -> Box { + into_boxed_dv(clone_core(&self.0)) + } + + pub fn to_string(&self, to: &mut DiplomatWrite) -> Result<(), ()> { + write!(to, "{}", self.0).map_err(|_| ()) + } + } +} diff --git a/cpp/BUILD.bazel b/cpp/BUILD.bazel index fa58de6..7366f06 100644 --- a/cpp/BUILD.bazel +++ b/cpp/BUILD.bazel @@ -1,55 +1,57 @@ -load("@rules_cc//cc:defs.bzl", "cc_library", "cc_binary") -load("@rules_rust//rust:defs.bzl", "rust_shared_library", "rust_static_library") +load("@rules_cc//cc:defs.bzl", "cc_library") package(default_visibility = ["//visibility:public"]) -# ============================================================================= -# C/C++ Interface -# ============================================================================= +genrule( + name = "codegen_cpp", + srcs = ["//core/ffi/diplomat:src/lib.rs"], + outs = [ + "BaseUnits.d.hpp", + "BaseUnits.hpp", + "DvError.d.hpp", + "DvError.hpp", + "DimensionalVariable.d.hpp", + "DimensionalVariable.hpp", + "diplomat_runtime.hpp", + ], + tools = ["//tools/diplomat_codegen:diplomat_codegen"], + cmd = "$(location //tools/diplomat_codegen:diplomat_codegen) cpp $(RULEDIR) --entry $(location //core/ffi/diplomat:src/lib.rs)", +) + +filegroup( + name = "generated_headers", + srcs = [":codegen_cpp"], +) -# C/C++ headers cc_library( + name = "generated_cpp_headers", + hdrs = [":generated_headers"], + includes = ["."], +) + +alias( name = "dv_headers", - hdrs = [ - "include/dv_c.h", - "include/dv.hpp", - ], - includes = ["include"], + actual = ":dv_cpp", ) -# Linkable library for C/C++ that exposes the Rust C ABI. -cc_library( +alias( name = "dv_c", - hdrs = ["include/dv_c.h"], - deps = ["//cpp:dv_capi_static"], - includes = ["include"], + actual = "//c:dv_c", +) + +cc_library( + name = "dv_generated", + hdrs = [":generated_headers"], + includes = ["."], + deps = [ + ":generated_cpp_headers", + "//core/ffi/diplomat:dv_diplomat_capi_static", + ], ) cc_library( name = "dv_cpp", hdrs = ["include/dv.hpp"], - deps = [":dv_c"], includes = ["include"], -) - -# ============================================================================= -# C-compatible Rust Library -# ============================================================================= - -# C ABI shared library for C/C++ consumers -rust_shared_library( - name = "dv_capi_shared", - srcs = ["capi/src/lib.rs"], - crate_name = "dv_capi", - edition = "2021", - deps = ["//core:dv_rs"], -) - -# Static variant for C/C++ to link without runtime dylib. -rust_static_library( - name = "dv_capi_static", - srcs = ["capi/src/lib.rs"], - crate_name = "dv_capi", - edition = "2021", - deps = ["//core:dv_rs"], + deps = [":dv_generated"], ) diff --git a/cpp/README.md b/cpp/README.md index 86ed3f5..50cb645 100644 --- a/cpp/README.md +++ b/cpp/README.md @@ -1,13 +1,11 @@ # dv C/C++ Bindings -This folder contains C and C++ headers wrapping the Rust core via a small C ABI shim. +The Rust Diplomat bridge lives in `core/ffi/diplomat/`, while the Bazel-facing C/C++ binding targets live directly in the language directories. -See full docs under docs site pages “C” and “C++”. +- C target alias: `//cpp:dv_c` +- C++ target alias: `//cpp:dv_cpp` -Quick usage: -- Bazel: `bazel run //cpp:demo_c` and `bazel run //cpp:demo_cpp` -- CMake: `cmake -S . -B build && cmake --build build --target dv_c_demo dv_cpp_demo` - -Headers in `cpp/include`: -- `dv_c.h`: C API -- `dv.hpp`: C++ RAII wrapper +See: +- `c/` for the generated C bindings and the `//c:dv_c` Bazel target +- `cpp/` for the C++ compatibility wrapper and the `//cpp:dv_cpp` Bazel target +- `docs/c.md` and `docs/cpp.md` for usage and build examples diff --git a/cpp/capi/Cargo.toml b/cpp/capi/Cargo.toml deleted file mode 100644 index 4227a53..0000000 --- a/cpp/capi/Cargo.toml +++ /dev/null @@ -1,16 +0,0 @@ -[package] -name = "dv_capi" -version = "0.1.0" -edition = "2021" -authors = ["Alex Tacescu "] -license = "Apache-2.0" -description = "C ABI bindings for dv (DimensionalVariable)" -publish = false - -[lib] -name = "dv_capi" -crate-type = ["staticlib", "cdylib"] -path = "src/lib.rs" - -[dependencies] -dv = { path = "../../core" } diff --git a/cpp/capi/src/lib.rs b/cpp/capi/src/lib.rs deleted file mode 100644 index 3e82d3a..0000000 --- a/cpp/capi/src/lib.rs +++ /dev/null @@ -1,345 +0,0 @@ -//! C ABI for dv core. - -use std::ffi::{CStr, CString}; -use std::os::raw::{c_char, c_double, c_int}; -use std::ptr; - -use dv_rs::{units, DimensionalVariable}; - -// Opaque handle for C API -#[repr(C)] -pub struct dv_var { - inner: DimensionalVariable, -} - -// Thread-local last error string for C API callers. -thread_local! { - static LAST_ERROR: std::cell::RefCell> = const { std::cell::RefCell::new(None) }; -} - -fn set_last_error(msg: String) { - LAST_ERROR.with(|e| *e.borrow_mut() = Some(msg)); -} - -#[no_mangle] -pub extern "C" fn dv_last_error_message() -> *const c_char { - LAST_ERROR.with(|e| { - if let Some(ref s) = *e.borrow() { - // Leak a CString per call; caller should copy immediately. We can reuse a TLS buffer if needed. - let c = CString::new(s.as_str()).unwrap_or_else(|_| CString::new("invalid error").unwrap()); - let ptr = c.as_ptr(); - std::mem::forget(c); - ptr - } else { - ptr::null() - } - }) -} - -#[no_mangle] -pub extern "C" fn dv_free_cstring(s: *mut c_char) { - if s.is_null() { return; } - unsafe { let _ = CString::from_raw(s); } -} - -#[no_mangle] -pub extern "C" fn dv_base_units_size() -> usize { - units::BASE_UNITS_SIZE -} - -// Create a variable from value and unit string. -#[no_mangle] -pub extern "C" fn dv_var_new(value: c_double, unit_str: *const c_char) -> *mut dv_var { - if unit_str.is_null() { - set_last_error("unit_str was null".to_string()); - return ptr::null_mut(); - } - let cstr = unsafe { CStr::from_ptr(unit_str) }; - let unit = match cstr.to_str() { - Ok(s) => s, - Err(_) => { - set_last_error("unit_str not valid UTF-8".to_string()); - return ptr::null_mut(); - } - }; - match DimensionalVariable::new(value, unit) { - Ok(inner) => Box::into_raw(Box::new(dv_var { inner })), - Err(e) => { - set_last_error(e); - ptr::null_mut() - } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_free(ptr_: *mut dv_var) { - if ptr_.is_null() { return; } - unsafe { let _ = Box::from_raw(ptr_); } -} - -#[no_mangle] -pub extern "C" fn dv_var_value(ptr_: *const dv_var) -> c_double { - if ptr_.is_null() { return f64::NAN; } - let v = unsafe { &(*ptr_) }; - v.inner.value() -} - -// Returns 1 if unitless, 0 otherwise. -#[no_mangle] -pub extern "C" fn dv_var_is_unitless(ptr_: *const dv_var) -> c_int { - if ptr_.is_null() { return 0; } - let v = unsafe { &(*ptr_) }; - if v.inner.is_unitless() { 1 } else { 0 } -} - -// Attempt to convert to a target unit; on success stores into out_value and returns 1. On failure, returns 0 and sets last error. -#[no_mangle] -pub extern "C" fn dv_var_value_in(ptr_: *const dv_var, unit_str: *const c_char, out_value: *mut c_double) -> c_int { - if ptr_.is_null() { set_last_error("null dv_var".to_string()); return 0; } - if unit_str.is_null() { set_last_error("unit_str was null".to_string()); return 0; } - if out_value.is_null() { set_last_error("out_value was null".to_string()); return 0; } - let v = unsafe { &(*ptr_) }; - let cstr = unsafe { CStr::from_ptr(unit_str) }; - let unit = match cstr.to_str() { Ok(s) => s, Err(_) => { set_last_error("unit_str not valid UTF-8".to_string()); return 0; } }; - match v.inner.value_in(unit) { - Ok(val) => { unsafe { *out_value = val; } 1 }, - Err(e) => { set_last_error(e); 0 } - } -} - -// Arithmetic operations. All return a newly allocated dv_var* or null on error. -#[no_mangle] -pub extern "C" fn dv_var_add(a: *const dv_var, b: *const dv_var) -> *mut dv_var { - if a.is_null() || b.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - let b = unsafe { &(*b) }; - match a.inner.try_add(&b.inner) { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: v })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_sub(a: *const dv_var, b: *const dv_var) -> *mut dv_var { - if a.is_null() || b.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - let b = unsafe { &(*b) }; - match a.inner.try_sub(&b.inner) { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: v })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_mul(a: *const dv_var, b: *const dv_var) -> *mut dv_var { - if a.is_null() || b.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - let b = unsafe { &(*b) }; - let v = &a.inner * &b.inner; - Box::into_raw(Box::new(dv_var { inner: v })) -} - -#[no_mangle] -pub extern "C" fn dv_var_div(a: *const dv_var, b: *const dv_var) -> *mut dv_var { - if a.is_null() || b.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - let b = unsafe { &(*b) }; - let v = &a.inner / &b.inner; - Box::into_raw(Box::new(dv_var { inner: v })) -} - -#[no_mangle] -pub extern "C" fn dv_var_mul_scalar(a: *const dv_var, s: c_double) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - let v = &a.inner * s; - Box::into_raw(Box::new(dv_var { inner: v })) -} - -#[no_mangle] -pub extern "C" fn dv_var_div_scalar(a: *const dv_var, s: c_double) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - let v = &a.inner / s; - Box::into_raw(Box::new(dv_var { inner: v })) -} - -#[no_mangle] -pub extern "C" fn dv_var_powi(a: *const dv_var, exp: c_int) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - let v = a.inner.powi(exp as i32); - Box::into_raw(Box::new(dv_var { inner: v })) -} - -#[no_mangle] -pub extern "C" fn dv_var_powf(a: *const dv_var, exp: c_double) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - match a.inner.powf(exp) { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: v })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_sqrt(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - match a.inner.sqrt() { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: v })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_ln(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - match a.inner.ln() { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: DimensionalVariable { value: v, unit: [0.0; units::BASE_UNITS_SIZE] } })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_log2(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - match a.inner.log2() { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: DimensionalVariable { value: v, unit: [0.0; units::BASE_UNITS_SIZE] } })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_log10(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - match a.inner.log10() { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: DimensionalVariable { value: v, unit: [0.0; units::BASE_UNITS_SIZE] } })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_sin(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - match a.inner.sin() { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: DimensionalVariable { value: v, unit: [0.0; units::BASE_UNITS_SIZE] } })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_cos(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - match a.inner.cos() { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: DimensionalVariable { value: v, unit: [0.0; units::BASE_UNITS_SIZE] } })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_tan(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - match a.inner.tan() { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: DimensionalVariable { value: v, unit: [0.0; units::BASE_UNITS_SIZE] } })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_neg(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - let v = a.inner.neg(); - Box::into_raw(Box::new(dv_var { inner: v })) -} - -#[no_mangle] -pub extern "C" fn dv_var_abs(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - let v = a.inner.abs(); - Box::into_raw(Box::new(dv_var { inner: v })) -} - -#[no_mangle] -pub extern "C" fn dv_var_asin(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - match a.inner.asin() { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: v })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_acos(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - match a.inner.acos() { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: v })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_var_atan(a: *const dv_var) -> *mut dv_var { - if a.is_null() { set_last_error("null operand".to_string()); return ptr::null_mut(); } - let a = unsafe { &(*a) }; - match a.inner.atan() { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: v })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -// Free-standing trigonometric functions that take raw f64 and return angle in radians - -/// Convert a dv_var to a string representation. -/// Returns a newly allocated C string that must be freed with dv_free_cstring. -/// Returns null on error. -#[no_mangle] -pub extern "C" fn dv_var_to_string(ptr_: *const dv_var) -> *mut c_char { - if ptr_.is_null() { - set_last_error("null dv_var".to_string()); - return ptr::null_mut(); - } - let v = unsafe { &(*ptr_) }; - let s = v.inner.to_string(); - match CString::new(s) { - Ok(c) => c.into_raw(), - Err(_) => { - set_last_error("failed to create C string".to_string()); - ptr::null_mut() - } - } -} - -#[no_mangle] -pub extern "C" fn dv_asin(x: c_double) -> *mut dv_var { - match dv_rs::asin(x) { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: v })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_acos(x: c_double) -> *mut dv_var { - match dv_rs::acos(x) { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: v })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} - -#[no_mangle] -pub extern "C" fn dv_atan(x: c_double) -> *mut dv_var { - match dv_rs::atan(x) { - Ok(v) => Box::into_raw(Box::new(dv_var { inner: v })), - Err(e) => { set_last_error(e); ptr::null_mut() } - } -} diff --git a/cpp/include/dv.hpp b/cpp/include/dv.hpp index 4215618..4519c5c 100644 --- a/cpp/include/dv.hpp +++ b/cpp/include/dv.hpp @@ -1,102 +1,152 @@ #pragma once -#include "dv_c.h" + +#include "DvError.hpp" +#include "DimensionalVariable.hpp" + +#include #include #include -#include +#include +#include namespace dv { inline std::string last_error() { - const char* msg = dv_last_error_message(); - return msg ? std::string(msg) : std::string(); + return "dv operation failed"; +} + +inline std::string last_error(std::monostate) { + return last_error(); +} + +inline std::string last_error(diplomat::Utf8Error) { + return "invalid UTF-8"; +} + +inline std::string last_error(const std::unique_ptr& error) { + if (!error) { + return last_error(); + } + + auto message = error->to_string(); + auto text = std::move(message).ok(); + return text.has_value() && !text->empty() ? std::move(*text) : last_error(); +} + +inline std::string last_error(std::unique_ptr&& error) { + return last_error(static_cast&>(error)); +} + +template +inline T unwrap_or_throw(diplomat::result&& result) { + if (result.is_ok()) { + auto v = std::move(result).ok(); + return std::move(*v); + } + + auto error = std::move(result).err(); + throw std::runtime_error(error.has_value() ? last_error(std::move(*error)) : last_error()); +} + +template +inline T unwrap_utf8_and_throw( + diplomat::result>, diplomat::Utf8Error>&& result +) { + if (result.is_err()) { + auto error = std::move(result).err(); + throw std::runtime_error(error.has_value() ? last_error(std::move(*error)) : last_error()); + } + + auto outer = std::move(result).ok(); + auto inner_result = std::move(*outer); + if (inner_result.is_ok()) { + auto inner = std::move(inner_result).ok(); + return std::move(*inner); + } + + auto nested = std::move(inner_result).err(); + throw std::runtime_error(nested.has_value() ? last_error(std::move(*nested)) : last_error()); } class DV { public: - DV() : ptr_(nullptr) {} - DV(double value, const char* unit) : ptr_(dv_var_new(value, unit)) { - if (!ptr_) throw std::runtime_error(last_error()); - } + DV() = default; + + DV(double value, const char* unit) + : ptr_(unwrap_utf8_and_throw>(DimensionalVariable::new_(value, unit))) {} + DV(const DV&) = delete; DV& operator=(const DV&) = delete; - DV(DV&& o) noexcept : ptr_(o.ptr_) { o.ptr_ = nullptr; } - DV& operator=(DV&& o) noexcept { if (this != &o) { reset(); ptr_ = o.ptr_; o.ptr_ = nullptr; } return *this; } - ~DV() { reset(); } + DV(DV&&) noexcept = default; + DV& operator=(DV&&) noexcept = default; + ~DV() = default; - void reset() { if (ptr_) { dv_var_free(ptr_); ptr_ = nullptr; } } - bool valid() const { return ptr_ != nullptr; } - const dv_var* cptr() const { return ptr_; } - dv_var* ptr() { return ptr_; } + double value() const { return ptr_->value(); } + bool is_unitless() const { return ptr_->is_unitless(); } - double value() const { return dv_var_value(ptr_); } - bool is_unitless() const { return dv_var_is_unitless(ptr_) != 0; } double value_in(const char* unit) const { - double out = 0.0; - if (!dv_var_value_in(ptr_, unit, &out)) { - throw std::runtime_error(last_error()); - } - return out; + return unwrap_utf8_and_throw(ptr_->value_in(unit)); } - // Arithmetic: return new objects - friend DV operator+(const DV& a, const DV& b) { return from_new(dv_var_add(a.cptr(), b.cptr())); } - friend DV operator-(const DV& a, const DV& b) { return from_new(dv_var_sub(a.cptr(), b.cptr())); } - friend DV operator*(const DV& a, const DV& b) { return from_new(dv_var_mul(a.cptr(), b.cptr())); } - friend DV operator/(const DV& a, const DV& b) { return from_new(dv_var_div(a.cptr(), b.cptr())); } - - friend DV operator*(const DV& a, double s) { return from_new(dv_var_mul_scalar(a.cptr(), s)); } - friend DV operator*(double s, const DV& a) { return from_new(dv_var_mul_scalar(a.cptr(), s)); } - friend DV operator/(const DV& a, double s) { return from_new(dv_var_div_scalar(a.cptr(), s)); } - - DV powi(int e) const { return from_new(dv_var_powi(cptr(), e)); } - DV powf(double e) const { return from_new(dv_var_powf(cptr(), e)); } - DV sqrt() const { return from_new(dv_var_sqrt(cptr())); } - DV ln() const { return from_new(dv_var_ln(cptr())); } - DV log2() const { return from_new(dv_var_log2(cptr())); } - DV log10() const { return from_new(dv_var_log10(cptr())); } - DV sin() const { return from_new(dv_var_sin(cptr())); } - DV cos() const { return from_new(dv_var_cos(cptr())); } - DV tan() const { return from_new(dv_var_tan(cptr())); } - DV abs() const { return from_new(dv_var_abs(cptr())); } - friend DV operator-(const DV& a) { return from_new(dv_var_neg(a.cptr())); } - - /// Convert to string representation (e.g., "9.81 m/s^2") - std::string to_string() const { - char* s = dv_var_to_string(ptr_); - if (!s) throw std::runtime_error(last_error()); - std::string result(s); - dv_free_cstring(s); - return result; + DV powi(int e) const { return from_ptr(ptr_->powi(e)); } + DV powf(double e) const { return from_ptr(unwrap_or_throw>(ptr_->powf(e))); } + DV sqrt() const { return from_ptr(unwrap_or_throw>(ptr_->sqrt())); } + DV ln() const { return from_ptr(unwrap_or_throw>(ptr_->ln())); } + DV log2() const { return from_ptr(unwrap_or_throw>(ptr_->log2())); } + DV log10() const { return from_ptr(unwrap_or_throw>(ptr_->log10())); } + DV sin() const { return from_ptr(unwrap_or_throw>(ptr_->sin())); } + DV cos() const { return from_ptr(unwrap_or_throw>(ptr_->cos())); } + DV tan() const { return from_ptr(unwrap_or_throw>(ptr_->tan())); } + DV abs() const { return from_ptr(ptr_->abs()); } + DV asin() const { return from_ptr(unwrap_or_throw>(ptr_->asin())); } + DV acos() const { return from_ptr(unwrap_or_throw>(ptr_->acos())); } + DV atan() const { return from_ptr(unwrap_or_throw>(ptr_->atan())); } + + std::string to_string() const { return unwrap_or_throw(ptr_->to_string()); } + + friend DV operator+(const DV& a, const DV& b) { + return from_ptr(unwrap_or_throw>(a.ptr_->add(*b.ptr_))); } - - /// Stream output operator - friend std::ostream& operator<<(std::ostream& os, const DV& v) { - return os << v.to_string(); + friend DV operator-(const DV& a, const DV& b) { + return from_ptr(unwrap_or_throw>(a.ptr_->sub(*b.ptr_))); } - - // Inverse trigonometric functions (return angle in radians) - DV asin() const { return from_new(dv_var_asin(cptr())); } - DV acos() const { return from_new(dv_var_acos(cptr())); } - DV atan() const { return from_new(dv_var_atan(cptr())); } + friend DV operator*(const DV& a, const DV& b) { + return from_ptr(a.ptr_->mul(*b.ptr_)); + } + friend DV operator/(const DV& a, const DV& b) { + return from_ptr(a.ptr_->div(*b.ptr_)); + } + friend DV operator*(const DV& a, double s) { return from_ptr(a.ptr_->mul_scalar(s)); } + friend DV operator*(double s, const DV& a) { return from_ptr(a.ptr_->mul_scalar(s)); } + friend DV operator/(const DV& a, double s) { return from_ptr(a.ptr_->div_scalar(s)); } + friend DV operator/(double s, const DV& a) { return from_ptr(a.ptr_->rdiv_scalar(s)); } + friend DV operator-(const DV& a) { return from_ptr(a.ptr_->neg()); } + + friend bool operator==(const DV& a, const DV& b) { return a.ptr_->equals(*b.ptr_); } + friend bool operator!=(const DV& a, const DV& b) { return a.ptr_->not_equals(*b.ptr_); } + friend bool operator<(const DV& a, const DV& b) { return unwrap_or_throw(a.ptr_->less_than(*b.ptr_)); } + friend bool operator<=(const DV& a, const DV& b) { return unwrap_or_throw(a.ptr_->less_equal(*b.ptr_)); } + friend bool operator>(const DV& a, const DV& b) { return unwrap_or_throw(a.ptr_->greater_than(*b.ptr_)); } + friend bool operator>=(const DV& a, const DV& b) { return unwrap_or_throw(a.ptr_->greater_equal(*b.ptr_)); } private: - static DV from_new(dv_var* p) { - if (!p) throw std::runtime_error(last_error()); - DV v; v.ptr_ = p; return v; + explicit DV(std::unique_ptr p) : ptr_(std::move(p)) {} + + static DV from_ptr(std::unique_ptr p) { + if (!p) throw std::runtime_error("dv operation failed"); + return DV(std::move(p)); } - dv_var* ptr_; + std::unique_ptr ptr_; friend DV asin(double x); friend DV acos(double x); friend DV atan(double x); }; -inline size_t base_units_size() { return dv_base_units_size(); } - -// Free-standing inverse trigonometric functions (take raw double, return angle in radians) -inline DV asin(double x) { return DV::from_new(dv_asin(x)); } -inline DV acos(double x) { return DV::from_new(dv_acos(x)); } -inline DV atan(double x) { return DV::from_new(dv_atan(x)); } +inline size_t base_units_size() { return DimensionalVariable::base_units_size(); } +inline DV asin(double x) { return DV::from_ptr(unwrap_or_throw>(DimensionalVariable::asin_scalar(x))); } +inline DV acos(double x) { return DV::from_ptr(unwrap_or_throw>(DimensionalVariable::acos_scalar(x))); } +inline DV atan(double x) { return DV::from_ptr(unwrap_or_throw>(DimensionalVariable::atan_scalar(x))); } } // namespace dv diff --git a/cpp/include/dv_c.h b/cpp/include/dv_c.h deleted file mode 100644 index e19af48..0000000 --- a/cpp/include/dv_c.h +++ /dev/null @@ -1,66 +0,0 @@ -#ifndef DV_C_H -#define DV_C_H - -#ifdef __cplusplus -extern "C" { -#endif - -#include - -typedef struct dv_var dv_var; // opaque - -// Error handling: call after a function returns failure to get a message (UTF-8). The pointer is valid until next API call. -const char* dv_last_error_message(void); - -// Util -size_t dv_base_units_size(void); -void dv_free_cstring(char* s); // Free a string returned by dv_var_to_string - -// Lifecycle -dv_var* dv_var_new(double value, const char* unit_str); -void dv_var_free(dv_var* v); - -// Accessors -double dv_var_value(const dv_var* v); -int dv_var_is_unitless(const dv_var* v); -int dv_var_value_in(const dv_var* v, const char* unit_str, double* out_value); -char* dv_var_to_string(const dv_var* v); // Returns allocated string, must free with dv_free_cstring - -// Arithmetic -dv_var* dv_var_add(const dv_var* a, const dv_var* b); -dv_var* dv_var_sub(const dv_var* a, const dv_var* b); -dv_var* dv_var_mul(const dv_var* a, const dv_var* b); -dv_var* dv_var_div(const dv_var* a, const dv_var* b); - -// Scalar ops -dv_var* dv_var_mul_scalar(const dv_var* a, double s); -dv_var* dv_var_div_scalar(const dv_var* a, double s); - -// Powers -dv_var* dv_var_powi(const dv_var* a, int exp); -dv_var* dv_var_powf(const dv_var* a, double exp); -dv_var* dv_var_sqrt(const dv_var* a); -dv_var* dv_var_ln(const dv_var* a); -dv_var* dv_var_log2(const dv_var* a); -dv_var* dv_var_log10(const dv_var* a); -dv_var* dv_var_sin(const dv_var* a); -dv_var* dv_var_cos(const dv_var* a); -dv_var* dv_var_tan(const dv_var* a); -dv_var* dv_var_neg(const dv_var* a); -dv_var* dv_var_abs(const dv_var* a); - -// Inverse trigonometric functions (return angle in radians) -dv_var* dv_var_asin(const dv_var* a); -dv_var* dv_var_acos(const dv_var* a); -dv_var* dv_var_atan(const dv_var* a); - -// Free-standing inverse trigonometric functions (take raw double, return angle in radians) -dv_var* dv_asin(double x); -dv_var* dv_acos(double x); -dv_var* dv_atan(double x); - -#ifdef __cplusplus -} -#endif - -#endif // DV_C_H diff --git a/docs/docs/c_cpp.md b/docs/docs/c_cpp.md index 492ce02..e08839f 100644 --- a/docs/docs/c_cpp.md +++ b/docs/docs/c_cpp.md @@ -5,36 +5,23 @@ sidebar_position: 3 # DV with C/C++ -DV has been designed to work in either C or C++, with either Bazel or CMake as a build system. +DV has been designed to work in either C or C++, and the primary supported build path is Bazel. ## A note about build systems We currently do not publish C/C++ libraries, so you will need to build the library from scratch every time (see [GH-32](https://github.com/alextac98/dv/issues/32)). -For CMake, you'll need to make sure that Cargo is installed on the system you intend to build. Follow instructions here: https://rust-lang.org/tools/install - For Bazel, make sure you properly have both Rust and C/C++ toolchains (ideally hermetic) set up and running. We recommend [llvm-toolchains](https://github.com/bazel-contrib/toolchains_llvm) for C/C++ hermeticity. ## C++ -DV exposes a C API and a thin C++ wrapper (`dv.hpp`). You can use it from Bazel or CMake. +DV exposes generated C and C++ bindings via Diplomat. The Rust bridge crate lives in `core/ffi/diplomat`, while the Bazel targets for each language live in `c/` and `cpp/`. ```cpp -#include "dv.hpp" -#include -#include +#include "DimensionalVariable.hpp" int main() { - dv::DV mass(10.0, "kg"); - dv::DV accel(9.81, "m/s^2"); - dv::DV force = mass * accel; // N - std::cout << "force = " << force.value_in("lbf") << " lbf\n"; - - // Working with angles - dv::DV angle_rad(M_PI / 4.0, "rad"); - dv::DV angle_deg(45.0, "deg"); - std::cout << "45 degrees = " << angle_deg.value_in("rad") << " radians\n"; - + // See examples/cpp/main.cpp for the generated Diplomat C++ API with result handling. return 0; } @@ -57,40 +44,27 @@ load("@rules_cc//cc:defs.bzl", "cc_binary") cc_binary( name = "example", srcs = ["main.cpp"], - deps = ["@dv//cpp:dv_cpp"], # C++ wrapper + deps = ["@dv//cpp:dv_cpp"], # compatibility wrapper target ) ``` -### CMake with C++ - -```cmake title="CMakeLists.txt" -include(FetchContent) -FetchContent_Declare(dv GIT_REPOSITORY https://github.com/alextac98/dv.git GIT_TAG main) -FetchContent_MakeAvailable(dv) - -add_executable(example main.cpp) -target_link_libraries(example PRIVATE dv_cpp) -``` +If you want the raw generated C++ API directly, depend on `@dv//cpp:dv_generated`. ### Static vs dynamic linking - Default in this repo uses static linking to avoid runtime `rpath` issues. -- If you choose dynamic linking on macOS, set `install_name` to `@rpath/libdv_capi.dylib` and add an rpath (e.g., `@loader_path`). +- If you choose dynamic linking on macOS, ensure your produced shared library install name/rpath are configured appropriately for your build system. ## C -Use the C header `dv_c.h` for a simple opaque handle API. +Use the generated C header `DimensionalVariable.h` for the opaque handle API. ```c -#include "dv_c.h" -#include -int main(){ - dv_var* d = dv_var_new(10.0, "m"); - dv_var* t = dv_var_new(2.0, "s"); - dv_var* v = dv_var_div(d, t); - double mph = 0.0; dv_var_value_in(v, "mi/hr", &mph); - printf("%f\n", mph); - dv_var_free(v); dv_var_free(d); dv_var_free(t); +#include "DimensionalVariable.h" +int main(void){ + // See examples/c/main.c for Diplomat-generated result structs and string views. + // The generated API names are prefixed with `DimensionalVariable_*`. + return 0; } ``` @@ -111,17 +85,10 @@ load("@rules_cc//cc:defs.bzl", "cc_binary") cc_binary( name = "example_c", srcs = ["main.c"], - deps = ["@dv//cpp:dv_c"], + deps = ["@dv//c:dv_c"], ) ``` -### CMake with C - -```cmake title="CMakeLists.txt" -include(FetchContent) -FetchContent_Declare(dv GIT_REPOSITORY https://github.com/alextac98/dv.git GIT_TAG main) -FetchContent_MakeAvailable(dv) +### CMake -add_executable(example_c main.c) -target_link_libraries(example_c PRIVATE dv_c) -``` +CMake support shells out to the Rust Diplomat bridge in `core/ffi/diplomat` to regenerate C and C++ headers in the build tree. Bazel remains the primary development path. diff --git a/docs/docs/dev/code.md b/docs/docs/dev/code.md index 0ba5d81..d96bb38 100644 --- a/docs/docs/dev/code.md +++ b/docs/docs/dev/code.md @@ -31,9 +31,17 @@ bazel run //core:serve_docs #### Python +On Windows, prefer PowerShell/cmd for Bazel commands, or set `MSYS2_ARG_CONV_EXCL='*'` when using Git Bash so `//...` labels are passed through unchanged. + ```shell -# Build the extension -bazel build //python:maturin_build +# Build the extension module (.so) +bazel build //python:dv_ext.so + +# Build the default development wheel (CPython 3.12+ abi3) +bazel build //python:wheel_abi3.dist + +# Build distributable wheels for all supported Python versions +bazel build //python:wheel_cp310.dist //python:wheel_cp311.dist //python:wheel_abi3.dist # Run tests bazel test //python:test_dv @@ -62,9 +70,11 @@ The core of the library is written in rust, and lives in the `core` directory. L | Path | Description | |---|---| | `core/` | Rust crate + core functionality | +| `core/ffi/diplomat/` | Rust-owned Diplomat bridge crate | +| `c/` | C binding targets | | `docs/` | Docs site for users and developers | -| `cpp/` | C/C++ bindings | -| `python/` | Python bindings | +| `cpp/` | C++ bindings and compatibility wrapper | +| `python/` | Python bindings, wheel packaging, and tests | | `MODULE.bazel` | Bazel module dependencies | ### Contributing Units diff --git a/docs/docs/intro.md b/docs/docs/intro.md index 5279fbb..6fc7524 100644 --- a/docs/docs/intro.md +++ b/docs/docs/intro.md @@ -99,11 +99,23 @@ DV fixes all of these issues Status | Language | Notes -------|----------|------ ✅ Core | Rust | Reference implementation -✅ C | C ABI (`dv_c.h`) -✅ C++ | C++ RAII wrapper (`dv.hpp`) -✅ Python | Python via PyO3 +✅ C | Diplomat-generated C bindings +✅ C++ | Diplomat-generated C++ bindings +✅ Python | Diplomat-generated nanobind bindings (+ Python compatibility wrapper) 🛠 Planned | JavaScript / TypeScript | WASM or N-API layer 🛠 Planned | Java | JNI via C ABI (or pure port) 🛠 Planned | Matlab | MEX wrapper Cross‑language parity tests will ensure identical exponent math and error strings (where sensible). + +## Repository Layout + +The repository is organized around one Rust source of truth plus language-specific package directories: + +| Path | Purpose | +| --- | --- | +| `core/` | Core Rust logic and the published Rust crate | +| `core/ffi/diplomat/` | Rust-owned Diplomat bridge crate used for cross-language code generation | +| `python/` | Python package wrapper, wheel packaging, tests, and generated extension build targets | +| `c/` | C binding targets | +| `cpp/` | C++ binding targets and the `dv.hpp` compatibility wrapper | diff --git a/docs/docs/python.md b/docs/docs/python.md index 76791d1..4fe4592 100644 --- a/docs/docs/python.md +++ b/docs/docs/python.md @@ -16,18 +16,18 @@ sidebar_position: 3 # -DV supports python via PyO3 bindings to the core library. Any Rust `Results<>` are converted to Python exceptions. +DV supports Python via Diplomat-generated nanobind bindings, with a thin Python compatibility wrapper (`python/dv_py/__init__.py`) preserving the ergonomic API. The project currently builds for these architectures: * Linux * x86 64-bit - * Arm 64-bit (aarch64-gnu) - * Arm 32-bit (armv7-gnueabihf) * MacOS * Arm 64-bit * x86 64-bit * Windows * x86 64-bit + +The current Bazel-managed PyPI wheel build publishes platform wheels for CPython 3.10, CPython 3.11, and a CPython 3.12+ `abi3` wheel. ## Quickstart @@ -40,7 +40,7 @@ pip install dv-py Then import and use it in your Python code: ```python -from dv import DV +from dv_py import DimensionalVariable as DV # Create dimensioned variables velocity = DV(10.0, "m/s") @@ -51,6 +51,26 @@ distance = velocity * time print(f"Distance: {distance.value_in('m')} m") ``` +## Build Targets + +For development in this repo: + +On Windows, run Bazel from PowerShell/cmd, or set `MSYS2_ARG_CONV_EXCL='*'` first if you are using Git Bash so labels like `//python:wheel_abi3.dist` are not rewritten into invalid `/python:...` paths. + +```bash +# Build the extension module +bazel build //python:dv_ext.so + +# Build the default development wheel (CPython 3.12) +bazel build //python:wheel_abi3.dist + +# Build wheels for all supported Python versions +bazel build //python:wheel_cp310.dist //python:wheel_cp311.dist //python:wheel_abi3.dist + +# Run the Python test suite +bazel test //python:test_dv +``` + ## Examples @@ -64,7 +84,8 @@ This example demonstrates: - Error handling for incompatible operations """ -from dv import DV, DVError +from dv_py import DVError +from dv_py import DimensionalVariable as DV def main(): diff --git a/examples/README.md b/examples/README.md index d1d3279..e30affc 100644 --- a/examples/README.md +++ b/examples/README.md @@ -14,13 +14,7 @@ This directory contains minimal examples for each supported language. ## CMake (C/C++) -From the repository root: - -1. Configure - - `cmake -S . -B build` -2. Build targets - - `cmake --build build --target dv_example_c` - - `cmake --build build --target dv_example_cpp` +CMake examples are temporarily unavailable during the Diplomat migration. Use the Bazel targets above. ## Cargo (Rust) @@ -28,5 +22,5 @@ From the repository root: Notes -- The C and C++ examples link against the Rust C-ABI produced by the `cpp/capi` crate via the imported `dv_c` and `dv_cpp` targets. +- The C and C++ examples now use Diplomat-generated bindings from `//c` and `//cpp`, backed by the Rust bridge in `core/ffi/diplomat`. - The Rust example depends on the core crate directly via a path dependency and uses Bazel via `//core:dv_rs` when built with Bazel. diff --git a/examples/c/BUILD.bazel b/examples/c/BUILD.bazel index da07193..c66abaa 100644 --- a/examples/c/BUILD.bazel +++ b/examples/c/BUILD.bazel @@ -5,5 +5,5 @@ package(default_visibility = ["//visibility:public"]) cc_binary( name = "c_example", srcs = ["main.c"], - deps = ["//cpp:dv_c"], + deps = ["//c:dv_c"], ) diff --git a/examples/c/CMakeLists.txt b/examples/c/CMakeLists.txt index dbc824c..7d24a1d 100644 --- a/examples/c/CMakeLists.txt +++ b/examples/c/CMakeLists.txt @@ -1,14 +1,5 @@ cmake_minimum_required(VERSION 3.20) project(dv_c_example C) -# Expect to be added from repo root as part of the overall build. Use include and link from cpp/ setup. add_executable(dv_example_c main.c) -target_include_directories(dv_example_c PRIVATE ${CMAKE_CURRENT_LIST_DIR}/../../cpp/include) -target_link_libraries(dv_example_c PRIVATE dv_c m) - -if(APPLE) - # Allow running example if dv_capi.dylib is used at runtime - set_target_properties(dv_example_c PROPERTIES - BUILD_RPATH ${CMAKE_CURRENT_LIST_DIR}/../../cpp/capi/target/release - ) -endif() +target_link_libraries(dv_example_c PRIVATE dv_c) diff --git a/examples/c/main.c b/examples/c/main.c index ffaaad1..aba7172 100644 --- a/examples/c/main.c +++ b/examples/c/main.c @@ -1,36 +1,37 @@ -#include "dv_c.h" +#include "DimensionalVariable.h" #include +#include -static void print_last_error(const char* prefix) { - const char* msg = dv_last_error_message(); - if (msg && *msg) { - fprintf(stderr, "%s: %s\n", prefix, msg); - } else { - fprintf(stderr, "%s: (unknown error)\n", prefix); - } +static DiplomatStringView str_view(const char* s) { + DiplomatStringView v; + v.data = s; + v.len = strlen(s); + return v; } int main(void) { - dv_var* d = dv_var_new(42.0, "m"); - if (!d) { print_last_error("dv_var_new(d)"); return 1; } + DimensionalVariable_new_result d_res = DimensionalVariable_new(42.0, str_view("m")); + if (!d_res.is_ok) { fprintf(stderr, "DimensionalVariable_new(d) failed\n"); return 1; } + DimensionalVariable* d = d_res.ok; - dv_var* t = dv_var_new(3.0, "s"); - if (!t) { print_last_error("dv_var_new(t)"); dv_var_free(d); return 1; } + DimensionalVariable_new_result t_res = DimensionalVariable_new(3.0, str_view("s")); + if (!t_res.is_ok) { fprintf(stderr, "DimensionalVariable_new(t) failed\n"); DimensionalVariable_destroy(d); return 1; } + DimensionalVariable* t = t_res.ok; - dv_var* v = dv_var_div(d, t); // 14 m/s - if (!v) { print_last_error("dv_var_div(d,t)"); dv_var_free(d); dv_var_free(t); return 1; } + DimensionalVariable* v = DimensionalVariable_div(d, t); // 14 m/s + if (!v) { fprintf(stderr, "DimensionalVariable_div(d,t) failed\n"); DimensionalVariable_destroy(d); DimensionalVariable_destroy(t); return 1; } - double mph = 0.0; - if (!dv_var_value_in(v, "mi/hr", &mph)) { - print_last_error("dv_var_value_in(v, mi/hr)"); - dv_var_free(v); dv_var_free(d); dv_var_free(t); + DimensionalVariable_value_in_result mph_res = DimensionalVariable_value_in(v, str_view("mi/hr")); + if (!mph_res.is_ok) { + fprintf(stderr, "DimensionalVariable_value_in(v, mi/hr) failed\n"); + DimensionalVariable_destroy(v); DimensionalVariable_destroy(d); DimensionalVariable_destroy(t); return 1; } - printf("speed = %.4f mi/hr\n", mph); + printf("speed = %.4f mi/hr\n", mph_res.ok); - dv_var_free(v); - dv_var_free(d); - dv_var_free(t); + DimensionalVariable_destroy(v); + DimensionalVariable_destroy(d); + DimensionalVariable_destroy(t); return 0; } diff --git a/examples/cpp/BUILD.bazel b/examples/cpp/BUILD.bazel index 08c693c..f969da4 100644 --- a/examples/cpp/BUILD.bazel +++ b/examples/cpp/BUILD.bazel @@ -5,5 +5,5 @@ package(default_visibility = ["//visibility:public"]) cc_binary( name = "cpp_example", srcs = ["main.cpp"], - deps = ["//cpp:dv_cpp"], + deps = ["//cpp:dv_generated"], ) diff --git a/examples/cpp/CMakeLists.txt b/examples/cpp/CMakeLists.txt index 5766c43..ab51310 100644 --- a/examples/cpp/CMakeLists.txt +++ b/examples/cpp/CMakeLists.txt @@ -2,11 +2,4 @@ cmake_minimum_required(VERSION 3.20) project(dv_cpp_example CXX) add_executable(dv_example_cpp main.cpp) -target_include_directories(dv_example_cpp PRIVATE ${CMAKE_CURRENT_LIST_DIR}/../../cpp/include) target_link_libraries(dv_example_cpp PRIVATE dv_cpp) - -if(APPLE) - set_target_properties(dv_example_cpp PROPERTIES - BUILD_RPATH ${CMAKE_CURRENT_LIST_DIR}/../../cpp/capi/target/release - ) -endif() diff --git a/examples/cpp/main.cpp b/examples/cpp/main.cpp index 8e501ef..97c59a6 100644 --- a/examples/cpp/main.cpp +++ b/examples/cpp/main.cpp @@ -1,26 +1,81 @@ -#include "dv.hpp" -#include +#include "DimensionalVariable.hpp" +#include "DvError.hpp" + #include +#include +#include +#include +#include +#include +#include + +template +T expect_ok(diplomat::result&& result, const char* what) { + if (result.is_ok()) { + auto v = std::move(result).ok(); + return std::move(*v); + } + + auto err = std::move(result).err(); + if (err.has_value()) { + if constexpr (std::is_same_v>) { + auto msg = (*err)->to_string(); + auto text = std::move(msg).ok(); + if (text.has_value() && !text->empty()) { + throw std::runtime_error(*text); + } + } + } + + throw std::runtime_error(what); +} + +template +T expect_utf8_and_ok(diplomat::result>, diplomat::Utf8Error>&& result, const char* what) { + if (result.is_err()) { + throw std::runtime_error("utf8 error"); + } + + auto outer = std::move(result).ok(); + auto inner = std::move(*outer); + if (inner.is_ok()) { + auto value = std::move(inner).ok(); + return std::move(*value); + } + + auto err = std::move(inner).err(); + if (err.has_value()) { + auto msg = (*err)->to_string(); + auto text = std::move(msg).ok(); + if (text.has_value() && !text->empty()) { + throw std::runtime_error(*text); + } + } + + throw std::runtime_error(what); +} int main() { - dv::DV mass(10.0, "kg"); - dv::DV accel(9.81, "m/s^2"); - dv::DV force = mass * accel; // N - std::cout << "force = " << force.value_in("lbf") << " lbf\n"; - - // Working with angles - dv::DV angle_rad(M_PI / 4.0, "rad"); - dv::DV angle_deg(45.0, "deg"); - std::cout << "45 degrees = " << angle_deg.value_in("rad") << " radians\n"; - std::cout << "π/4 radians = " << angle_rad.value_in("deg") << " degrees\n"; - - // Free-standing inverse trig functions - dv::DV angle_from_asin = dv::asin(0.5); - dv::DV angle_from_acos = dv::acos(0.5); - dv::DV angle_from_atan = dv::atan(1.0); - std::cout << "asin(0.5) = " << angle_from_asin.value_in("rad") << " rad\n"; - std::cout << "acos(0.5) = " << angle_from_acos.value_in("rad") << " rad\n"; - std::cout << "atan(1.0) = " << angle_from_atan.value_in("deg") << " deg (should be 45)\n"; - + auto mass = expect_utf8_and_ok>(DimensionalVariable::new_(10.0, "kg"), "mass"); + auto accel = expect_utf8_and_ok>(DimensionalVariable::new_(9.81, "m/s^2"), "accel"); + auto force = mass->mul(*accel); + auto force_lbf = expect_utf8_and_ok(force->value_in("lbf"), "force.value_in"); + std::cout << "force = " << force_lbf << " lbf\n"; + + auto angle_deg = expect_utf8_and_ok>(DimensionalVariable::new_(45.0, "deg"), "angle_deg"); + auto angle_rad = expect_utf8_and_ok>(DimensionalVariable::new_(M_PI / 4.0, "rad"), "angle_rad"); + std::cout << "45 degrees = " << expect_utf8_and_ok(angle_deg->value_in("rad"), "deg->rad") << " radians\n"; + std::cout << "pi/4 radians = " << expect_utf8_and_ok(angle_rad->value_in("deg"), "rad->deg") << " degrees\n"; + + auto asin_angle = expect_ok>(DimensionalVariable::asin_scalar(0.5), "asin"); + auto acos_angle = expect_ok>(DimensionalVariable::acos_scalar(0.5), "acos"); + auto atan_angle = expect_ok>(DimensionalVariable::atan_scalar(1.0), "atan"); + std::cout << "asin(0.5) = " << expect_utf8_and_ok(asin_angle->value_in("rad"), "asin rad") << " rad\n"; + std::cout << "acos(0.5) = " << expect_utf8_and_ok(acos_angle->value_in("deg"), "acos deg") << " deg\n"; + std::cout << "atan(1.0) = " << expect_utf8_and_ok(atan_angle->value_in("deg"), "atan deg") << " deg (should be 45)\n"; + + auto force_str = expect_ok(force->to_string(), "to_string"); + std::cout << "force string = " << force_str << "\n"; + return 0; } diff --git a/python/BUILD.bazel b/python/BUILD.bazel index 0fe9c52..2d70879 100644 --- a/python/BUILD.bazel +++ b/python/BUILD.bazel @@ -1,36 +1,221 @@ load("@rules_python//python:defs.bzl", "py_library", "py_test") -load("@rules_rust_pyo3//:defs.bzl", "pyo3_extension") +load("@rules_cc//cc:defs.bzl", "cc_library") +load(":package_metadata.bzl", "PYTHON_PACKAGE_AUTHOR", "PYTHON_PACKAGE_AUTHOR_EMAIL", "PYTHON_PACKAGE_CLASSIFIERS", "PYTHON_PACKAGE_LICENSE", "PYTHON_PACKAGE_NAME", "PYTHON_PACKAGE_PROJECT_URLS", "PYTHON_PACKAGE_REQUIRES", "PYTHON_PACKAGE_SUMMARY", "PYTHON_PACKAGE_VERSION") +load(":wheels.bzl", "dv_extension", "dv_runtime_package", "dv_wheel") package(default_visibility = ["//visibility:public"]) -# Export files for version management and publishing +NANOBIND_REPO_CP310 = "external/rules_python++pip+pypi_310_310_nanobind/site-packages/nanobind" +NANOBIND_REPO_CP311 = "external/rules_python++pip+pypi_311_311_nanobind/site-packages/nanobind" +NANOBIND_REPO_CP312 = "external/rules_python++pip+pypi_312_312_nanobind/site-packages/nanobind" + +# Export files for version management and packaging metadata exports_files([ - "Cargo.toml", + "package_metadata.bzl", "pyproject.toml", ]) -# ============================================================================= -# Python PyO3 Extension Module -# ============================================================================= +config_setting( + name = "linux_x86_64", + constraint_values = [ + "@platforms//cpu:x86_64", + "@platforms//os:linux", + ], +) + +config_setting( + name = "linux_aarch64", + constraint_values = [ + "@platforms//cpu:aarch64", + "@platforms//os:linux", + ], +) + +config_setting( + name = "macos_x86_64", + constraint_values = [ + "@platforms//cpu:x86_64", + "@platforms//os:macos", + ], +) + +config_setting( + name = "macos_arm64", + constraint_values = [ + "@platforms//cpu:arm64", + "@platforms//os:macos", + ], +) + +config_setting( + name = "windows_x86_64", + constraint_values = [ + "@platforms//cpu:x86_64", + "@platforms//os:windows", + ], +) + +genrule( + name = "codegen_python_nanobind", + srcs = ["//core/ffi/diplomat:src/lib.rs"], + outs = [ + "dv_ext_ext.cpp", + "include/BaseUnits.d.hpp", + "include/BaseUnits.hpp", + "include/DvError.d.hpp", + "include/DvError.hpp", + "include/DimensionalVariable.d.hpp", + "include/DimensionalVariable.hpp", + "include/diplomat_nanobind_common.hpp", + "include/diplomat_runtime.hpp", + "sub_modules/dv_ext/BaseUnits_binding.cpp", + "sub_modules/dv_ext/DvError_binding.cpp", + "sub_modules/dv_ext/DimensionalVariable_binding.cpp", + ], + tools = ["//tools/diplomat_codegen:diplomat_codegen"], + cmd = "$(location //tools/diplomat_codegen:diplomat_codegen) nanobind $(RULEDIR) --entry $(location //core/ffi/diplomat:src/lib.rs) --config nanobind.lib_name=dv_ext", +) + +filegroup( + name = "generated_nanobind_headers", + srcs = [ + "include/BaseUnits.d.hpp", + "include/BaseUnits.hpp", + "include/DvError.d.hpp", + "include/DvError.hpp", + "include/DimensionalVariable.d.hpp", + "include/DimensionalVariable.hpp", + "include/diplomat_nanobind_common.hpp", + "include/diplomat_runtime.hpp", + ], +) + +cc_library( + name = "generated_nanobind_header_lib", + hdrs = [":generated_nanobind_headers"], + includes = ["include"], +) + +dv_extension( + name = "cp310", + nanobind_repo_path = NANOBIND_REPO_CP310, + nanobind_whl_files = "@@rules_python++pip+pypi_310_310_nanobind//:extracted_whl_files", + nanobind_combined_src = "@@rules_python++pip+pypi_310_310_nanobind//:site-packages/nanobind/src/nb_combined.cpp", + python_headers = "@python_3_10//:python_headers", + python_libs = "@python_3_10//:libpython", +) + +dv_extension( + name = "cp311", + nanobind_repo_path = NANOBIND_REPO_CP311, + nanobind_whl_files = "@@rules_python++pip+pypi_311_311_nanobind//:extracted_whl_files", + nanobind_combined_src = "@@rules_python++pip+pypi_311_311_nanobind//:site-packages/nanobind/src/nb_combined.cpp", + python_headers = "@python_3_11//:python_headers", + python_libs = "@python_3_11//:libpython", +) + +dv_extension( + name = "cp312", + nanobind_repo_path = NANOBIND_REPO_CP312, + nanobind_whl_files = "@@rules_python++pip+pypi_312_312_nanobind//:extracted_whl_files", + nanobind_combined_src = "@@rules_python++pip+pypi_312_312_nanobind//:site-packages/nanobind/src/nb_combined.cpp", + python_headers = "@python_3_12//:python_headers", + python_libs = "@python_3_12//:libpython", +) -pyo3_extension( - name = "dv_pyo3", - srcs = ["src/lib.rs"], - deps = ["//core:dv_rs"], +dv_extension( + name = "abi3", + nanobind_repo_path = NANOBIND_REPO_CP312, + nanobind_whl_files = "@@rules_python++pip+pypi_312_312_nanobind//:extracted_whl_files", + nanobind_combined_src = "@@rules_python++pip+pypi_312_312_nanobind//:site-packages/nanobind/src/nb_combined.cpp", + python_headers = "@python_3_12//:python_headers", + limited_api = True, + extra_deps = select({ + ":windows_x86_64": ["@@rules_python++python+python_3_12_x86_64-pc-windows-msvc//:abi3_interface"], + "//conditions:default": [], + }), + linkopts = select({ + ":macos_arm64": ["-undefined", "dynamic_lookup"], + ":macos_x86_64": ["-undefined", "dynamic_lookup"], + "//conditions:default": [], + }), ) -# Python library that exposes the extension module -# This creates a "dv" package by making __init__.py available at the root level +alias( + name = "dv_ext.so", + actual = ":dv_ext_native_cp312", +) + +dv_runtime_package( + name = "dv_ext_pkg_cp312", + native_target = ":dv_ext_native_cp312", +) + +# Python library that exposes the generated nanobind extension module py_library( name = "dv_py", srcs = [ "dv_py/__init__.py", ], - data = [":dv_pyo3"], + data = [":dv_ext_pkg_cp312"], imports = ["."], visibility = ["//visibility:public"], ) +dv_wheel( + name = "wheel_cp310", + native_target = ":dv_ext_native_cp310", + abi = "cp310", + python_tag = "cp310", + dist_folder = "dist_cp310", + author = PYTHON_PACKAGE_AUTHOR, + author_email = PYTHON_PACKAGE_AUTHOR_EMAIL, + classifiers = PYTHON_PACKAGE_CLASSIFIERS, + description_file = "pip-readme.md", + distribution = PYTHON_PACKAGE_NAME, + license = PYTHON_PACKAGE_LICENSE, + project_urls = PYTHON_PACKAGE_PROJECT_URLS, + python_requires = PYTHON_PACKAGE_REQUIRES, + summary = PYTHON_PACKAGE_SUMMARY, + version = PYTHON_PACKAGE_VERSION, +) + +dv_wheel( + name = "wheel_cp311", + native_target = ":dv_ext_native_cp311", + abi = "cp311", + python_tag = "cp311", + dist_folder = "dist_cp311", + author = PYTHON_PACKAGE_AUTHOR, + author_email = PYTHON_PACKAGE_AUTHOR_EMAIL, + classifiers = PYTHON_PACKAGE_CLASSIFIERS, + description_file = "pip-readme.md", + distribution = PYTHON_PACKAGE_NAME, + license = PYTHON_PACKAGE_LICENSE, + project_urls = PYTHON_PACKAGE_PROJECT_URLS, + python_requires = PYTHON_PACKAGE_REQUIRES, + summary = PYTHON_PACKAGE_SUMMARY, + version = PYTHON_PACKAGE_VERSION, +) + +dv_wheel( + name = "wheel_abi3", + native_target = ":dv_ext_native_abi3", + abi = "abi3", + python_tag = "cp312", + dist_folder = "dist_abi3", + author = PYTHON_PACKAGE_AUTHOR, + author_email = PYTHON_PACKAGE_AUTHOR_EMAIL, + classifiers = PYTHON_PACKAGE_CLASSIFIERS, + description_file = "pip-readme.md", + distribution = PYTHON_PACKAGE_NAME, + license = PYTHON_PACKAGE_LICENSE, + project_urls = PYTHON_PACKAGE_PROJECT_URLS, + python_requires = PYTHON_PACKAGE_REQUIRES, + summary = PYTHON_PACKAGE_SUMMARY, + version = PYTHON_PACKAGE_VERSION, +) + # ============================================================================= # Tests # ============================================================================= @@ -40,6 +225,6 @@ py_test( srcs = ["tests/test_dv.py"], deps = [ ":dv_py", - "@pypi//pytest:pkg", + "@@rules_python++pip+pypi_312_312_pytest//:pkg", ], ) diff --git a/python/Cargo.toml b/python/Cargo.toml deleted file mode 100644 index 0e52946..0000000 --- a/python/Cargo.toml +++ /dev/null @@ -1,23 +0,0 @@ -[package] -name = "dv_py" -version = "0.3.3" -edition = "2021" -authors = [ "Alex Tacescu ",] -homepage = "https://dv.alextac.com" -repository = "https://github.com/alextac98/dv" -license = "Apache-2.0" -description = "Python bindings for dv (DimensionalVariable)" -publish = false - -[lib] -name = "dv_py" -crate-type = [ "cdylib",] -path = "src/lib.rs" - -[dependencies.dv_rs] -package = "dv" -path = "../core" - -[dependencies.pyo3] -version = "0.26" -features = [ "extension-module", "abi3-py38", "generate-import-lib",] diff --git a/python/dv_py/__init__.py b/python/dv_py/__init__.py index b17e7d0..c2073f5 100644 --- a/python/dv_py/__init__.py +++ b/python/dv_py/__init__.py @@ -1,30 +1,271 @@ -"""Python bindings for dv (DimensionalVariable). - -This module provides dimensional analysis for physical quantities, -ensuring unit correctness in mathematical operations. - -Example: - >>> from dv import DV - >>> velocity = DV(10.0, "m/s") - >>> time = DV(2.0, "s") - >>> distance = velocity * time - >>> print(distance.value_in("m")) - 20.0 -""" - -# When used as a package, use relative import -# The .so file is in the same directory as this __init__.py +"""Python bindings for dv (DimensionalVariable) via Diplomat + nanobind.""" + +from __future__ import annotations + +from typing import Any + try: - # Try relative import first (when used as package 'dv') - from . import dv_pyo3 as dv + from . import dv_ext as _nb except ImportError: - # Fall back to direct import (when __init__.py is run directly) - import dv_pyo3 as dv + import dv_ext as _nb + + +class DVError(Exception): + """Library error for invalid dimensional operations.""" + + +def _map_exc(exc: Exception) -> DVError: + msg = str(exc) or "dv operation failed" + return DVError(msg) + + +def _as_inner(value: Any): + if isinstance(value, DimensionalVariable): + return value._inner + return value + + +class DimensionalVariable: + """Python compatibility wrapper around the generated nanobind object.""" + + __slots__ = ("_inner",) + + def __init__(self, value: float, unit: str): + try: + self._inner = _nb.DimensionalVariable.new(float(value), unit) + except Exception as exc: # nanobind generated exceptions are generic today + raise _map_exc(exc) from None + + @classmethod + def _from_inner(cls, inner): + obj = cls.__new__(cls) + obj._inner = inner + return obj + + def value(self) -> float: + return self._inner.value() + + def value_in(self, unit: str) -> float: + try: + return self._inner.value_in(unit) + except Exception as exc: + raise _map_exc(exc) from None + + def is_unitless(self) -> bool: + return self._inner.is_unitless() + + def base_units(self): + u = self._inner.base_units() + return (u.m, u.kg, u.s, u.k, u.a, u.mol, u.cd, u.rad) + + def clone(self): + return self._from_inner(self._inner.clone_var()) + + def add(self, other: "DimensionalVariable"): + try: + return self._from_inner(self._inner.add(other._inner)) + except Exception as exc: + raise _map_exc(exc) from None + + def sub(self, other: "DimensionalVariable"): + try: + return self._from_inner(self._inner.sub(other._inner)) + except Exception as exc: + raise _map_exc(exc) from None + + def mul(self, other: "DimensionalVariable"): + return self._from_inner(self._inner.mul(other._inner)) + + def div(self, other: "DimensionalVariable"): + return self._from_inner(self._inner.div(other._inner)) + + def mul_scalar(self, scalar: float): + return self._from_inner(self._inner.mul_scalar(float(scalar))) + + def div_scalar(self, scalar: float): + return self._from_inner(self._inner.div_scalar(float(scalar))) + + def rdiv_scalar(self, scalar: float): + return self._from_inner(self._inner.rdiv_scalar(float(scalar))) + + def powi(self, exp: int): + return self._from_inner(self._inner.powi(int(exp))) + + def powf(self, exp: float): + try: + return self._from_inner(self._inner.powf(float(exp))) + except Exception as exc: + raise _map_exc(exc) from None + + def sqrt(self): + try: + return self._from_inner(self._inner.sqrt()) + except Exception as exc: + raise _map_exc(exc) from None + + def ln(self): + try: + return self._from_inner(self._inner.ln()) + except Exception as exc: + raise _map_exc(exc) from None + + def log2(self): + try: + return self._from_inner(self._inner.log2()) + except Exception as exc: + raise _map_exc(exc) from None + + def log10(self): + try: + return self._from_inner(self._inner.log10()) + except Exception as exc: + raise _map_exc(exc) from None + + def sin(self): + try: + return self._from_inner(self._inner.sin()) + except Exception as exc: + raise _map_exc(exc) from None + + def cos(self): + try: + return self._from_inner(self._inner.cos()) + except Exception as exc: + raise _map_exc(exc) from None + + def tan(self): + try: + return self._from_inner(self._inner.tan()) + except Exception as exc: + raise _map_exc(exc) from None + + def asin(self): + try: + return self._from_inner(self._inner.asin()) + except Exception as exc: + raise _map_exc(exc) from None + + def acos(self): + try: + return self._from_inner(self._inner.acos()) + except Exception as exc: + raise _map_exc(exc) from None + + def atan(self): + try: + return self._from_inner(self._inner.atan()) + except Exception as exc: + raise _map_exc(exc) from None + + def __add__(self, other: "DimensionalVariable"): + return self.add(other) + + def __sub__(self, other: "DimensionalVariable"): + return self.sub(other) + + def __mul__(self, other): + if isinstance(other, DimensionalVariable): + return self.mul(other) + if isinstance(other, (int, float)): + return self.mul_scalar(float(other)) + raise TypeError("Cannot multiply DV with this type") + + def __rmul__(self, other): + if isinstance(other, (int, float)): + return self.mul_scalar(float(other)) + raise TypeError("Cannot multiply this type with DV") + + def __truediv__(self, other): + if isinstance(other, DimensionalVariable): + return self.div(other) + if isinstance(other, (int, float)): + return self.div_scalar(float(other)) + raise TypeError("Cannot divide DV by this type") + + def __rtruediv__(self, other): + if isinstance(other, (int, float)): + return self.rdiv_scalar(float(other)) + raise TypeError("Cannot divide this type by DV") + + def __pow__(self, exponent, _modulo=None): + if isinstance(exponent, int): + return self.powi(exponent) + if isinstance(exponent, float): + return self.powf(exponent) + raise TypeError("Exponent must be int or float") + + def __neg__(self): + return self._from_inner(self._inner.neg()) + + def __abs__(self): + return self._from_inner(self._inner.abs()) + + def __eq__(self, other): + if not isinstance(other, DimensionalVariable): + return False + return self._inner.equals(other._inner) + + def __ne__(self, other): + if not isinstance(other, DimensionalVariable): + return True + return self._inner.not_equals(other._inner) + + def __lt__(self, other): + try: + return self._inner.less_than(other._inner) + except Exception as exc: + raise _map_exc(exc) from None + + def __le__(self, other): + try: + return self._inner.less_equal(other._inner) + except Exception as exc: + raise _map_exc(exc) from None + + def __gt__(self, other): + try: + return self._inner.greater_than(other._inner) + except Exception as exc: + raise _map_exc(exc) from None + + def __ge__(self, other): + try: + return self._inner.greater_equal(other._inner) + except Exception as exc: + raise _map_exc(exc) from None + + def __repr__(self): + try: + return f"DimensionalVariable({self.value()}, '{str(self).split(' ', 1)[1]}')" + except Exception: + return "DimensionalVariable()" + + def __str__(self): + try: + return self._inner.to_string() + except Exception as exc: + raise _map_exc(exc) from None + + +def asin(x: float) -> DimensionalVariable: + try: + return DimensionalVariable._from_inner(_nb.DimensionalVariable.asin_scalar(float(x))) + except Exception as exc: + raise _map_exc(exc) from None + + +def acos(x: float) -> DimensionalVariable: + try: + return DimensionalVariable._from_inner(_nb.DimensionalVariable.acos_scalar(float(x))) + except Exception as exc: + raise _map_exc(exc) from None + + +def atan(x: float) -> DimensionalVariable: + try: + return DimensionalVariable._from_inner(_nb.DimensionalVariable.atan_scalar(float(x))) + except Exception as exc: + raise _map_exc(exc) from None -DimensionalVariable = dv.DimensionalVariable -DVError = dv.DVError -asin = dv.asin -acos = dv.acos -atan = dv.atan -__all__ = ["DimensionalVariable", "DVError", "asin", "acos", "atan"] \ No newline at end of file +__all__ = ["DimensionalVariable", "DVError", "asin", "acos", "atan"] diff --git a/python/package_metadata.bzl b/python/package_metadata.bzl new file mode 100644 index 0000000..2fd1904 --- /dev/null +++ b/python/package_metadata.bzl @@ -0,0 +1,32 @@ +PYTHON_PACKAGE_NAME = "dv_py" +PYTHON_PACKAGE_VERSION = "0.3.4" + +PYTHON_PACKAGE_SUMMARY = "Python bindings for dv (DimensionalVariable) - keeping track of units and dimensions for physical quantities" +PYTHON_PACKAGE_REQUIRES = ">=3.10" + +PYTHON_PACKAGE_AUTHOR = "Alex Tacescu" +PYTHON_PACKAGE_AUTHOR_EMAIL = "alextac98@gmail.com" +PYTHON_PACKAGE_LICENSE = "Apache-2.0" + +PYTHON_PACKAGE_CLASSIFIERS = [ + "Development Status :: 4 - Beta", + "Intended Audience :: Developers", + "Intended Audience :: Science/Research", + "License :: OSI Approved :: Apache Software License", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: 3.10", + "Programming Language :: Python :: 3.11", + "Programming Language :: Python :: 3.12", + "Programming Language :: Python :: 3.13", + "Programming Language :: Python :: 3.14", + "Topic :: Scientific/Engineering", + "Topic :: Scientific/Engineering :: Physics", + "Topic :: Software Development :: Libraries", +] + +PYTHON_PACKAGE_PROJECT_URLS = { + "Homepage": "https://dv.alextac.com", + "Documentation": "https://dv.alextac.com/docs/python", + "Repository": "https://github.com/alextac98/dv", + "Issues": "https://github.com/alextac98/dv/issues", +} diff --git a/python/pyproject.toml b/python/pyproject.toml index ffa6155..3f0961b 100644 --- a/python/pyproject.toml +++ b/python/pyproject.toml @@ -1,14 +1,10 @@ -[build-system] -requires = [ "maturin>=1.0,<2.0",] -build-backend = "maturin" - [project] name = "dv_py" -version = "0.3.3" +version = "0.3.4" description = "Python bindings for dv (DimensionalVariable) - keeping track of units and dimensions for physical quantities" readme = "pip-readme.md" -requires-python = ">=3.8" -classifiers = [ "Development Status :: 4 - Beta", "Intended Audience :: Developers", "Intended Audience :: Science/Research", "License :: OSI Approved :: Apache Software License", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", "Programming Language :: Python :: 3.14", "Programming Language :: Python :: 3.15", "Programming Language :: Rust", "Topic :: Scientific/Engineering", "Topic :: Scientific/Engineering :: Physics", "Topic :: Software Development :: Libraries",] +requires-python = ">=3.10" +classifiers = [ "Development Status :: 4 - Beta", "Intended Audience :: Developers", "Intended Audience :: Science/Research", "License :: OSI Approved :: Apache Software License", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", "Programming Language :: Python :: 3.14", "Topic :: Scientific/Engineering", "Topic :: Scientific/Engineering :: Physics", "Topic :: Software Development :: Libraries",] keywords = [ "units", "dimensions", "physical-quantities", "unit-conversion", "unit-checking",] [[project.authors]] name = "Alex Tacescu" @@ -22,7 +18,3 @@ Homepage = "https://dv.alextac.com" Documentation = "https://dv.alextac.com/docs/python" Repository = "https://github.com/alextac98/dv" Issues = "https://github.com/alextac98/dv/issues" - -[tool.maturin] -module-name = "dv_py.dv_pyo3" -python-source = "." diff --git a/python/src/lib.rs b/python/src/lib.rs deleted file mode 100644 index 935c0fb..0000000 --- a/python/src/lib.rs +++ /dev/null @@ -1,415 +0,0 @@ -use pyo3::prelude::*; -use pyo3::exceptions::PyTypeError; -use dv_rs::DimensionalVariable; - -pyo3::create_exception!(dv_pyo3, DVError, pyo3::exceptions::PyException); - -/// A dimensioned variable that combines a numerical value with physical units. -/// -/// The DV class performs dimensional analysis to ensure physical correctness -/// in mathematical operations. Units are stored internally as SI base unit -/// exponents (m, kg, s, K, A, mol, cd). -/// -/// Examples: -/// >>> from dv import DV -/// >>> velocity = DV(10.0, "m/s") -/// >>> time = DV(2.0, "s") -/// >>> distance = velocity * time -/// >>> distance.value_in("m") -/// 20.0 -/// >>> distance.value_in("km") -/// 0.02 -#[pyclass(name = "DimensionalVariable")] -struct PyDV { - dv: DimensionalVariable, -} - -#[pymethods] -impl PyDV { - /// Create a new dimensioned variable. - /// - /// Args: - /// value (float): The numerical value - /// unit (str): The unit string (e.g., "m/s", "kg*m/s^2") - /// - /// Returns: - /// DV: A new dimensioned variable - /// - /// Raises: - /// DVError: If the unit string is invalid - #[new] - fn new(value: f64, unit: &str) -> PyResult { - match DimensionalVariable::new(value, unit) { - Ok(dv) => Ok(PyDV { dv }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Get the raw value in SI base units. - /// - /// Returns: - /// float: The value in SI base units - fn value(&self) -> f64 { - self.dv.value() - } - - /// Convert the value to the specified unit. - /// - /// Args: - /// unit (str): The target unit string - /// - /// Returns: - /// float: The value in the target unit - /// - /// Raises: - /// DVError: If units are incompatible or unit string is invalid - fn value_in(&self, unit: &str) -> PyResult { - match self.dv.value_in(unit) { - Ok(v) => Ok(v), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Check if the variable is dimensionless (unitless). - /// - /// Returns: - /// bool: True if dimensionless, False otherwise - fn is_unitless(&self) -> bool { - self.dv.is_unitless() - } - - /// Get the base unit exponents as a tuple. - /// - /// Returns: - /// tuple: (m, kg, s, K, A, mol, cd, rad) exponents - fn base_units(&self) -> (f64, f64, f64, f64, f64, f64, f64, f64) { - let units = self.dv.unit(); - (units[0], units[1], units[2], units[3], units[4], units[5], units[6], units[7]) - } - - /// Addition operator. - fn __add__(&self, other: &PyDV) -> PyResult { - match self.dv.try_add(&other.dv) { - Ok(result) => Ok(PyDV { dv: result }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Subtraction operator. - fn __sub__(&self, other: &PyDV) -> PyResult { - match self.dv.try_sub(&other.dv) { - Ok(result) => Ok(PyDV { dv: result }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Multiplication operator (DV * DV or DV * scalar). - fn __mul__(&self, other: &Bound<'_, PyAny>) -> PyResult { - // Try to extract as another PyDV - if let Ok(other_dv) = other.downcast::() { - let other_borrow = other_dv.borrow(); - Ok(PyDV { dv: &self.dv * &other_borrow.dv }) - } else if let Ok(scalar) = other.extract::() { - Ok(PyDV { dv: &self.dv * scalar }) - } else { - Err(PyTypeError::new_err("Cannot multiply DV with this type")) - } - } - - /// Right multiplication operator (scalar * DV). - fn __rmul__(&self, other: &Bound<'_, PyAny>) -> PyResult { - if let Ok(scalar) = other.extract::() { - Ok(PyDV { dv: scalar * &self.dv }) - } else { - Err(PyTypeError::new_err("Cannot multiply this type with DV")) - } - } - - /// Division operator (DV / DV or DV / scalar). - fn __truediv__(&self, other: &Bound<'_, PyAny>) -> PyResult { - // Try to extract as another PyDV - if let Ok(other_dv) = other.downcast::() { - let other_borrow = other_dv.borrow(); - Ok(PyDV { dv: &self.dv / &other_borrow.dv }) - } else if let Ok(scalar) = other.extract::() { - Ok(PyDV { dv: &self.dv / scalar }) - } else { - Err(PyTypeError::new_err("Cannot divide DV by this type")) - } - } - - /// Right division operator (scalar / DV). - fn __rtruediv__(&self, other: &Bound<'_, PyAny>) -> PyResult { - if let Ok(scalar) = other.extract::() { - Ok(PyDV { dv: scalar / &self.dv }) - } else { - Err(PyTypeError::new_err("Cannot divide this type by DV")) - } - } - - /// Power operator. - /// - /// Args: - /// exponent (int or float): The exponent - /// - /// Returns: - /// DV: The result of raising to the power - fn __pow__(&self, exponent: &Bound<'_, PyAny>, _modulo: Option<&Bound<'_, PyAny>>) -> PyResult { - if let Ok(exp_int) = exponent.extract::() { - Ok(PyDV { dv: self.dv.powi(exp_int) }) - } else if let Ok(exp_float) = exponent.extract::() { - match self.dv.powf(exp_float) { - Ok(result) => Ok(PyDV { dv: result }), - Err(e) => Err(DVError::new_err(e)), - } - } else { - Err(PyTypeError::new_err("Exponent must be int or float")) - } - } - - /// Negation operator. - fn __neg__(&self) -> PyDV { - PyDV { dv: -&self.dv } - } - - /// Absolute value. - fn __abs__(&self) -> PyDV { - PyDV { dv: self.dv.abs() } - } - - /// Equality comparison. - fn __eq__(&self, other: &PyDV) -> bool { - self.dv == other.dv - } - - /// Inequality comparison. - fn __ne__(&self, other: &PyDV) -> bool { - self.dv != other.dv - } - - /// Less than comparison. - fn __lt__(&self, other: &PyDV) -> PyResult { - match self.dv.partial_cmp(&other.dv) { - Some(std::cmp::Ordering::Less) => Ok(true), - Some(_) => Ok(false), - None => Err(DVError::new_err("Cannot compare values with incompatible units")), - } - } - - /// Less than or equal comparison. - fn __le__(&self, other: &PyDV) -> PyResult { - match self.dv.partial_cmp(&other.dv) { - Some(std::cmp::Ordering::Less) | Some(std::cmp::Ordering::Equal) => Ok(true), - Some(_) => Ok(false), - None => Err(DVError::new_err("Cannot compare values with incompatible units")), - } - } - - /// Greater than comparison. - fn __gt__(&self, other: &PyDV) -> PyResult { - match self.dv.partial_cmp(&other.dv) { - Some(std::cmp::Ordering::Greater) => Ok(true), - Some(_) => Ok(false), - None => Err(DVError::new_err("Cannot compare values with incompatible units")), - } - } - - /// Greater than or equal comparison. - fn __ge__(&self, other: &PyDV) -> PyResult { - match self.dv.partial_cmp(&other.dv) { - Some(std::cmp::Ordering::Greater) | Some(std::cmp::Ordering::Equal) => Ok(true), - Some(_) => Ok(false), - None => Err(DVError::new_err("Cannot compare values with incompatible units")), - } - } - - /// String representation (for developers/debugging). - fn __repr__(&self) -> String { - format!("DimensionalVariable({}, '{}')", self.dv.value(), self.dv.to_string().split_whitespace().skip(1).collect::>().join("")) - } - - /// String conversion (human-readable). - fn __str__(&self) -> String { - self.dv.to_string() - } - - // Mathematical functions - - /// Square root. - /// - /// Returns: - /// DV: The square root - /// - /// Raises: - /// DVError: If the operation fails - fn sqrt(&self) -> PyResult { - match self.dv.sqrt() { - Ok(result) => Ok(PyDV { dv: result }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Natural logarithm (requires unitless value). - /// - /// Returns: - /// DV: The natural logarithm (unitless) - /// - /// Raises: - /// DVError: If the value is not unitless - fn ln(&self) -> PyResult { - match self.dv.ln() { - Ok(result) => Ok(PyDV { dv: DimensionalVariable { value: result, unit: [0.0; 8] } }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Base-2 logarithm (requires unitless value). - /// - /// Returns: - /// DV: The base-2 logarithm (unitless) - /// - /// Raises: - /// DVError: If the value is not unitless - fn log2(&self) -> PyResult { - match self.dv.log2() { - Ok(result) => Ok(PyDV { dv: DimensionalVariable { value: result, unit: [0.0; 8] } }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Base-10 logarithm (requires unitless value). - /// - /// Returns: - /// DV: The base-10 logarithm (unitless) - /// - /// Raises: - /// DVError: If the value is not unitless - fn log10(&self) -> PyResult { - match self.dv.log10() { - Ok(result) => Ok(PyDV { dv: DimensionalVariable { value: result, unit: [0.0; 8] } }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Sine (requires angle). - /// - /// Returns: - /// DV: The sine (unitless) - /// - /// Raises: - /// DVError: If the value is not an angle - fn sin(&self) -> PyResult { - match self.dv.sin() { - Ok(result) => Ok(PyDV { dv: DimensionalVariable { value: result, unit: [0.0; 8] } }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Cosine (requires angle). - /// - /// Returns: - /// DV: The cosine (unitless) - /// - /// Raises: - /// DVError: If the value is not an angle - fn cos(&self) -> PyResult { - match self.dv.cos() { - Ok(result) => Ok(PyDV { dv: DimensionalVariable { value: result, unit: [0.0; 8] } }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Tangent (requires angle). - /// - /// Returns: - /// DV: The tangent (unitless) - /// - /// Raises: - /// DVError: If the value is not an angle - fn tan(&self) -> PyResult { - match self.dv.tan() { - Ok(result) => Ok(PyDV { dv: DimensionalVariable { value: result, unit: [0.0; 8] } }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Arcsine (requires unitless value in [-1, 1]). - /// - /// Returns: - /// DV: The arcsine as an angle in radians - /// - /// Raises: - /// DVError: If the value is not unitless or outside [-1, 1] - fn asin(&self) -> PyResult { - match self.dv.asin() { - Ok(result) => Ok(PyDV { dv: result }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Arccosine (requires unitless value in [-1, 1]). - /// - /// Returns: - /// DV: The arccosine as an angle in radians - /// - /// Raises: - /// DVError: If the value is not unitless or outside [-1, 1] - fn acos(&self) -> PyResult { - match self.dv.acos() { - Ok(result) => Ok(PyDV { dv: result }), - Err(e) => Err(DVError::new_err(e)), - } - } - - /// Arctangent (requires unitless value). - /// - /// Returns: - /// DV: The arctangent as an angle in radians - /// - /// Raises: - /// DVError: If the value is not unitless - fn atan(&self) -> PyResult { - match self.dv.atan() { - Ok(result) => Ok(PyDV { dv: result }), - Err(e) => Err(DVError::new_err(e)), - } - } -} - -/// Arcsine function for f64 input, returns DimensionalVariable in radians. -#[pyfunction] -fn asin(x: f64) -> PyResult { - match dv_rs::asin(x) { - Ok(result) => Ok(PyDV { dv: result }), - Err(e) => Err(DVError::new_err(e)), - } -} - -/// Arccosine function for f64 input, returns DimensionalVariable in radians. -#[pyfunction] -fn acos(x: f64) -> PyResult { - match dv_rs::acos(x) { - Ok(result) => Ok(PyDV { dv: result }), - Err(e) => Err(DVError::new_err(e)), - } -} - -/// Arctangent function for f64 input, returns DimensionalVariable in radians. -#[pyfunction] -fn atan(x: f64) -> PyResult { - match dv_rs::atan(x) { - Ok(result) => Ok(PyDV { dv: result }), - Err(e) => Err(DVError::new_err(e)), - } -} - -/// Python module for dv (DimensionalVariable). -#[pymodule] -fn dv_pyo3(m: &Bound<'_, PyModule>) -> PyResult<()> { - m.add_class::()?; - m.add("DVError", m.py().get_type::())?; - m.add_function(wrap_pyfunction!(asin, m)?)?; - m.add_function(wrap_pyfunction!(acos, m)?)?; - m.add_function(wrap_pyfunction!(atan, m)?)?; - Ok(()) -} diff --git a/python/wheels.bzl b/python/wheels.bzl new file mode 100644 index 0000000..7863ca1 --- /dev/null +++ b/python/wheels.bzl @@ -0,0 +1,185 @@ +load("@rules_cc//cc:defs.bzl", "cc_binary", "cc_library") +load("@rules_python//python:packaging.bzl", "py_wheel") + +WHEEL_PLATFORMS = select( + { + "//python:linux_aarch64": "linux_aarch64", + "//python:linux_x86_64": "linux_x86_64", + "//python:macos_arm64": "macosx_11_0_arm64", + "//python:macos_x86_64": "macosx_10_15_x86_64", + "//python:windows_x86_64": "win_amd64", + }, + no_match_error = "Wheel platform tags are only configured for Linux/macOS x86_64 and arm64, plus Windows x86_64.", +) + +def _nanobind_copts(repo_path, limited_api = False): + windows = [ + "/std:c++17", + "/I" + repo_path + "/include", + "/I" + repo_path + "/src", + "/I" + repo_path + "/ext/robin_map/include", + ] + posix = [ + "-std=c++17", + "-faligned-allocation", + "-fvisibility=hidden", + "-I" + repo_path + "/include", + "-I" + repo_path + "/src", + "-I" + repo_path + "/ext/robin_map/include", + ] + if limited_api: + windows = windows + ["/DPy_LIMITED_API=0x030C0000"] + posix = posix + ["-DPy_LIMITED_API=0x030C0000"] + return select({ + "//python:windows_x86_64": windows, + "//conditions:default": posix, + }) + +def dv_extension( + name, + nanobind_repo_path, + nanobind_whl_files, + nanobind_combined_src, + python_headers, + python_libs = None, + limited_api = False, + extra_deps = [], + linkopts = []): + wheel_files_target = "nanobind_wheel_files_{}".format(name) + native_target = "dv_ext_native_{}".format(name) + + cc_library( + name = wheel_files_target, + hdrs = [nanobind_whl_files], + ) + + deps = [ + ":generated_nanobind_header_lib", + ":" + wheel_files_target, + "//core/ffi/diplomat:dv_diplomat_capi_static", + python_headers, + ] + if python_libs: + deps.append(python_libs) + + resolved_linkopts = select({ + "//python:windows_x86_64": ["ntdll.lib"], + "//conditions:default": [], + }) + linkopts + + cc_binary( + name = native_target, + srcs = [ + "dv_ext_ext.cpp", + "sub_modules/dv_ext/BaseUnits_binding.cpp", + "sub_modules/dv_ext/DvError_binding.cpp", + "sub_modules/dv_ext/DimensionalVariable_binding.cpp", + nanobind_combined_src, + ], + copts = _nanobind_copts(nanobind_repo_path, limited_api = limited_api), + deps = deps + extra_deps, + linkopts = resolved_linkopts, + linkshared = True, + ) + +def dv_runtime_package(name, native_target): + so_target = "{}_so".format(name) + pyd_target = "{}_pyd".format(name) + + native.genrule( + name = so_target, + srcs = [native_target], + outs = ["dv_py/dv_ext.so"], + cmd_bash = "cp $< $(RULEDIR)/dv_py/dv_ext.so", + cmd_bat = "copy /Y \"$(location {})\" \"$(RULEDIR)\\dv_py\\dv_ext.so\" >NUL".format(native_target), + ) + + native.genrule( + name = pyd_target, + srcs = [native_target], + outs = ["dv_py/dv_ext.pyd"], + cmd_bash = "cp $< $(RULEDIR)/dv_py/dv_ext.pyd", + cmd_bat = "copy /Y \"$(location {})\" \"$(RULEDIR)\\dv_py\\dv_ext.pyd\" >NUL".format(native_target), + ) + + native.filegroup( + name = name, + srcs = select({ + "//python:windows_x86_64": [":" + pyd_target], + "//conditions:default": [":" + so_target], + }), + ) + +def dv_wheel( + name, + native_target, + abi, + python_tag, + dist_folder, + author, + author_email, + classifiers, + description_file, + distribution, + license, + project_urls, + python_requires, + summary, + version): + init_pkg_target = "{}_pkg_init".format(name) + so_pkg_target = "{}_pkg_so".format(name) + pyd_pkg_target = "{}_pkg_pyd".format(name) + contents_target = "{}_contents".format(name) + wheel_dir = name + + native.genrule( + name = init_pkg_target, + srcs = ["dv_py/__init__.py"], + outs = ["{}/dv_py/__init__.py".format(wheel_dir)], + cmd_bash = "cp $(location dv_py/__init__.py) $(RULEDIR)/{}/dv_py/__init__.py".format(wheel_dir), + cmd_bat = "copy /Y \"$(location dv_py/__init__.py)\" \"$(RULEDIR)\\{}\\dv_py\\__init__.py\" >NUL".format(wheel_dir), + ) + + native.genrule( + name = so_pkg_target, + srcs = [native_target], + outs = ["{}/dv_py/dv_ext.so".format(wheel_dir)], + cmd_bash = "cp $(location {1}) $(RULEDIR)/{0}/dv_py/dv_ext.so".format(wheel_dir, native_target), + cmd_bat = "copy /Y \"$(location {1})\" \"$(RULEDIR)\\{0}\\dv_py\\dv_ext.so\" >NUL".format(wheel_dir, native_target), + ) + + native.genrule( + name = pyd_pkg_target, + srcs = [native_target], + outs = ["{}/dv_py/dv_ext.pyd".format(wheel_dir)], + cmd_bash = "cp $(location {1}) $(RULEDIR)/{0}/dv_py/dv_ext.pyd".format(wheel_dir, native_target), + cmd_bat = "copy /Y \"$(location {1})\" \"$(RULEDIR)\\{0}\\dv_py\\dv_ext.pyd\" >NUL".format(wheel_dir, native_target), + ) + + native.filegroup( + name = contents_target, + srcs = select({ + "//python:windows_x86_64": [":" + init_pkg_target, ":" + pyd_pkg_target], + "//conditions:default": [":" + init_pkg_target, ":" + so_pkg_target], + }), + ) + + py_wheel( + name = name, + abi = abi, + author = author, + author_email = author_email, + classifiers = classifiers, + description_file = description_file, + distribution = distribution, + dist_folder = dist_folder, + license = license, + platform = WHEEL_PLATFORMS, + project_urls = project_urls, + python_requires = python_requires, + python_tag = python_tag, + strip_path_prefixes = ["python/{}".format(wheel_dir)], + summary = summary, + version = version, + deps = [":" + contents_target], + ) diff --git a/tests/BUILD.bazel b/tests/BUILD.bazel index 7477001..8178ffe 100644 --- a/tests/BUILD.bazel +++ b/tests/BUILD.bazel @@ -34,7 +34,7 @@ py_test( data = [":regression_vectors"], deps = [ "//python:dv_py", - "@pypi//pytest:pkg", + "@@rules_python++pip+pypi_312_312_pytest//:pkg", ], ) diff --git a/tests/regression_cpp_tests.cpp b/tests/regression_cpp_tests.cpp index 9d7de01..3122be9 100644 --- a/tests/regression_cpp_tests.cpp +++ b/tests/regression_cpp_tests.cpp @@ -19,6 +19,19 @@ bool nearly_equal(double actual, double expected, double abs_tol, double rel_tol return diff <= std::max(abs_tol, rel_tol * std::fabs(expected)); } +void expect_error_contains(const char* context, const std::string& needle, const std::function& fn) { + try { + fn(); + } catch (const std::exception& e) { + if (std::string(e.what()).find(needle) == std::string::npos) { + throw std::runtime_error(std::string(context) + ": expected error containing '" + needle + "', got '" + e.what() + "'"); + } + return; + } + + throw std::runtime_error(std::string(context) + ": expected exception"); +} + fs::path resolve_vector_path(const std::string& file_name) { std::vector candidates; @@ -304,10 +317,39 @@ void run_vector_file(const std::string& file_name) { } } +void run_error_message_checks() { + expect_error_contains("construct invalid unit", "Failed to parse unit 'nope'", []() { + dv::DV bad(1.0, "nope"); + }); + + expect_error_contains("convert incompatible unit", "Incompatible unit conversion to: s", []() { + dv::DV distance(1.0, "m"); + (void)distance.value_in("s"); + }); + + expect_error_contains("add incompatible units", "Incompatible units for addition", []() { + dv::DV distance(1.0, "m"); + dv::DV time(1.0, "s"); + (void)(distance + time); + }); + + expect_error_contains("ln dimensional quantity", "ln requires a unitless quantity", []() { + dv::DV distance(1.0, "m"); + (void)distance.ln(); + }); + + expect_error_contains("comparison incompatible units", "Incompatible units for comparison", []() { + dv::DV distance(1.0, "m"); + dv::DV time(1.0, "s"); + (void)(distance < time); + }); +} + int main() { try { run_vector_file("units_tests.json"); run_vector_file("math_tests.json"); + run_error_message_checks(); std::cout << "Regression vectors passed for C++\n"; return 0; } catch (const std::exception& e) { diff --git a/tools/BUILD.bazel b/tools/BUILD.bazel index ea8bfd8..8bab956 100644 --- a/tools/BUILD.bazel +++ b/tools/BUILD.bazel @@ -17,11 +17,10 @@ py_binary( data = [ "//:VERSION.toml", "//core:Cargo.toml", - "//python:Cargo.toml", "//python:pyproject.toml", ], deps = [ - "@pypi//toml", - "@pypi//requests", + "@@rules_python++pip+pypi_312_312_toml//:pkg", + "@@rules_python++pip+pypi_312_312_requests//:pkg", ], -) \ No newline at end of file +) diff --git a/tools/diplomat_codegen/BUILD.bazel b/tools/diplomat_codegen/BUILD.bazel new file mode 100644 index 0000000..a199421 --- /dev/null +++ b/tools/diplomat_codegen/BUILD.bazel @@ -0,0 +1,12 @@ +load("@rules_rust//rust:defs.bzl", "rust_binary") + +package(default_visibility = ["//visibility:public"]) + +rust_binary( + name = "diplomat_codegen", + srcs = ["main.rs"], + edition = "2021", + deps = [ + "@crates//:diplomat-tool", + ], +) diff --git a/tools/diplomat_codegen/main.rs b/tools/diplomat_codegen/main.rs new file mode 100644 index 0000000..7023703 --- /dev/null +++ b/tools/diplomat_codegen/main.rs @@ -0,0 +1,47 @@ +use std::env; +use std::path::PathBuf; + +use diplomat_tool::config::Config; +use diplomat_tool::DocsUrlGenerator; + +fn main() -> std::io::Result<()> { + let mut args = env::args().skip(1); + let target_language = args + .next() + .expect("usage: diplomat_codegen [--entry ]"); + let out_dir = PathBuf::from( + args.next() + .expect("usage: diplomat_codegen [--entry ]"), + ); + + let mut entry = PathBuf::from("src/lib.rs"); + let mut config = Config::default(); + let mut cli_config = Vec::new(); + while let Some(arg) = args.next() { + match arg.as_str() { + "--entry" => { + entry = PathBuf::from( + args.next() + .expect("--entry requires a path argument"), + ); + } + "--config" => { + cli_config.push( + args.next() + .expect("--config requires a key=value argument"), + ); + } + _ => panic!("unknown argument: {arg}"), + } + } + config.read_cli_settings(cli_config); + + diplomat_tool::gen( + &entry, + &target_language, + &out_dir, + &DocsUrlGenerator::with_base_urls(None, Default::default()), + config, + false, + ) +} diff --git a/tools/requirements.in b/tools/requirements.in index 61e1dd7..5d98ce1 100644 --- a/tools/requirements.in +++ b/tools/requirements.in @@ -1,4 +1,4 @@ toml requests pytest -maturin +nanobind diff --git a/tools/requirements.txt b/tools/requirements.txt index f5548f9..5266d4b 100644 --- a/tools/requirements.txt +++ b/tools/requirements.txt @@ -95,21 +95,9 @@ iniconfig==2.3.0 \ --hash=sha256:c76315c77db068650d49c5b56314774a7804df16fee4402c1f19d6d15d8c4730 \ --hash=sha256:f631c04d2c48c52b84d0d0549c99ff3859c98df65b3101406327ecc7d53fbf12 # via pytest -maturin==1.10.2 \ - --hash=sha256:04df81ee295dcda37828bd025a4ac688ea856e3946e4cb300a8f44a448de0069 \ - --hash=sha256:07a82864352feeaf2167247c8206937ef6c6ae9533025d416b7004ade0ea601d \ - --hash=sha256:11c73815f21a755d2129c410e6cb19dbfacbc0155bfc46c706b69930c2eb794b \ - --hash=sha256:259292563da89850bf8f7d37aa4ddba22905214c1e180b1c8f55505dfd8c0e81 \ - --hash=sha256:7fbd997c5347649ee7987bd05a92bd5b8b07efa4ac3f8bcbf6196e07eb573d89 \ - --hash=sha256:96e1d391e4c1fa87edf2a37e4d53d5f2e5f39dd880b9d8306ac9f8eb212d23f8 \ - --hash=sha256:a217aa7c42aa332fb8e8377eb07314e1f02cf0fe036f614aca4575121952addd \ - --hash=sha256:a41ec70d99e27c05377be90f8e3c3def2a7bae4d0d9d5ea874aaf2d1da625d5c \ - --hash=sha256:a4c29a770ea2c76082e0afc6d4efd8ee94405588bfae00d10828f72e206c739b \ - --hash=sha256:da031771d9fb6ddb1d373638ec2556feee29e4507365cd5749a2d354bcadd818 \ - --hash=sha256:da777766fd584440dc9fecd30059a94f85e4983f58b09e438ae38ee4b494024c \ - --hash=sha256:e3ce9b2ad4fb9c341f450a6d32dc3edb409a2d582a81bc46ba55f6e3b6196b22 \ - --hash=sha256:efcd496a3202ffe0d0489df1f83d08b91399782fb2dd545d5a1e7bf6fd81af39 \ - --hash=sha256:f0d1b7b5f73c8d30a7e71cd2a2189a7f0126a3a3cd8b3d6843e7e1d4db50f759 +nanobind==2.11.0 \ + --hash=sha256:6d98d063c61dbbd05a2d903e59be398bfcff9d59c54fbbc9d4488960485d40d0 \ + --hash=sha256:8097442c3e55d011a67f016ce1d9567ed9e3cdb3ad6749f13a76dbbc2721f0ee # via -r tools/requirements.in packaging==25.0 \ --hash=sha256:29572ef2b1f17581046b3a2227d5c611fb25ec70ca1ba8554b24b0e69331a484 \ diff --git a/tools/update_versions.py b/tools/update_versions.py index d7d2a82..3f56ead 100644 --- a/tools/update_versions.py +++ b/tools/update_versions.py @@ -2,6 +2,7 @@ import toml import requests import os +import re from pathlib import Path @@ -106,7 +107,7 @@ def update_rust(versions: tuple, dryrun: bool = False) -> bool: def update_python(versions: tuple, dryrun: bool = False) -> bool: - """Update the Python pyproject.toml and Cargo.toml versions based on the provided versions. + """Update the Python pyproject.toml version based on the provided versions. Args: versions (tuple): A tuple containing major, minor, and patch versions. dryrun (bool): If True, only check for consistency without making changes. @@ -131,17 +132,23 @@ def update_python(versions: tuple, dryrun: bool = False) -> bool: with open(pyproject_path, "r") as f: pyproject_toml = toml.load(f) - current_pyproject_version = pyproject_toml["project"]["version"] - - # Check Cargo.toml - cargo_path = workspace_root / "python" / "Cargo.toml" - with open(cargo_path, "r") as f: - cargo_toml = toml.load(f) + package_metadata_path = workspace_root / "python" / "package_metadata.bzl" + package_metadata_text = package_metadata_path.read_text() + version_match = re.search( + r'^PYTHON_PACKAGE_VERSION = "([^"]+)"$', + package_metadata_text, + re.MULTILINE, + ) + if not version_match: + raise ValueError( + f"Unable to find PYTHON_PACKAGE_VERSION in {package_metadata_path}" + ) - current_cargo_version = cargo_toml["package"]["version"] + current_pyproject_version = pyproject_toml["project"]["version"] + current_build_version = version_match.group(1) versions_match_pyproject = current_pyproject_version == version_str - versions_match_cargo = current_cargo_version == version_str + versions_match_build = current_build_version == version_str version_not_used = version_str not in pypi_versions has_passed = True @@ -155,17 +162,17 @@ def update_python(versions: tuple, dryrun: bool = False) -> bool: print("\t❌ Python package version is already published on PyPI.") has_passed &= False - if versions_match_pyproject and versions_match_cargo: + if versions_match_pyproject and versions_match_build: # Versions already match - print("\t✅ Python pyproject.toml and Cargo.toml versions are consistent.") + print("\t✅ Python package version metadata is consistent.") has_passed &= True else: if dryrun: - print("\t❌ Python package versions are inconsistent.") + print("\t❌ Python package version is inconsistent.") if not versions_match_pyproject: print(f"\t\tpyproject.toml: {current_pyproject_version}") - if not versions_match_cargo: - print(f"\t\tCargo.toml: {current_cargo_version}") + if not versions_match_build: + print(f"\t\tpackage_metadata.bzl: {current_build_version}") print(f"\t\tVersion.toml: {version_str}") has_passed &= False elif not version_not_used: @@ -183,13 +190,16 @@ def update_python(versions: tuple, dryrun: bool = False) -> bool: f"\t⚠️ Updated Python pyproject.toml version from {current_pyproject_version} to {version_str}." ) - # Update the version in Cargo.toml - if not versions_match_cargo: - cargo_toml["package"]["version"] = version_str - with open(cargo_path, "w") as f: - toml.dump(cargo_toml, f) + if not versions_match_build: + updated_package_metadata_text = re.sub( + r'^PYTHON_PACKAGE_VERSION = "([^"]+)"$', + f'PYTHON_PACKAGE_VERSION = "{version_str}"', + package_metadata_text, + flags = re.MULTILINE, + ) + package_metadata_path.write_text(updated_package_metadata_text) print( - f"\t⚠️ Updated Python Cargo.toml version from {current_cargo_version} to {version_str}." + f"\t⚠️ Updated Python package_metadata.bzl version from {current_build_version} to {version_str}." ) has_passed &= True