A high-performance inference engine for AI models
half-nixify ci (#1025)
uuuvn0d60981a899c
diff --git a/.config/platforms.toml b/.config/platforms.tomlindex 3842b6ff9..ebab54dc6 100644--- a/.config/platforms.toml+++ b/.config/platforms.toml@@ -9,9 +9,6 @@ WATCHOS_DEPLOYMENT_TARGET = "26.4"# Please make sure to use compatible versions of the cargo-swift / uniffi pair.# See: https://github.com/antoniusnaumann/cargo-swift?tab=readme-ov-file#installing-for-a-different-uniffi-versionswift = { provider = "cargo", version = "0.11.1" }-zigbuild = { provider = "cargo", version = "0.23.4" }-xwin = { provider = "cargo", version = "0.23.1" }-ziglang = { provider = "uv", version = "0.17.0" }maturin = { provider = "uv", version = "1.15.0" }[targets."aarch64-apple-darwin"]@@ -73,6 +70,12 @@ aliases = ["windows"]capabilities_supported = ["grammar"]capabilities_default = ["grammar"]+[targets."wasm32-unknown-unknown"]+backend = "cpu"+aliases = ["wasm"]+capabilities_supported = []+capabilities_default = []+[targets."wasm32-wasip1-threads"]backend = "cpu"aliases = ["wasi"]@@ -88,7 +91,7 @@ targets = ["aarch64-apple-ios-macabi","wasm32-wasip1-threads",]-tools = ["ziglang", "zigbuild", "xwin"]+tools = []bindings = []examples_path = "crates/legacy/uzu/examples"metadata = { image_url = "https://artifacts.trymirai.com/social/github/uzu-header.jpg", badges = [@@ -111,7 +114,7 @@ metadata = { image_url = "https://artifacts.trymirai.com/social/github/uzu-heade[languages.python]targets = ["aarch64-apple-darwin", "x86_64-apple-darwin"]-tools = ["ziglang", "zigbuild", "xwin", "maturin"]+tools = ["maturin"]bindings = ["pyo3"]examples_path = "crates/legacy/uzu/bindings/python/examples"metadata = { image_url = "https://artifacts.trymirai.com/social/github/uzu-python.jpg", badges = [@@ -149,7 +152,7 @@ metadata = { image_url = "https://artifacts.trymirai.com/social/github/uzu-swift[languages.typescript]targets = ["aarch64-apple-darwin", "x86_64-apple-darwin"]-tools = ["ziglang", "zigbuild", "xwin"]+tools = []bindings = ["napi"]examples_path = "crates/legacy/uzu/bindings/typescript/examples"metadata = { image_url = "https://artifacts.trymirai.com/social/github/uzu-typescript.jpg", badges = [diff --git a/.github/actions/setup-legacy/action.yml b/.github/actions/setup-legacy/action.ymlnew file mode 100644index 000000000..f66de3ef6--- /dev/null+++ b/.github/actions/setup-legacy/action.yml@@ -0,0 +1,30 @@+name: setup-legacy+description: Set up dependencies for macOS release workflows++inputs:+ python:+ description: "Install uv for Python builds and scripts"+ required: false+ default: 'false'++runs:+ using: composite+ steps:+ - uses: dtolnay/rust-toolchain@nightly++ - run: xcodebuild -downloadComponent MetalToolchain+ shell: bash++ - if: inputs.python == 'true'+ uses: astral-sh/[email protected]+ with:+ enable-cache: true++ - uses: actions/setup-node@v7+ with:+ node-version: '26'+ registry-url: "https://registry.npmjs.org"++ - uses: pnpm/action-setup@v6+ with:+ version: 12.9.0diff --git a/.github/actions/setup-nix/action.yml b/.github/actions/setup-nix/action.ymlnew file mode 100644index 000000000..ed570c3f8--- /dev/null+++ b/.github/actions/setup-nix/action.yml@@ -0,0 +1,22 @@+name: setup-nix+description: Load the Nix development environment++runs:+ using: composite+ steps:+ - name: Install Nix+ if: runner.os == 'Linux'+ uses: NixOS/nix-installer-action@v1++ - name: Locate Nix+ if: runner.os == 'macOS'+ shell: bash+ run: |+ if ! command -v nix >/dev/null 2>&1; then+ /nix/var/nix/profiles/default/bin/nix --version+ echo /nix/var/nix/profiles/default/bin >> "$GITHUB_PATH"+ fi++ - uses: nicknovitski/nix-develop@9be7cfb4b10451d3390a75dc18ad0465bed4932a # v1.2.1+ with:+ arguments: ${{ runner.os == 'macOS' && '.#host-xcode' || '.#default' }}diff --git a/.github/actions/setup/action.yml b/.github/actions/setup/action.ymldeleted file mode 100644index 8ac47340a..000000000--- a/.github/actions/setup/action.yml+++ /dev/null@@ -1,98 +0,0 @@-name: setup-description: Setup dependencies--inputs:- linters:- description: "Install linters"- required: false- default: 'false'- metal:- description: "Install metal toolchain"- required: false- default: 'false'- test_data:- description: "Download test data"- required: false- default: 'false'- nextest:- description: "Install nextest"- required: false- default: 'false'- target:- description: "Additional Rust target to install"- required: false- default: ''- bindings:- description: "Install bindings requirements"- required: false- default: 'false'- node-version:- description: "Node.js version for bindings and apps"- required: false- default: '26'--runs:- using: composite- steps:- - if: runner.os == 'Linux'- run: |- sudo apt-get update- sudo apt-get install -y libasound2-dev build-essential pkg-config- shell: bash-- # - if: runner.os == 'Linux'- # run: |- # sudo mkdir -p /data/cargo- # sudo chown runner:runner /data/cargo-- # mkdir -p ~/.cargo- # rm -rf ~/.cargo/registry && ln -sfn /data/cargo/registry ~/.cargo/registry- # rm -rf ~/.cargo/git && ln -sfn /data/cargo/git ~/.cargo/git- # shell: bash-- - uses: dtolnay/rust-toolchain@stable- with:- targets: ${{ inputs.target }}-- - uses: dtolnay/rust-toolchain@nightly- with:- targets: ${{ inputs.target }}- components: ${{ inputs.linters == 'true' && 'rustfmt,clippy' || '' }}-- # Wasmtime 47 removed WASI threads; use the maintained 36.x LTS line.- - if: inputs.target == 'wasm32-wasip1-threads'- uses: bytecodealliance/actions/wasmtime/setup@v1- with:- version: "36.0.18"-- - if: inputs.linters == 'true'- run: cargo install --locked cargo-deny- shell: bash-- - if: inputs.metal == 'true'- run: xcodebuild -downloadComponent MetalToolchain- shell: bash-- - if: inputs.nextest == 'true'- run: cargo install --locked cargo-nextest- shell: bash-- - if: inputs.bindings == 'true'- uses: astral-sh/[email protected]- with:- enable-cache: true-- - if: inputs.test_data == 'true'- run: cargo tools hanashi-tokenizers- shell: bash-- - if: inputs.bindings == 'true'- uses: actions/setup-node@v7- with:- node-version: ${{ inputs.node-version }}- registry-url: "https://registry.npmjs.org"-- - if: inputs.bindings == 'true'- uses: pnpm/action-setup@v6- with:- version: 12.14.0diff --git a/.github/workflows/release-mirai-gui.yml b/.github/workflows/release-mirai-gui.ymlindex e02e25e25..b4c0ed943 100644--- a/.github/workflows/release-mirai-gui.yml+++ b/.github/workflows/release-mirai-gui.yml@@ -92,10 +92,9 @@ jobs:with:ref: ${{ github.sha }}persist-credentials: false- - uses: ./.github/actions/setup+ - uses: ./.github/actions/setup-legacywith:- metal: true- bindings: true+ python: ${{ github.event_name == 'workflow_dispatch' }}# Fail here, not after the twenty-minute build.- name: Verify secrets and variables are configureddiff --git a/.github/workflows/release-uzu-pi-extension.yml b/.github/workflows/release-uzu-pi-extension.ymlindex a171fdd21..ddc2e648f 100644--- a/.github/workflows/release-uzu-pi-extension.yml+++ b/.github/workflows/release-uzu-pi-extension.yml@@ -66,11 +66,7 @@ jobs:with:ref: ${{ github.sha }}persist-credentials: false- - uses: ./.github/actions/setup- with:- metal: true- bindings: true- node-version: '26'+ - uses: ./.github/actions/setup-legacy- name: Wait for matching npm releaseif: ${{ github.event_name == 'release' }}diff --git a/.github/workflows/release.yml b/.github/workflows/release.ymlindex 2dfb161d4..dfed628d0 100644--- a/.github/workflows/release.yml+++ b/.github/workflows/release.yml@@ -62,10 +62,9 @@ jobs:jq -er '"message_id=" + (.id | strings | select(test("^[0-9]+$")))' >> "$GITHUB_OUTPUT"- uses: actions/checkout@v7- - uses: ./.github/actions/setup+ - uses: ./.github/actions/setup-legacywith:- metal: true- bindings: true+ python: true- name: "Release: Checkout main"uses: actions/checkout@v7@@ -194,11 +193,8 @@ jobs:- name: "Release: Install tools"run: |- cargo tools setup- cargo tools install rustcargo tools install pythoncargo tools install swift- cargo tools install typescript- name: "Release: Sync"run: cargo tools syncdiff --git a/.github/workflows/tests.yml b/.github/workflows/tests.ymlindex 917b8ca2f..fabc4b99e 100644--- a/.github/workflows/tests.yml+++ b/.github/workflows/tests.yml@@ -28,40 +28,37 @@ jobs:steps:- uses: actions/checkout@v7- id: setup- uses: ./.github/actions/setup- with:- linters: true- metal: true+ uses: ./.github/actions/setup-nix- name: Check uzu-engine rustfmt discovery- if: ${{ always() && steps.setup.outcome == 'success' }}+ if: ${{ !cancelled() && steps.setup.outcome == 'success' }}run: RUSTUP_TOOLCHAIN=nightly ./scripts/check-rustfmt-discovery.sh- name: Check Rust formatting- if: ${{ always() && steps.setup.outcome == 'success' }}+ if: ${{ !cancelled() && steps.setup.outcome == 'success' }}run: cargo +nightly fmt --check- name: Check Metal formatting- if: ${{ always() && steps.setup.outcome == 'success' }}+ if: ${{ !cancelled() && steps.setup.outcome == 'success' }}run: ./scripts/clang-format.sh --check- name: Lint with clippy- if: ${{ always() && steps.setup.outcome == 'success' }}+ if: ${{ !cancelled() && steps.setup.outcome == 'success' }}run: cargo +nightly clippy --workspace --all-targets -- -D warnings- name: Check that Cargo.lock is consistent with Cargo.toml- if: ${{ always() && steps.setup.outcome == 'success' }}+ if: ${{ !cancelled() && steps.setup.outcome == 'success' }}run: |cargo metadata --locked --format-version=1 > /dev/nullgit diff --exit-code -- Cargo.lock- name: Check with cargo-deny- if: ${{ always() && steps.setup.outcome == 'success' }}+ if: ${{ !cancelled() && steps.setup.outcome == 'success' }}# The GUI has a separate audit for its supported macOS target.run: cargo deny --exclude mirai-gui check -D warnings- name: Check sync- if: ${{ always() && steps.setup.outcome == 'success' }}+ if: ${{ !cancelled() && steps.setup.outcome == 'success' }}run: cargo tools sync --checktests:@@ -92,12 +89,11 @@ jobs:steps:- uses: actions/checkout@v7- - uses: ./.github/actions/setup- with:- metal: ${{ matrix.host == 'macos' && 'true' || 'false' }}- test_data: ${{ matrix.tests == true && 'true' || 'false' }}- nextest: ${{ matrix.tests && 'true' || 'false' }}- target: ${{ matrix.target }}+ - uses: ./.github/actions/setup-nix++ - name: Download test data+ if: ${{ matrix.tests == true }}+ run: cargo tools hanashi-tokenizers- name: Build cratesrun: |@@ -126,18 +122,7 @@ jobs:steps:- uses: actions/checkout@v7- - uses: ./.github/actions/setup- with:- metal: true- bindings: true-- - name: "Setup"- run: |- cargo tools setup- cargo tools install rust- cargo tools install python- cargo tools install swift- cargo tools install typescript+ - uses: ./.github/actions/setup-nix- name: "Verify"id: verify@@ -165,30 +150,26 @@ jobs:steps:- uses: actions/checkout@v7- - uses: ./.github/actions/setup- with:- linters: true- metal: true- bindings: true+ - uses: ./.github/actions/setup-nix- id: installname: Install dependenciesrun: pnpm install --frozen-lockfile- name: Typecheck- if: ${{ always() && steps.install.outcome == 'success' }}+ if: ${{ !cancelled() && steps.install.outcome == 'success' }}run: pnpm typecheck- name: Lint- if: ${{ always() && steps.install.outcome == 'success' }}+ if: ${{ !cancelled() && steps.install.outcome == 'success' }}run: pnpm lint- name: Check formatting- if: ${{ always() && steps.install.outcome == 'success' }}+ if: ${{ !cancelled() && steps.install.outcome == 'success' }}run: pnpm format:check- name: Check with cargo-deny- if: ${{ always() && steps.install.outcome == 'success' }}+ if: ${{ !cancelled() && steps.install.outcome == 'success' }}working-directory: apps/mirai-gui/desktoprun: cargo deny check -D warnings@@ -206,10 +187,7 @@ jobs:steps:- uses: actions/checkout@v7- - uses: ./.github/actions/setup- with:- metal: true- bindings: true+ - uses: ./.github/actions/setup-nix- name: Install dependenciesrun: pnpm install --frozen-lockfile@@ -228,10 +206,7 @@ jobs:steps:- uses: actions/checkout@v7- - uses: ./.github/actions/setup- with:- metal: true- bindings: true+ - uses: ./.github/actions/setup-nix- name: Install dependenciesrun: pnpm install --frozen-lockfile@@ -257,11 +232,7 @@ jobs:steps:- uses: actions/checkout@v7- - uses: ./.github/actions/setup- with:- metal: true- bindings: true- node-version: '26'+ - uses: ./.github/actions/setup-nix- name: Build monorepo bindingsworking-directory: crates/legacy/uzu/bindings/typescriptdiff --git a/README.md b/README.mdindex 1d499a3be..511799197 100644--- a/README.md+++ b/README.md@@ -1428,6 +1428,7 @@ It supports:- `aarch64-apple-ios-sim`- `aarch64-pc-windows-msvc` _(in progress)_- `aarch64-unknown-linux-gnu` _(in progress)_+ - `wasm32-unknown-unknown` _(in progress)_- `wasm32-wasip1-threads` _(in progress)_- `x86_64-apple-darwin`- `x86_64-pc-windows-msvc` _(in progress)_diff --git a/apps/mirai-gui/package.json b/apps/mirai-gui/package.jsonindex 8271e2c37..bff910b35 100644--- a/apps/mirai-gui/package.json+++ b/apps/mirai-gui/package.json@@ -3,7 +3,7 @@"version": "0.6.13","private": true,"type": "module",- "packageManager": "[email protected]",+ "packageManager": "[email protected]","scripts": {"dev": "tauri dev","build": "tauri build --target aarch64-apple-darwin",diff --git a/apps/mirai-gui/pnpm-lock.yaml b/apps/mirai-gui/pnpm-lock.yamlindex 1d0e13c1c..4b1103856 100644--- a/apps/mirai-gui/pnpm-lock.yaml+++ b/apps/mirai-gui/pnpm-lock.yaml@@ -7,153 +7,153 @@ importers:configDependencies: {}packageManagerDependencies:pnpm:- specifier: 12.14.0- version: 12.14.0+ specifier: 12.9.0+ version: 12.9.0packages:- '@pnpm/[email protected]':- resolution: {integrity: sha512-+iSh7x21C3A2hqc+Z0ZmbKTcn6YNlzrXM142PsnQH/dLj0DYxFzoBvc6XAnL/yfQ5nnH2ebBiRj/zVxr61fZbQ==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-/53fHFwP1mBYQjli6h3LBZsocAMjrEY6hCDiomIwdLIFbtxHrWucPg/s8ozOG3K6Qt8yEA78v7fCcNrgZKTlEQ==}cpu: [arm64]os: [android]- '@pnpm/[email protected]':- resolution: {integrity: sha512-qT+0LqEr2wBVaxcG2T8cX/R8SSRz2Rvpp8nRR4fh8tnGUZRch87gFmsHUAoSQh7w6j1h0qTjrA384j4xi8frvw==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-QI+Md3q3Df0WbDGpqciRw9ge0r7CGbxSlP3HcyIf34/YdZsbmUTl416oWOe3RrkZpVVVCA20f8B9esYrITpArA==}cpu: [x64]os: [android]- '@pnpm/[email protected]':- resolution: {integrity: sha512-tnrdUB8ecJoehuKKqi1YHCBVl61xtJ9XVGcx5EviC6fWO4DeGI8GtXrjvJxDBM3nuVjJeWistgsUp/N142x4sw==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-mWr7fGPYJ12GuvU/q0SyJfj7X/9Eqa5dA6cc+yUUAKRdYEcqW4lQcsDd1ArfxJNSDYooz9X+UhFeVxKO9e/xDA==}cpu: [arm64]os: [darwin]- '@pnpm/[email protected]':- resolution: {integrity: sha512-vlBfGkruqQRsEHTW43cPwpYd7QlbIJ//cvpAdb3bVXkI8SgTPoXhCnc05m+ZNiPrrEkBsX/t7KHw9aXpkzPm3Q==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-fr4ns4FyMLptdYbWqW3yc/yvbfQP7D1RBCFUJpSPr7tOzd3JxZvl+Tkvg65kEAGU5wXI6vl3eCOofumEj/n3Gw==}cpu: [x64]os: [darwin]- '@pnpm/[email protected]':- resolution: {integrity: sha512-Qg5rxBrGYl6Tfso+EyygPf84fY1Fzy55E/0or+iuYKtnf0vc0MlHJfVIlT7pBukMRntQHRik7hUi0Z4s7AlJsw==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-4+hZPeJzSSw1oOrfUg+v4QylHv6qKhdgcCnKt9ooryE79p1Z9oyozVJ5em+g6ajbvv6jlH+epnht8/s9Cp5M3Q==}cpu: [x64]os: [freebsd]- '@pnpm/[email protected]':- resolution: {integrity: sha512-DRIe4yQkXBGA/PhVJdzlbnllxBdAtnMMvTVLLcGpsK5FvJz9kxD2Hyxtn68ovmNkVX06f6p45cQwfm3wx2jn1A==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-+mHQSbA6M6W71PyV0IxYu2T43lZA8rAhlw4Gy7EMlyiv8H2GWJAXtUXl2huw7tnsar2AhCRlPn/ZvUv+/mIBkA==}cpu: [arm64]os: [linux]libc: [musl]- '@pnpm/[email protected]':- resolution: {integrity: sha512-7joGShZ44Nk3WpNU+60JoOPjCXlgxhJAq11S2UiVtwCUDgTer1yTPPfxGW8pxaD6046actYLIYDbZNlubHWs0A==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-U1mBoG27+J/HuWYtVZOQrvbiKnTlDsDVzyroKQqHsJaTHTXi0H5Y+fU1GjUyMcNG5r/EXtbhp9iAwQt64uXTxQ==}cpu: [arm64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':- resolution: {integrity: sha512-gSoryn7ySdXd//gjgf3MvvA8ZerJayaSbuMZMtAWq4vb2/wlVEgpl0Kvqt54y58TRj533Qjq2txKgnxd4JyoAQ==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-P5bgei3i6wjlKq6s4PNg/0cvik354upY2wW3YGSfweYTABnAZP2zGzgMc0eO5SHTz934Cbya8Z0YFRdw6MfmCg==}cpu: [ppc64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':- resolution: {integrity: sha512-EMjew1H9WqQ7pL+tYqCPwiuB+0PeCiJRV7fyWeuFw0wwYUajFBjcaPO3IGAVu9sdmJDU+e+HYv/Zey6aKae0Vw==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-oNx2uOo2gVrRckEvz7V+FKeq9HOF0rKNHcCyxRRHSXEXpmP6ZMMgJ+iU/m/zfSGp6bAcC5mvAE270FhAeIeKhA==}cpu: [riscv64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':- resolution: {integrity: sha512-shYOj/SFoXD35fHe0pWr2JofwSXulC0BnEIXLj2QokDi0EF//AfKsui35yKIkTEl+s2VJybc3PO4iJNhKIj5Qw==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-OChHS7hOlqdBMtZqjIB1QoZGNfzLPSsvTa2kYanf3qso5Q+KgnROQ+uV4a0wRGC6sdshSA63+Ui8MCylRy6iwA==}cpu: [s390x]os: [linux]libc: [glibc]- '@pnpm/[email protected]':- resolution: {integrity: sha512-btZiZ2Ot0llKK1ndSfA5i3IRX7/S0VrmzseNH/BJ4c+Cady+S81H6vvU1zByggHMyqQhC8OgxO5PiIY7D9bH0Q==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-ubZPsDMXS+LEnPa7wZD18E+KTpOAZPt+ms/khfIROt+6Cp0A2kayQA8aIsvV7+jGZD0xoknvaGN/P3v9OisZUg==}cpu: [x64]os: [linux]libc: [musl]- '@pnpm/[email protected]':- resolution: {integrity: sha512-F6K8e/jWxiuEYJaQtRRUG9ynBSTEHa+t7Lf86MKuOO5UA7WVVMbi+oB8nY6iKW++ncWS2yG6T9faXZGxqNsfoQ==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-ElANYUwQuMfWqMJR4m5L5h9zKjvGKcA8hi2put4J1DMx2smVaNGkGnxkgeIYgMjmF7UFxlZDcL4jItkScgsW4A==}cpu: [x64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':- resolution: {integrity: sha512-DOjlkVB6TtTKeAAe0hNZXn5S7YqESmo1Z6SGbR4BZNQ4isRg31XVHjX2RFTbY8gnZq68IwzyLmPqlEjMmYxofg==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-cqnBKZg5e9fFghmYtgJLyZOAsS1EyLeDVJ0qNsjR7hcc+dq1mWRiDo0erqdj2PGoYaVogyF9WejZSJoKvlfXDw==}cpu: [arm64]os: [win32]- '@pnpm/[email protected]':- resolution: {integrity: sha512-/LSX6mew/sLf08XqcjemuklNKf1K/Ftpgj4//hK/HKzI2dKbmxDB27a/2OaQ5a0O3/3OFzlssXDziZsi+yVBwQ==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-khqst6QGgHdKs2lEmz0N75qN/EoOcEywNQlRPfBrBrq1SytHra6ro/xViueJkVvDOz9gEO8oYcXTdZeAjErjMg==}cpu: [x64]os: [win32]- resolution: {integrity: sha512-wYum2HmT09Fky16JSPMrLAbuhUSH4GzY2GeBNC+z5btGNDZwNHEehoArqpw3vqkGzhkprQjXCITJfYAd8TOJpg==}+ resolution: {integrity: sha512-j2TvoLeSmGypiuVoeRvNdyKAfidMTwwdmFPGIRZJXFhBGduYdioqU0OxaE02G5rib90W1VFmbXY1NG0/roMN3Q==}engines: {node: '>=18.*'}hasBin: truesnapshots:- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: trueoptionalDependencies:- '@pnpm/exe.android-arm64': 12.14.0- '@pnpm/exe.android-x64': 12.14.0- '@pnpm/exe.darwin-arm64': 12.14.0- '@pnpm/exe.darwin-x64': 12.14.0- '@pnpm/exe.freebsd-x64': 12.14.0- '@pnpm/exe.linux-arm64': 12.14.0- '@pnpm/exe.linux-arm64-musl': 12.14.0- '@pnpm/exe.linux-ppc64': 12.14.0- '@pnpm/exe.linux-riscv64': 12.14.0- '@pnpm/exe.linux-s390x': 12.14.0- '@pnpm/exe.linux-x64': 12.14.0- '@pnpm/exe.linux-x64-musl': 12.14.0- '@pnpm/exe.win32-arm64': 12.14.0- '@pnpm/exe.win32-x64': 12.14.0+ '@pnpm/exe.android-arm64': 12.9.0+ '@pnpm/exe.android-x64': 12.9.0+ '@pnpm/exe.darwin-arm64': 12.9.0+ '@pnpm/exe.darwin-x64': 12.9.0+ '@pnpm/exe.freebsd-x64': 12.9.0+ '@pnpm/exe.linux-arm64': 12.9.0+ '@pnpm/exe.linux-arm64-musl': 12.9.0+ '@pnpm/exe.linux-ppc64': 12.9.0+ '@pnpm/exe.linux-riscv64': 12.9.0+ '@pnpm/exe.linux-s390x': 12.9.0+ '@pnpm/exe.linux-x64': 12.9.0+ '@pnpm/exe.linux-x64-musl': 12.9.0+ '@pnpm/exe.win32-arm64': 12.9.0+ '@pnpm/exe.win32-x64': 12.9.0---lockfileVersion: '9.0'diff --git a/apps/uzu-pi-extension/package.json b/apps/uzu-pi-extension/package.jsonindex 1dc00c3ce..5ffeee9be 100644--- a/apps/uzu-pi-extension/package.json+++ b/apps/uzu-pi-extension/package.json@@ -23,7 +23,7 @@"cpu": ["arm64"],- "packageManager": "[email protected]",+ "packageManager": "[email protected]","pi": {"extensions": ["./src/index.ts"@@ -36,7 +36,7 @@"scripts": {"build": "tsc -p tsconfig.build.json && node scripts/package.mjs","typecheck": "tsc --noEmit",- "test": "tsx --test tests/*.test.ts",+ "test": "node --enable-source-maps --import tsx --test tests/*.test.ts","check": "pnpm typecheck && pnpm test && pnpm build"},"dependencies": {diff --git a/apps/uzu-pi-extension/pnpm-lock.yaml b/apps/uzu-pi-extension/pnpm-lock.yamlindex 4e96f2bc6..ea6ca59fb 100644--- a/apps/uzu-pi-extension/pnpm-lock.yaml+++ b/apps/uzu-pi-extension/pnpm-lock.yaml@@ -7,153 +7,153 @@ importers:configDependencies: {}packageManagerDependencies:pnpm:- specifier: 12.14.0- version: 12.14.0+ specifier: 12.9.0+ version: 12.9.0packages:- '@pnpm/[email protected]':- resolution: {integrity: sha512-+iSh7x21C3A2hqc+Z0ZmbKTcn6YNlzrXM142PsnQH/dLj0DYxFzoBvc6XAnL/yfQ5nnH2ebBiRj/zVxr61fZbQ==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-/53fHFwP1mBYQjli6h3LBZsocAMjrEY6hCDiomIwdLIFbtxHrWucPg/s8ozOG3K6Qt8yEA78v7fCcNrgZKTlEQ==}cpu: [arm64]os: [android]- '@pnpm/[email protected]':- resolution: {integrity: sha512-qT+0LqEr2wBVaxcG2T8cX/R8SSRz2Rvpp8nRR4fh8tnGUZRch87gFmsHUAoSQh7w6j1h0qTjrA384j4xi8frvw==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-QI+Md3q3Df0WbDGpqciRw9ge0r7CGbxSlP3HcyIf34/YdZsbmUTl416oWOe3RrkZpVVVCA20f8B9esYrITpArA==}cpu: [x64]os: [android]- '@pnpm/[email protected]':- resolution: {integrity: sha512-tnrdUB8ecJoehuKKqi1YHCBVl61xtJ9XVGcx5EviC6fWO4DeGI8GtXrjvJxDBM3nuVjJeWistgsUp/N142x4sw==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-mWr7fGPYJ12GuvU/q0SyJfj7X/9Eqa5dA6cc+yUUAKRdYEcqW4lQcsDd1ArfxJNSDYooz9X+UhFeVxKO9e/xDA==}cpu: [arm64]os: [darwin]- '@pnpm/[email protected]':- resolution: {integrity: sha512-vlBfGkruqQRsEHTW43cPwpYd7QlbIJ//cvpAdb3bVXkI8SgTPoXhCnc05m+ZNiPrrEkBsX/t7KHw9aXpkzPm3Q==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-fr4ns4FyMLptdYbWqW3yc/yvbfQP7D1RBCFUJpSPr7tOzd3JxZvl+Tkvg65kEAGU5wXI6vl3eCOofumEj/n3Gw==}cpu: [x64]os: [darwin]- '@pnpm/[email protected]':- resolution: {integrity: sha512-Qg5rxBrGYl6Tfso+EyygPf84fY1Fzy55E/0or+iuYKtnf0vc0MlHJfVIlT7pBukMRntQHRik7hUi0Z4s7AlJsw==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-4+hZPeJzSSw1oOrfUg+v4QylHv6qKhdgcCnKt9ooryE79p1Z9oyozVJ5em+g6ajbvv6jlH+epnht8/s9Cp5M3Q==}cpu: [x64]os: [freebsd]- '@pnpm/[email protected]':- resolution: {integrity: sha512-DRIe4yQkXBGA/PhVJdzlbnllxBdAtnMMvTVLLcGpsK5FvJz9kxD2Hyxtn68ovmNkVX06f6p45cQwfm3wx2jn1A==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-+mHQSbA6M6W71PyV0IxYu2T43lZA8rAhlw4Gy7EMlyiv8H2GWJAXtUXl2huw7tnsar2AhCRlPn/ZvUv+/mIBkA==}cpu: [arm64]os: [linux]libc: [musl]- '@pnpm/[email protected]':- resolution: {integrity: sha512-7joGShZ44Nk3WpNU+60JoOPjCXlgxhJAq11S2UiVtwCUDgTer1yTPPfxGW8pxaD6046actYLIYDbZNlubHWs0A==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-U1mBoG27+J/HuWYtVZOQrvbiKnTlDsDVzyroKQqHsJaTHTXi0H5Y+fU1GjUyMcNG5r/EXtbhp9iAwQt64uXTxQ==}cpu: [arm64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':- resolution: {integrity: sha512-gSoryn7ySdXd//gjgf3MvvA8ZerJayaSbuMZMtAWq4vb2/wlVEgpl0Kvqt54y58TRj533Qjq2txKgnxd4JyoAQ==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-P5bgei3i6wjlKq6s4PNg/0cvik354upY2wW3YGSfweYTABnAZP2zGzgMc0eO5SHTz934Cbya8Z0YFRdw6MfmCg==}cpu: [ppc64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':- resolution: {integrity: sha512-EMjew1H9WqQ7pL+tYqCPwiuB+0PeCiJRV7fyWeuFw0wwYUajFBjcaPO3IGAVu9sdmJDU+e+HYv/Zey6aKae0Vw==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-oNx2uOo2gVrRckEvz7V+FKeq9HOF0rKNHcCyxRRHSXEXpmP6ZMMgJ+iU/m/zfSGp6bAcC5mvAE270FhAeIeKhA==}cpu: [riscv64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':- resolution: {integrity: sha512-shYOj/SFoXD35fHe0pWr2JofwSXulC0BnEIXLj2QokDi0EF//AfKsui35yKIkTEl+s2VJybc3PO4iJNhKIj5Qw==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-OChHS7hOlqdBMtZqjIB1QoZGNfzLPSsvTa2kYanf3qso5Q+KgnROQ+uV4a0wRGC6sdshSA63+Ui8MCylRy6iwA==}cpu: [s390x]os: [linux]libc: [glibc]- '@pnpm/[email protected]':- resolution: {integrity: sha512-btZiZ2Ot0llKK1ndSfA5i3IRX7/S0VrmzseNH/BJ4c+Cady+S81H6vvU1zByggHMyqQhC8OgxO5PiIY7D9bH0Q==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-ubZPsDMXS+LEnPa7wZD18E+KTpOAZPt+ms/khfIROt+6Cp0A2kayQA8aIsvV7+jGZD0xoknvaGN/P3v9OisZUg==}cpu: [x64]os: [linux]libc: [musl]- '@pnpm/[email protected]':- resolution: {integrity: sha512-F6K8e/jWxiuEYJaQtRRUG9ynBSTEHa+t7Lf86MKuOO5UA7WVVMbi+oB8nY6iKW++ncWS2yG6T9faXZGxqNsfoQ==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-ElANYUwQuMfWqMJR4m5L5h9zKjvGKcA8hi2put4J1DMx2smVaNGkGnxkgeIYgMjmF7UFxlZDcL4jItkScgsW4A==}cpu: [x64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':- resolution: {integrity: sha512-DOjlkVB6TtTKeAAe0hNZXn5S7YqESmo1Z6SGbR4BZNQ4isRg31XVHjX2RFTbY8gnZq68IwzyLmPqlEjMmYxofg==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-cqnBKZg5e9fFghmYtgJLyZOAsS1EyLeDVJ0qNsjR7hcc+dq1mWRiDo0erqdj2PGoYaVogyF9WejZSJoKvlfXDw==}cpu: [arm64]os: [win32]- '@pnpm/[email protected]':- resolution: {integrity: sha512-/LSX6mew/sLf08XqcjemuklNKf1K/Ftpgj4//hK/HKzI2dKbmxDB27a/2OaQ5a0O3/3OFzlssXDziZsi+yVBwQ==}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-khqst6QGgHdKs2lEmz0N75qN/EoOcEywNQlRPfBrBrq1SytHra6ro/xViueJkVvDOz9gEO8oYcXTdZeAjErjMg==}cpu: [x64]os: [win32]- resolution: {integrity: sha512-wYum2HmT09Fky16JSPMrLAbuhUSH4GzY2GeBNC+z5btGNDZwNHEehoArqpw3vqkGzhkprQjXCITJfYAd8TOJpg==}+ resolution: {integrity: sha512-j2TvoLeSmGypiuVoeRvNdyKAfidMTwwdmFPGIRZJXFhBGduYdioqU0OxaE02G5rib90W1VFmbXY1NG0/roMN3Q==}engines: {node: '>=18.*'}hasBin: truesnapshots:- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: trueoptionalDependencies:- '@pnpm/exe.android-arm64': 12.14.0- '@pnpm/exe.android-x64': 12.14.0- '@pnpm/exe.darwin-arm64': 12.14.0- '@pnpm/exe.darwin-x64': 12.14.0- '@pnpm/exe.freebsd-x64': 12.14.0- '@pnpm/exe.linux-arm64': 12.14.0- '@pnpm/exe.linux-arm64-musl': 12.14.0- '@pnpm/exe.linux-ppc64': 12.14.0- '@pnpm/exe.linux-riscv64': 12.14.0- '@pnpm/exe.linux-s390x': 12.14.0- '@pnpm/exe.linux-x64': 12.14.0- '@pnpm/exe.linux-x64-musl': 12.14.0- '@pnpm/exe.win32-arm64': 12.14.0- '@pnpm/exe.win32-x64': 12.14.0+ '@pnpm/exe.android-arm64': 12.9.0+ '@pnpm/exe.android-x64': 12.9.0+ '@pnpm/exe.darwin-arm64': 12.9.0+ '@pnpm/exe.darwin-x64': 12.9.0+ '@pnpm/exe.freebsd-x64': 12.9.0+ '@pnpm/exe.linux-arm64': 12.9.0+ '@pnpm/exe.linux-arm64-musl': 12.9.0+ '@pnpm/exe.linux-ppc64': 12.9.0+ '@pnpm/exe.linux-riscv64': 12.9.0+ '@pnpm/exe.linux-s390x': 12.9.0+ '@pnpm/exe.linux-x64': 12.9.0+ '@pnpm/exe.linux-x64-musl': 12.9.0+ '@pnpm/exe.win32-arm64': 12.9.0+ '@pnpm/exe.win32-x64': 12.9.0---lockfileVersion: '9.0'diff --git a/crates/legacy/cli-tools/src/languages/python.rs b/crates/legacy/cli-tools/src/languages/python.rsindex 6360d6f0a..4a5411ee2 100644--- a/crates/legacy/cli-tools/src/languages/python.rs+++ b/crates/legacy/cli-tools/src/languages/python.rs@@ -39,13 +39,11 @@ impl LanguageBackend for PythonLanguageBackend {) -> Result<()> {let paths = Paths::new()?;let bindings_path = paths.bindings_for_language_path(self.language());- let (zig_path, _) = Command::which("python-zig".to_string()).output()?;let host_target = self.config.host_target()?;for target in targets {let (_, stderr) = Command::maturin_build(target.name.clone(), target.features.clone(), configuration).with_current_path(&bindings_path)- .with_env("CARGO_ZIGBUILD_ZIG_PATH", &zig_path).with_envs(self.config.required_envs_for_target(target.name.clone())?).output()?;let wheel_path = parse_wheel_path(&stderr)?;diff --git a/crates/legacy/cli-tools/src/languages/typescript.rs b/crates/legacy/cli-tools/src/languages/typescript.rsindex 7d7ed9a4c..1f400a64d 100644--- a/crates/legacy/cli-tools/src/languages/typescript.rs+++ b/crates/legacy/cli-tools/src/languages/typescript.rs@@ -39,7 +39,6 @@ impl LanguageBackend for TypeScriptLanguageBackend {let manifest_path = paths.crate_manifest_path(&paths.main_crate);let bindings_path = paths.bindings_for_language_path(self.language());let output_path = paths.napi_output_path();- let (zig_path, _) = Command::which("python-zig".to_string()).output()?;Command::pnpm_install().with_current_path(&bindings_path).run()?;@@ -52,7 +51,6 @@ impl LanguageBackend for TypeScriptLanguageBackend {output_path.clone(),).with_current_path(&bindings_path)- .with_env("CARGO_ZIGBUILD_ZIG_PATH", &zig_path).with_envs(self.config.required_envs_for_target(target.name.clone())?).run()?;Command::pnpm_run("fix").with_current_path(&bindings_path).run()?;diff --git a/crates/legacy/cli-tools/src/types/command.rs b/crates/legacy/cli-tools/src/types/command.rsindex 34d17037e..0fcdc644f 100644--- a/crates/legacy/cli-tools/src/types/command.rs+++ b/crates/legacy/cli-tools/src/types/command.rs@@ -368,11 +368,6 @@ impl Command {configuration: Configuration,output_path: PathBuf,) -> Self {- let cross_flag = if target.contains("linux-gnu") {- "--use-napi-cross"- } else {- "-x"- };let mut command = Self::pnpm_exec().with_argument("napi").with_argument("build")@@ -382,8 +377,7 @@ impl Command {.with_arguments(vec!["--features".to_string(), features.join(",")]).with_argument("--platform").with_argument("--output-dir")- .with_argument(&output_path.to_string_lossy())- .with_argument(cross_flag);+ .with_argument(&output_path.to_string_lossy());command = match configuration {Configuration::Debug => command,Configuration::Release => command.with_argument("--release"),@@ -474,10 +468,6 @@ impl Command {}impl Command {- pub fn which(name: String) -> Self {- Self::new("which").with_argument(&name)- }-pub fn git_status_porcelain() -> Self {Self::new("git").with_argument("status").with_argument("--porcelain")}diff --git a/crates/legacy/uzu/bindings/typescript/package.json b/crates/legacy/uzu/bindings/typescript/package.jsonindex 7e3e129af..11f68be95 100644--- a/crates/legacy/uzu/bindings/typescript/package.json+++ b/crates/legacy/uzu/bindings/typescript/package.json@@ -8,7 +8,7 @@"type": "commonjs","repository": "https://github.com/trymirai/uzu","license": "MIT",- "packageManager": "[email protected]",+ "packageManager": "[email protected]","os": ["darwin"],diff --git a/crates/legacy/uzu/bindings/typescript/pnpm-lock.yaml b/crates/legacy/uzu/bindings/typescript/pnpm-lock.yamlindex 0f5bcbcbf..74cc66833 100644--- a/crates/legacy/uzu/bindings/typescript/pnpm-lock.yaml+++ b/crates/legacy/uzu/bindings/typescript/pnpm-lock.yaml@@ -6,196 +6,196 @@ importers:configDependencies: {}packageManagerDependencies:pnpm:- specifier: 12.14.0- version: 12.14.0+ specifier: 12.9.0+ version: 12.9.0packages:- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-+iSh7x21C3A2hqc+Z0ZmbKTcn6YNlzrXM142PsnQH/dLj0DYxFzoBvc6XAnL/yfQ5nnH2ebBiRj/zVxr61fZbQ==,+ integrity: sha512-/53fHFwP1mBYQjli6h3LBZsocAMjrEY6hCDiomIwdLIFbtxHrWucPg/s8ozOG3K6Qt8yEA78v7fCcNrgZKTlEQ==,}cpu: [arm64]os: [android]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-qT+0LqEr2wBVaxcG2T8cX/R8SSRz2Rvpp8nRR4fh8tnGUZRch87gFmsHUAoSQh7w6j1h0qTjrA384j4xi8frvw==,+ integrity: sha512-QI+Md3q3Df0WbDGpqciRw9ge0r7CGbxSlP3HcyIf34/YdZsbmUTl416oWOe3RrkZpVVVCA20f8B9esYrITpArA==,}cpu: [x64]os: [android]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-tnrdUB8ecJoehuKKqi1YHCBVl61xtJ9XVGcx5EviC6fWO4DeGI8GtXrjvJxDBM3nuVjJeWistgsUp/N142x4sw==,+ integrity: sha512-mWr7fGPYJ12GuvU/q0SyJfj7X/9Eqa5dA6cc+yUUAKRdYEcqW4lQcsDd1ArfxJNSDYooz9X+UhFeVxKO9e/xDA==,}cpu: [arm64]os: [darwin]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-vlBfGkruqQRsEHTW43cPwpYd7QlbIJ//cvpAdb3bVXkI8SgTPoXhCnc05m+ZNiPrrEkBsX/t7KHw9aXpkzPm3Q==,+ integrity: sha512-fr4ns4FyMLptdYbWqW3yc/yvbfQP7D1RBCFUJpSPr7tOzd3JxZvl+Tkvg65kEAGU5wXI6vl3eCOofumEj/n3Gw==,}cpu: [x64]os: [darwin]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-Qg5rxBrGYl6Tfso+EyygPf84fY1Fzy55E/0or+iuYKtnf0vc0MlHJfVIlT7pBukMRntQHRik7hUi0Z4s7AlJsw==,+ integrity: sha512-4+hZPeJzSSw1oOrfUg+v4QylHv6qKhdgcCnKt9ooryE79p1Z9oyozVJ5em+g6ajbvv6jlH+epnht8/s9Cp5M3Q==,}cpu: [x64]os: [freebsd]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-DRIe4yQkXBGA/PhVJdzlbnllxBdAtnMMvTVLLcGpsK5FvJz9kxD2Hyxtn68ovmNkVX06f6p45cQwfm3wx2jn1A==,+ integrity: sha512-+mHQSbA6M6W71PyV0IxYu2T43lZA8rAhlw4Gy7EMlyiv8H2GWJAXtUXl2huw7tnsar2AhCRlPn/ZvUv+/mIBkA==,}cpu: [arm64]os: [linux]libc: [musl]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-7joGShZ44Nk3WpNU+60JoOPjCXlgxhJAq11S2UiVtwCUDgTer1yTPPfxGW8pxaD6046actYLIYDbZNlubHWs0A==,+ integrity: sha512-U1mBoG27+J/HuWYtVZOQrvbiKnTlDsDVzyroKQqHsJaTHTXi0H5Y+fU1GjUyMcNG5r/EXtbhp9iAwQt64uXTxQ==,}cpu: [arm64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-gSoryn7ySdXd//gjgf3MvvA8ZerJayaSbuMZMtAWq4vb2/wlVEgpl0Kvqt54y58TRj533Qjq2txKgnxd4JyoAQ==,+ integrity: sha512-P5bgei3i6wjlKq6s4PNg/0cvik354upY2wW3YGSfweYTABnAZP2zGzgMc0eO5SHTz934Cbya8Z0YFRdw6MfmCg==,}cpu: [ppc64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-EMjew1H9WqQ7pL+tYqCPwiuB+0PeCiJRV7fyWeuFw0wwYUajFBjcaPO3IGAVu9sdmJDU+e+HYv/Zey6aKae0Vw==,+ integrity: sha512-oNx2uOo2gVrRckEvz7V+FKeq9HOF0rKNHcCyxRRHSXEXpmP6ZMMgJ+iU/m/zfSGp6bAcC5mvAE270FhAeIeKhA==,}cpu: [riscv64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-shYOj/SFoXD35fHe0pWr2JofwSXulC0BnEIXLj2QokDi0EF//AfKsui35yKIkTEl+s2VJybc3PO4iJNhKIj5Qw==,+ integrity: sha512-OChHS7hOlqdBMtZqjIB1QoZGNfzLPSsvTa2kYanf3qso5Q+KgnROQ+uV4a0wRGC6sdshSA63+Ui8MCylRy6iwA==,}cpu: [s390x]os: [linux]libc: [glibc]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-btZiZ2Ot0llKK1ndSfA5i3IRX7/S0VrmzseNH/BJ4c+Cady+S81H6vvU1zByggHMyqQhC8OgxO5PiIY7D9bH0Q==,+ integrity: sha512-ubZPsDMXS+LEnPa7wZD18E+KTpOAZPt+ms/khfIROt+6Cp0A2kayQA8aIsvV7+jGZD0xoknvaGN/P3v9OisZUg==,}cpu: [x64]os: [linux]libc: [musl]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-F6K8e/jWxiuEYJaQtRRUG9ynBSTEHa+t7Lf86MKuOO5UA7WVVMbi+oB8nY6iKW++ncWS2yG6T9faXZGxqNsfoQ==,+ integrity: sha512-ElANYUwQuMfWqMJR4m5L5h9zKjvGKcA8hi2put4J1DMx2smVaNGkGnxkgeIYgMjmF7UFxlZDcL4jItkScgsW4A==,}cpu: [x64]os: [linux]libc: [glibc]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-DOjlkVB6TtTKeAAe0hNZXn5S7YqESmo1Z6SGbR4BZNQ4isRg31XVHjX2RFTbY8gnZq68IwzyLmPqlEjMmYxofg==,+ integrity: sha512-cqnBKZg5e9fFghmYtgJLyZOAsS1EyLeDVJ0qNsjR7hcc+dq1mWRiDo0erqdj2PGoYaVogyF9WejZSJoKvlfXDw==,}cpu: [arm64]os: [win32]- '@pnpm/[email protected]':+ '@pnpm/[email protected]':resolution:{- integrity: sha512-/LSX6mew/sLf08XqcjemuklNKf1K/Ftpgj4//hK/HKzI2dKbmxDB27a/2OaQ5a0O3/3OFzlssXDziZsi+yVBwQ==,+ integrity: sha512-khqst6QGgHdKs2lEmz0N75qN/EoOcEywNQlRPfBrBrq1SytHra6ro/xViueJkVvDOz9gEO8oYcXTdZeAjErjMg==,}cpu: [x64]os: [win32]resolution:{- integrity: sha512-wYum2HmT09Fky16JSPMrLAbuhUSH4GzY2GeBNC+z5btGNDZwNHEehoArqpw3vqkGzhkprQjXCITJfYAd8TOJpg==,+ integrity: sha512-j2TvoLeSmGypiuVoeRvNdyKAfidMTwwdmFPGIRZJXFhBGduYdioqU0OxaE02G5rib90W1VFmbXY1NG0/roMN3Q==,}engines: { node: '>=18.*' }hasBin: truesnapshots:- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: true- '@pnpm/[email protected]':+ '@pnpm/[email protected]':optional: trueoptionalDependencies:- '@pnpm/exe.android-arm64': 12.14.0- '@pnpm/exe.android-x64': 12.14.0- '@pnpm/exe.darwin-arm64': 12.14.0- '@pnpm/exe.darwin-x64': 12.14.0- '@pnpm/exe.freebsd-x64': 12.14.0- '@pnpm/exe.linux-arm64': 12.14.0- '@pnpm/exe.linux-arm64-musl': 12.14.0- '@pnpm/exe.linux-ppc64': 12.14.0- '@pnpm/exe.linux-riscv64': 12.14.0- '@pnpm/exe.linux-s390x': 12.14.0- '@pnpm/exe.linux-x64': 12.14.0- '@pnpm/exe.linux-x64-musl': 12.14.0- '@pnpm/exe.win32-arm64': 12.14.0- '@pnpm/exe.win32-x64': 12.14.0+ '@pnpm/exe.android-arm64': 12.9.0+ '@pnpm/exe.android-x64': 12.9.0+ '@pnpm/exe.darwin-arm64': 12.9.0+ '@pnpm/exe.darwin-x64': 12.9.0+ '@pnpm/exe.freebsd-x64': 12.9.0+ '@pnpm/exe.linux-arm64': 12.9.0+ '@pnpm/exe.linux-arm64-musl': 12.9.0+ '@pnpm/exe.linux-ppc64': 12.9.0+ '@pnpm/exe.linux-riscv64': 12.9.0+ '@pnpm/exe.linux-s390x': 12.9.0+ '@pnpm/exe.linux-x64': 12.9.0+ '@pnpm/exe.linux-x64-musl': 12.9.0+ '@pnpm/exe.win32-arm64': 12.9.0+ '@pnpm/exe.win32-x64': 12.9.0---lockfileVersion: '9.0'diff --git a/flake.nix b/flake.nixindex b079308e1..36e7634e7 100644--- a/flake.nix+++ b/flake.nix@@ -24,11 +24,22 @@};rustToolchainNixCC = pkgs.rust-bin.fromRustupToolchainFile ./rust-toolchain.toml;- rustToolchainHostCC = rustToolchainNixCC.overrideAttrs (_: {- depsHostHostPropagated = [];- propagatedBuildInputs = [];- depsTargetTargetPropagated = [];- });+ rustToolchainStableNixCC = pkgs.rust-bin.fromRustupToolchain (+ (builtins.fromTOML (builtins.readFile ./rust-toolchain.toml)).toolchain // {channel = "stable";}+ );+ rustToolchainsNixCC = {+ nightly = rustToolchainNixCC;+ stable = rustToolchainStableNixCC;+ };+ withoutNixCC = toolchain:+ toolchain.overrideAttrs (_: {+ depsHostHostPropagated = [];+ propagatedBuildInputs = [];+ depsTargetTargetPropagated = [];+ });+ rustupShim = import ./scripts/rustup-shim.nix pkgs;+ rustShimNixCC = rustupShim (rustToolchainsNixCC // {default = "nightly";});+ rustShimHostCC = rustupShim ((pkgs.lib.mapAttrs (_: withoutNixCC) rustToolchainsNixCC) // {default = "nightly";});craneLibNixCC = (crane.mkLib pkgs).overrideToolchain rustToolchainNixCC;metal-toolchain = import ./scripts/metal-toolchain.nix pkgs {@@ -46,6 +57,7 @@[niluv+ maturinnodejs_26pnpm_12wasmtime_36@@ -60,8 +72,8 @@critcmp]++ (with pkgs; lib.optionals stdenv.hostPlatform.isDarwin [cargo-swift tuist]);- hostToolchainDevshellPackages = commonDevshellPackages ++ [rustToolchainHostCC];- nixToolchainDevshellPackages = commonDevshellPackages ++ [rustToolchainNixCC];+ hostToolchainDevshellPackages = commonDevshellPackages ++ [rustShimHostCC];+ nixToolchainDevshellPackages = commonDevshellPackages ++ [rustShimNixCC];mirai = craneLibNixCC.buildPackage {pname = "mirai";diff --git a/rust-toolchain.toml b/rust-toolchain.tomlindex e75da7261..a25ceeb9d 100644--- a/rust-toolchain.toml+++ b/rust-toolchain.toml@@ -9,6 +9,7 @@ targets = ["aarch64-apple-ios-sim","aarch64-pc-windows-msvc","aarch64-unknown-linux-gnu",+ "wasm32-unknown-unknown","wasm32-wasip1-threads","x86_64-apple-darwin","x86_64-pc-windows-msvc",diff --git a/scripts/rustup-shim.nix b/scripts/rustup-shim.nixnew file mode 100644index 000000000..c52112aaa--- /dev/null+++ b/scripts/rustup-shim.nix@@ -0,0 +1,133 @@+pkgs: {default, ...} @ args: let+ inherit (pkgs) lib;+ toolchains = builtins.removeAttrs args ["default"];+ channels = builtins.attrNames toolchains;+ propagatedDependencies =+ lib.genAttrs [+ "depsHostHostPropagated"+ "propagatedBuildInputs"+ "depsTargetTargetPropagated"+ ] (name: let+ dependencies = toolchains.${default}.${name} or [];+ in+ assert lib.assertMsg+ (lib.all (toolchain: (toolchain.${name} or []) == dependencies) (builtins.attrValues toolchains))+ "rustup-shim: toolchains disagree on ${name}"; dependencies);+ shim = ''+ #!${pkgs.runtimeShell}+ set -euo pipefail++ tool="''${0##*/}"++ if [[ "''${1-}" == +* ]]; then+ selection="''${1#+}"+ shift+ else+ selection="''${RUSTUP_TOOLCHAIN:-${default}}"+ fi++ if [[ "$tool" == rustup ]]; then+ kind="''${1-}"+ if [[ ( "$kind" != target && "$kind" != component ) || "''${2-}" != list ]]; then+ echo 'rustup-shim: supported commands: target list, component list' >&2+ exit 1+ fi+ shift 2+ installed_only=false+ while (( $# )); do+ case "$1" in+ --toolchain)+ if (( $# < 2 )); then+ echo 'rustup-shim: --toolchain requires a value' >&2+ exit 1+ fi+ selection="$2"+ shift 2+ ;;+ --toolchain=*) selection="''${1#*=}"; shift ;;+ --installed) installed_only=true; shift ;;+ *) printf "rustup-shim: unsupported argument '%s'\n" "$1" >&2; exit 1 ;;+ esac+ done+ fi++ case "$selection" in+ ${lib.concatMapStringsSep "\n" (channel: ''+ ${lib.escapeShellArg channel}|${lib.escapeShellArg (toString toolchains.${channel})})+ channel=${lib.escapeShellArg channel}+ toolchain=${lib.escapeShellArg (toString toolchains.${channel})}+ ;;+ '')+ channels}+ *)+ printf "rustup-shim: unknown toolchain '%s'; available: %s\n" "$selection" ${lib.escapeShellArg (lib.concatStringsSep ", " channels)} >&2+ exit 1+ ;;+ esac++ if [[ "$tool" == rustup ]]; then+ suffix=' (installed)'+ $installed_only && suffix=""+ if [[ "$kind" == target ]]; then+ shopt -s nullglob+ for target in "$toolchain"/lib/rustlib/*; do+ libraries=("$target"/lib/libcore-*.rlib)+ if (( ''${#libraries[@]} )); then+ printf '%s%s\n' "''${target##*/}" "$suffix"+ fi+ done+ elif [[ -f "$toolchain/lib/rustlib/src/rust/library/Cargo.toml" ]]; then+ printf 'rust-src%s\n' "$suffix"+ fi+ exit 0+ fi++ if [[ ! -f "$toolchain/bin/$tool" || ! -x "$toolchain/bin/$tool" ]]; then+ printf "rustup-shim: '%s' is not available in toolchain '%s'\n" "$tool" "$channel" >&2+ exit 127+ fi++ bin="${builtins.placeholder "out"}/bin"+ if [[ "''${PATH-}" != "$bin" && "''${PATH-}" != "$bin":* ]]; then+ export PATH="$bin''${PATH:+:$PATH}"+ fi++ cargo_home="''${CARGO_HOME:-''${HOME:+$HOME/.cargo}}"+ if [[ -n "$cargo_home" ]]; then+ [[ "$cargo_home" == /* ]] || cargo_home="$PWD/$cargo_home"+ case ":$PATH:" in+ *":$cargo_home/bin:"*) ;;+ *) export PATH="$PATH:$cargo_home/bin" ;;+ esac+ fi++ export RUSTUP_HOME="''${RUSTUP_HOME-}"+ export RUSTUP_TOOLCHAIN="$toolchain"++ exec "$toolchain/bin/$tool" "$@"+ '';+in+ pkgs.stdenvNoCC.mkDerivation (propagatedDependencies+ // {+ name = "rustup-shim";+ passthru = {inherit default toolchains;};+ inherit shim;+ passAsFile = ["shim"];+ dontUnpack = true;+ dontConfigure = true;+ dontBuild = true;+ installPhase = ''+ runHook preInstall++ mkdir -p "$out/bin"+ install -m755 "$shimPath" "$out/bin/rustup"++ for toolchain in ${lib.escapeShellArgs (map toString (builtins.attrValues toolchains))}; do+ for binary in "$toolchain"/bin/*; do+ ln -sfn "$out/bin/rustup" "$out/bin/''${binary##*/}"+ done+ done++ runHook postInstall+ '';+ })