From 014687c8ee650a225ccc59e5ff8e782cd38ea107 Mon Sep 17 00:00:00 2001 From: timohueser Date: Thu, 12 Nov 2026 16:46:37 +0100 Subject: [PATCH 1/4] builder: remove the desktop app Delete builder/desktop and the web code that only the desktop host reaches: the device page, the ride library page, the desktop page, the gating layer and the desktop platform. The hosted map builder keeps the device step; a browser with no WebUSB now shows "This browser cannot use the USB cable. Use Chrome or Edge." obc-usb stays for `obc format-card`. Its `open` returns only the link, and the Linux udev rule moves to builder/usb/linux with a README. CI loses the desktop-frontend and desktop jobs, and the tools, suites, licences and data readers lose their desktop entries. Co-Authored-By: Claude Opus 5.5 --- .claude/launch.json | 7 - .github/workflows/bake.yml | 4 +- .github/workflows/ci.yml | 165 +- .github/workflows/deploy-site.yml | 4 +- .gitignore | 5 +- Cargo.lock | 1 - Cargo.toml | 4 +- builder/__init__.py | 6 +- builder/desktop/.gitignore | 5 - builder/desktop/Cargo.lock | 5240 -------------- builder/desktop/Cargo.toml | 75 - builder/desktop/README.md | 150 - builder/desktop/build.rs | 3 - builder/desktop/capabilities/default.json | 7 - builder/desktop/e2e/launch.py | 138 - builder/desktop/icons/128x128.png | Bin 4001 -> 0 bytes builder/desktop/icons/128x128@2x.png | Bin 7903 -> 0 bytes builder/desktop/icons/32x32.png | Bin 1152 -> 0 bytes builder/desktop/icons/icon.icns | Bin 123390 -> 0 bytes builder/desktop/icons/icon.ico | Bin 285478 -> 0 bytes builder/desktop/icons/icon.png | Bin 15819 -> 0 bytes builder/desktop/src/catalog.rs | 56 - builder/desktop/src/http.rs | 74 - builder/desktop/src/main.rs | 224 - builder/desktop/src/map_output.rs | 144 - builder/desktop/src/paths.rs | 72 - builder/desktop/src/rides.rs | 1144 --- builder/desktop/src/usb/mod.rs | 252 - builder/desktop/src/usb/runtime_guard.rs | 51 - builder/desktop/src/usb/watch.rs | 130 - builder/desktop/tauri.conf.json | 40 - builder/usb/Cargo.toml | 3 +- builder/usb/README.md | 24 + .../linux/99-openbikecomputer.rules | 11 +- builder/usb/src/client/usb.rs | 4 +- builder/usb/src/lib.rs | 62 +- builder/web/package-lock.json | 11 - builder/web/package.json | 4 +- builder/web/src/App.svelte | 44 +- .../web/src/components/ConfirmDialog.svelte | 8 +- builder/web/src/components/DeviceChip.svelte | 172 - builder/web/src/components/Gated.svelte | 98 - builder/web/src/components/Header.svelte | 18 +- .../web/src/components/UpdatePrompt.svelte | 27 +- .../components/coverage/CorridorPanel.svelte | 3 - .../components/coverage/CoverageHome.svelte | 8 +- .../coverage/CoverageHome.svelte.test.ts | 3 +- .../components/coverage/DownloadStep.svelte | 76 +- .../src/components/device/DeviceStep.svelte | 116 +- .../components/device/DeviceSurfaces.svelte | 4 +- .../src/components/device/MapSendStep.svelte | 58 - .../web/src/components/device/PopMenu.svelte | 148 - .../src/components/device/PreviewModal.svelte | 932 --- .../src/components/device/RideExport.svelte | 2 - .../src/components/device/RideLibrary.svelte | 557 -- .../web/src/components/device/RideMap.svelte | 209 - .../src/components/device/RideTiles.svelte | 160 - .../src/components/device/RouteTiles.svelte | 152 - builder/web/src/components/device/Tile.svelte | 118 - .../src/components/device/TrackThumb.svelte | 127 - .../web/src/components/device/TripBand.svelte | 356 - .../components/device/TripDropDialog.svelte | 302 - builder/web/src/lib/catalog/client.test.ts | 6 +- builder/web/src/lib/catalog/client.ts | 4 +- builder/web/src/lib/constants.ts | 9 +- builder/web/src/lib/desktop/invoke.ts | 176 - builder/web/src/lib/desktop/library.test.ts | 43 - builder/web/src/lib/desktop/library.ts | 95 - builder/web/src/lib/desktop/release.test.ts | 38 - builder/web/src/lib/desktop/release.ts | 36 - builder/web/src/lib/desktop/usb.svelte.ts | 29 - builder/web/src/lib/desktop/usb.test.ts | 683 -- builder/web/src/lib/desktop/usb.ts | 551 -- .../src/lib/device/dashboard.svelte.test.ts | 194 - .../web/src/lib/device/dashboard.svelte.ts | 166 - builder/web/src/lib/device/elevation.test.ts | 287 - builder/web/src/lib/device/elevation.ts | 303 - builder/web/src/lib/device/library.test.ts | 523 -- builder/web/src/lib/device/library.ts | 462 -- builder/web/src/lib/device/manage.test.ts | 187 - builder/web/src/lib/device/manage.ts | 156 - builder/web/src/lib/device/multidrop.test.ts | 37 - builder/web/src/lib/device/multidrop.ts | 49 - builder/web/src/lib/device/progress.ts | 2 +- builder/web/src/lib/device/rideMap.test.ts | 124 - builder/web/src/lib/device/rideMap.ts | 171 - builder/web/src/lib/device/rides.ts | 2 +- builder/web/src/lib/device/segments.test.ts | 98 - builder/web/src/lib/device/segments.ts | 102 - builder/web/src/lib/device/session.svelte.ts | 15 +- builder/web/src/lib/device/thumbs.svelte.ts | 309 - builder/web/src/lib/device/thumbs.test.ts | 314 - builder/web/src/lib/device/tripDelete.test.ts | 102 - builder/web/src/lib/device/tripDelete.ts | 102 - builder/web/src/lib/platform/bundle.test.ts | 99 +- builder/web/src/lib/platform/desktop.ts | 99 - .../web/src/lib/platform/desktop.wire.test.ts | 112 - builder/web/src/lib/platform/dev.ts | 20 +- builder/web/src/lib/platform/gating.test.ts | 140 - builder/web/src/lib/platform/gating.ts | 165 - builder/web/src/lib/platform/hosts.test.ts | 57 +- builder/web/src/lib/platform/index.ts | 11 +- builder/web/src/lib/platform/types.ts | 48 +- .../web/src/lib/platform/web.download.test.ts | 21 +- builder/web/src/lib/platform/web.ts | 30 - builder/web/src/lib/router.svelte.ts | 23 +- builder/web/src/lib/routes.ts | 17 +- builder/web/src/lib/ui/confirm.svelte.ts | 10 +- builder/web/src/lib/ui/menu.ts | 13 - builder/web/src/lib/usb/pipe.ts | 11 +- builder/web/src/lib/usb/session.svelte.ts | 15 +- builder/web/src/lib/usb/session.ts | 18 +- builder/web/src/lib/usb/webusb.test.ts | 4 +- builder/web/src/lib/usb/webusb.ts | 11 +- builder/web/src/routes/Desktop.svelte | 130 - builder/web/src/routes/Device.svelte | 897 --- builder/web/src/routes/Rides.svelte | 115 - builder/web/test-support/data/review.json | 2 +- .../web/test-support/data/run-planned.json | 3 +- builder/web/test-support/data/status.json | 6 +- builder/web/vite.config.ts | 12 +- builder/web/vite/third-party-licenses.ts | 7 +- firmware/obc-app/src/harness/upload.rs | 7 +- firmware/obc-fw-nrf54l/src/usb/mod.rs | 2 +- firmware/tools/dependency_rules.json | 4 +- host/obc-bake/src/bin/obc-pack.rs | 4 +- host/obc-bake/src/pipeline.rs | 4 +- host/obc-bake/tests/packer_cases/pipeline.rs | 8 +- host/obc-data-steps/src/device/catalog.rs | 2 +- host/obc-data-steps/src/readers.rs | 4 - host/obc-data/README.md | 4 +- host/obc-data/src/cli/serve_cli.rs | 6 +- host/obc-draw/src/land.rs | 7 +- host/obc-map-core/src/progress.rs | 4 +- pyproject.toml | 2 - tools/fixture_catalog.py | 44 +- tools/install-geos.sh | 4 - tools/justfile | 47 +- tools/licenses/THIRD-PARTY.md | 6123 +---------------- tools/licenses/deny.toml | 17 +- tools/licenses/gen-third-party.sh | 13 +- tools/obc.bash | 4 +- tools/ready.py | 1 - tools/test_plan.py | 7 +- tools/testing/prose-baseline.json | 1 - tools/testing/suites.toml | 23 +- tools/tests/test_ci_aggregate.py | 30 +- tools/tests/test_ready.py | 2 +- tools/tests/test_selection_plan.py | 18 +- tools/verification/ops/download_reports.py | 2 +- tools/verification/ops/import_results.py | 2 +- uv.lock | 282 +- 152 files changed, 325 insertions(+), 25642 deletions(-) delete mode 100644 builder/desktop/.gitignore delete mode 100644 builder/desktop/Cargo.lock delete mode 100644 builder/desktop/Cargo.toml delete mode 100644 builder/desktop/README.md delete mode 100644 builder/desktop/build.rs delete mode 100644 builder/desktop/capabilities/default.json delete mode 100644 builder/desktop/e2e/launch.py delete mode 100644 builder/desktop/icons/128x128.png delete mode 100644 builder/desktop/icons/128x128@2x.png delete mode 100644 builder/desktop/icons/32x32.png delete mode 100644 builder/desktop/icons/icon.icns delete mode 100644 builder/desktop/icons/icon.ico delete mode 100644 builder/desktop/icons/icon.png delete mode 100644 builder/desktop/src/catalog.rs delete mode 100644 builder/desktop/src/http.rs delete mode 100644 builder/desktop/src/main.rs delete mode 100644 builder/desktop/src/map_output.rs delete mode 100644 builder/desktop/src/paths.rs delete mode 100644 builder/desktop/src/rides.rs delete mode 100644 builder/desktop/src/usb/mod.rs delete mode 100644 builder/desktop/src/usb/runtime_guard.rs delete mode 100644 builder/desktop/src/usb/watch.rs delete mode 100644 builder/desktop/tauri.conf.json create mode 100644 builder/usb/README.md rename builder/{desktop => usb}/linux/99-openbikecomputer.rules (79%) delete mode 100644 builder/web/src/components/DeviceChip.svelte delete mode 100644 builder/web/src/components/Gated.svelte delete mode 100644 builder/web/src/components/device/MapSendStep.svelte delete mode 100644 builder/web/src/components/device/PopMenu.svelte delete mode 100644 builder/web/src/components/device/PreviewModal.svelte delete mode 100644 builder/web/src/components/device/RideLibrary.svelte delete mode 100644 builder/web/src/components/device/RideMap.svelte delete mode 100644 builder/web/src/components/device/RideTiles.svelte delete mode 100644 builder/web/src/components/device/RouteTiles.svelte delete mode 100644 builder/web/src/components/device/Tile.svelte delete mode 100644 builder/web/src/components/device/TrackThumb.svelte delete mode 100644 builder/web/src/components/device/TripBand.svelte delete mode 100644 builder/web/src/components/device/TripDropDialog.svelte delete mode 100644 builder/web/src/lib/desktop/invoke.ts delete mode 100644 builder/web/src/lib/desktop/library.test.ts delete mode 100644 builder/web/src/lib/desktop/library.ts delete mode 100644 builder/web/src/lib/desktop/release.test.ts delete mode 100644 builder/web/src/lib/desktop/release.ts delete mode 100644 builder/web/src/lib/desktop/usb.svelte.ts delete mode 100644 builder/web/src/lib/desktop/usb.test.ts delete mode 100644 builder/web/src/lib/desktop/usb.ts delete mode 100644 builder/web/src/lib/device/dashboard.svelte.test.ts delete mode 100644 builder/web/src/lib/device/dashboard.svelte.ts delete mode 100644 builder/web/src/lib/device/elevation.test.ts delete mode 100644 builder/web/src/lib/device/elevation.ts delete mode 100644 builder/web/src/lib/device/library.test.ts delete mode 100644 builder/web/src/lib/device/library.ts delete mode 100644 builder/web/src/lib/device/manage.test.ts delete mode 100644 builder/web/src/lib/device/manage.ts delete mode 100644 builder/web/src/lib/device/multidrop.test.ts delete mode 100644 builder/web/src/lib/device/multidrop.ts delete mode 100644 builder/web/src/lib/device/rideMap.test.ts delete mode 100644 builder/web/src/lib/device/rideMap.ts delete mode 100644 builder/web/src/lib/device/segments.test.ts delete mode 100644 builder/web/src/lib/device/segments.ts delete mode 100644 builder/web/src/lib/device/thumbs.svelte.ts delete mode 100644 builder/web/src/lib/device/thumbs.test.ts delete mode 100644 builder/web/src/lib/device/tripDelete.test.ts delete mode 100644 builder/web/src/lib/device/tripDelete.ts delete mode 100644 builder/web/src/lib/platform/desktop.ts delete mode 100644 builder/web/src/lib/platform/desktop.wire.test.ts delete mode 100644 builder/web/src/lib/platform/gating.test.ts delete mode 100644 builder/web/src/lib/platform/gating.ts delete mode 100644 builder/web/src/lib/ui/menu.ts delete mode 100644 builder/web/src/routes/Desktop.svelte delete mode 100644 builder/web/src/routes/Device.svelte delete mode 100644 builder/web/src/routes/Rides.svelte diff --git a/.claude/launch.json b/.claude/launch.json index 49410ac402..adc89e47dd 100644 --- a/.claude/launch.json +++ b/.claude/launch.json @@ -21,13 +21,6 @@ "cwd": "builder/web", "port": 5173 }, - { - "name": "web-builder-desktop", - "runtimeExecutable": "npm", - "runtimeArgs": ["run", "dev", "--", "--mode", "desktop", "--port", "5173"], - "cwd": "builder/web", - "port": 5173 - }, { "name": "data-page", "runtimeExecutable": "tools/obc", diff --git a/.github/workflows/bake.yml b/.github/workflows/bake.yml index c16686dd6e..d590278a3c 100644 --- a/.github/workflows/bake.yml +++ b/.github/workflows/bake.yml @@ -1,7 +1,7 @@ name: Bake -# Build catalog cells once, centrally, so the website and desktop app can select, -# download, and assemble the same verified inputs. +# Build catalog cells once, centrally, so the website can select, download, and +# assemble the same verified inputs. # # ── READ THIS BEFORE ADDING A COUNTRY TO THE MATRIX ──────────────────────────────── # diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 686d9c81c9..102929b9af 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,12 +21,7 @@ name: CI # board crate; its job adds a flash-size guard against the 32 KB slot. # * obc-builder-bridge is a workspace library and the builder's shared WASM core. # The wasm-bridges job gates its production size and hands the same bytes to frontend jobs. -# * obc-desktop (#906) is the third excluded + standalone crate: a Tauri app, so it brings a -# platform webview with it (WebKitGTK on Linux) and would otherwise put those headers in -# every renderer test's way. The shell embeds the frontend, so both halves are built there. -# The planner artifact verifier also needs the locked Node reader dependencies. -# It is the only **three-OS matrix** in this file because it is the artifact a user installs. -# * `--locked` everywhere so a stale Cargo.lock (any of the four) fails CI. +# * `--locked` everywhere so a stale Cargo.lock (any of them) fails CI. on: workflow_call: @@ -208,9 +203,6 @@ jobs: echo "::group::obc-boot (workspace-excluded)" cargo fmt --check --manifest-path firmware/obc-boot/Cargo.toml || rc=1 echo "::endgroup::" - echo "::group::obc-desktop (workspace-excluded)" - cargo fmt --check --manifest-path builder/desktop/Cargo.toml || rc=1 - echo "::endgroup::" exit $rc # Blocking clippy on the host workspace: -D warnings from day one (the baseline is clean). @@ -673,10 +665,6 @@ jobs: run: cargo deny --manifest-path firmware/obc-boot/Cargo.toml --all-features --config tools/licenses/deny.toml check - name: cargo-deny (obc-sensor-sim) run: cargo deny --manifest-path firmware/obc-sensor-sim/Cargo.toml --all-features --config tools/licenses/deny.toml check - # The desktop shell is the one artifact a *user* installs, so its tree is the - # one where a bad licence or a live advisory matters most. - - name: cargo-deny (obc-desktop app) - run: cargo deny --manifest-path builder/desktop/Cargo.toml --all-features --config tools/licenses/deny.toml check # deny.toml skips the repository's own crates, so it cannot see obc-data reach one. - name: obc-data depends on no GPL crate run: python3 tools/check_obc_data_licence.py @@ -1000,9 +988,8 @@ jobs: # The web builder's Svelte frontend: type-check, unit tests, production builds. # - # One source tree, three hosts (#895): `npm run build` is the local FastAPI one, - # `build:web` the static hosted site and `build:desktop` the Tauri shell. All three - # are built here — a host that stops compiling is otherwise invisible until someone + # One source tree, two hosts: `npm run build` is the local FastAPI one and + # `build:web` the static hosted site. Both are built here — a host that stops compiling is otherwise invisible until someone # tries to ship it. The *contents* of the web bundle (no job polling, no style # editor) are asserted by vitest, which builds and inspects the emitted chunks. # @@ -1029,8 +1016,7 @@ jobs: with: name: obc-builder-bridge-pkg path: builder/web/src/lib/core/pkg - # The device the USB suites run against. The desktop-frontend job does not download it: that - # job only builds the shipped bundle, which must not contain this package at all. + # The device the USB suites run against. The shipped bundle must not contain this package. - uses: actions/download-artifact@v4 with: name: obc-flat-device-pkg @@ -1048,7 +1034,7 @@ jobs: run: | rm -f "$RUNNER_TEMP/web-builder-junit.xml" npm run test:components -- --reporter=default --reporter=junit --outputFile="$RUNNER_TEMP/web-builder-junit.xml" - - name: production builds (dev + web + desktop hosts) + - name: production builds (dev + web hosts) run: npm run build:all # naga is the WGSL front end of Firefox; Chrome's Tint compiles the same files in the TrailView smoke. - name: Cache the WGSL validator @@ -1133,145 +1119,6 @@ jobs: path: .artifacts/web-builder/ if-no-files-found: error - desktop-frontend: - needs: [selection, wasm-bridges] - if: contains(fromJSON(needs.selection.outputs.jobs), 'desktop-frontend') - runs-on: ubuntu-24.04 - steps: - - uses: actions/checkout@v4 - with: - ref: ${{ inputs.source_sha || github.sha }} - persist-credentials: false - - uses: actions/download-artifact@v4 - with: - name: obc-builder-bridge-pkg - path: builder/web/src/lib/core/pkg - - uses: actions/setup-node@v4 - with: - node-version: 22 - cache: npm - cache-dependency-path: builder/web/package-lock.json - - name: Build the desktop bundle - working-directory: builder/web - run: | - npm ci - npm run build:desktop - - uses: actions/upload-artifact@v4 - with: - name: obc-desktop-frontend - path: builder/web/dist/desktop - retention-days: 1 - - desktop: - needs: [selection, desktop-frontend] - if: contains(fromJSON(needs.selection.outputs.jobs), 'desktop') - runs-on: ${{ matrix.os }} - env: - # Baked into packaged apps; a runtime variable can still override it for a - # maintainer testing an unpublished tree. - OBC_CATALOG_URL: ${{ vars.OBC_CATALOG_URL }} - strategy: - # One platform's failure must not hide another's. - fail-fast: false - matrix: - include: - - os: ubuntu-24.04 - slug: linux-x86_64 - exe: obc-desktop - - os: macos-latest - slug: macos-arm64 - exe: obc-desktop - - os: windows-latest - slug: windows-x86_64-msvc - exe: obc-desktop.exe - defaults: - run: - # Git Bash on the Windows runner, so the shared steps below are one script - # rather than three. Nothing here needs a Windows-native shell. - shell: bash - steps: - - uses: actions/checkout@v4 - with: - ref: ${{ inputs.source_sha || github.sha }} - persist-credentials: false - - uses: actions-rust-lang/setup-rust-toolchain@v1 - with: - cache: false - - uses: Swatinem/rust-cache@v2 - with: - workspaces: builder/desktop - key: desktop-${{ matrix.slug }} - # wry's Linux backend. macOS and Windows need nothing extra — which is most of - # why Tauri was chosen over Electron (#906) — but Linux wants WebKitGTK. - - name: Install the Linux webview deps - if: runner.os == 'Linux' - uses: ./.github/actions/apt-install - with: - packages: libwebkit2gtk-4.1-dev libsoup-3.0-dev libjavascriptcoregtk-4.1-dev libgtk-3-dev librsvg2-dev - # The bundle the shell embeds, built once on Linux by `desktop-frontend` and - # unpacked here. It is byte-identical on all three runners — a Vite build of the - # same sources — so building it per-platform was three runs of `npm ci` and - # three Node toolchains for one output. Landing it at the path tauri.conf.json's - # `frontendDist` names is the whole integration; nothing here runs npm, and the - # `beforeBuildCommand` in that file is never executed (there is no Tauri CLI in - # this repo — see the note above about `custom-protocol`). - - uses: actions/download-artifact@v4 - with: - name: obc-desktop-frontend - path: builder/web/dist/desktop - # Order matters. `cargo test` never produces the plain binary — even with - # --all-targets it builds bins as *test harnesses*, a different artifact — so the - # `build` below is a full codegen + link either way. Running it first means the - # normal lib it produces is already there for `test` to link against, instead of - # `test` building one set of artifacts and `build` starting a second. - - name: "obc-desktop: clippy" - working-directory: builder/desktop - run: cargo clippy --release --all-targets --locked -- -D warnings - - name: "obc-desktop: build (release)" - working-directory: builder/desktop - run: cargo build --release --locked - - uses: taiki-e/install-action@v2 - with: - tool: cargo-nextest@0.9.143 - - name: "obc-desktop: test" - id: desktop-tests - working-directory: builder/desktop - env: - NEXTEST_PROFILE: ci - run: | - rm -f target/nextest/ci/junit.xml - cargo nextest run --release --locked --config-file ../../.config/nextest.toml --no-tests fail - - name: Upload native desktop test results - if: ${{ !cancelled() && (steps.desktop-tests.outcome == 'success' || steps.desktop-tests.outcome == 'failure') }} - uses: actions/upload-artifact@v4 - with: - name: desktop-tests-${{ matrix.slug }}-${{ github.run_attempt }} - path: builder/desktop/target/nextest/ci/junit.xml - if-no-files-found: error - # Recorded so an accidental native dependency or bundling regression is visible. - - name: "obc-desktop: record the artifact size" - working-directory: builder/desktop - run: | - bytes=$(wc -c < "target/release/${{ matrix.exe }}") - echo "| ${{ matrix.slug }} | $bytes bytes |" >> "$GITHUB_STEP_SUMMARY" - - uses: actions/upload-artifact@v4 - with: - name: obc-desktop-${{ matrix.slug }} - path: builder/desktop/target/release/${{ matrix.exe }} - retention-days: 7 - # macOS ships two architectures and this crate is built on the Apple-silicon - # runner, so cross-build the Intel slice to keep a future universal bundle open. - # - # Push events only: a second target triple is build-only insurance, not a - # correctness gate on the app anyone runs. - - name: "obc-desktop: the macOS Intel slice (build-only)" - if: runner.os == 'macOS' && github.event_name == 'push' - working-directory: builder/desktop - run: | - rustup target add x86_64-apple-darwin - cargo build --release --locked --target x86_64-apple-darwin - file target/x86_64-apple-darwin/release/obc-desktop - planner-search: needs: selection if: contains(fromJSON(needs.selection.outputs.jobs), 'planner-search') @@ -1333,7 +1180,7 @@ jobs: # publishes no plan, which fails this gate rather than silently passing. ci: if: always() - needs: [selection, guards, cairn, fmt, clippy, test, ui-snapshots, builder-python, embedded, boot, device, deny, wasm, wasm-bridges, docs, ios-unit, ios-app, ios-release, web, web-browser, desktop-frontend, desktop, verification, planner-search] + needs: [selection, guards, cairn, fmt, clippy, test, ui-snapshots, builder-python, embedded, boot, device, deny, wasm, wasm-bridges, docs, ios-unit, ios-app, ios-release, web, web-browser, verification, planner-search] runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/deploy-site.yml b/.github/workflows/deploy-site.yml index 683eabdf7c..166cdd885d 100644 --- a/.github/workflows/deploy-site.yml +++ b/.github/workflows/deploy-site.yml @@ -156,8 +156,8 @@ jobs: # VITE_SITE_BASE makes the builder's links to the docs and the landing relative: # they are siblings inside this artifact, so naming them by absolute URL would be - # the one place a domain move still bit us. Left unset everywhere else (dev - # server, desktop app), where the site genuinely is somewhere else. + # the one place a domain move still bit us. Left unset everywhere else (the dev + # server), where the site genuinely is somewhere else. - name: Build the static map builder working-directory: builder/web env: diff --git a/.gitignore b/.gitignore index c506aaec5c..e6e80c7fb6 100644 --- a/.gitignore +++ b/.gitignore @@ -71,14 +71,13 @@ builder/web/test-support/flat-device/pkg/ # virtualenv + the optional local maps drop. The tooling itself (everything in # tools/ except obc.local) is committed. tools/obc.local -# Planner tile settings for a local desktop build (see builder/desktop/README.md). +# Local Vite settings of the web builder. builder/web/.env.local .venv/ /maps/ # Web builder frontend: dependencies + the Vite build output (CI builds it). # The dev host builds into builder/server/static/dist/ (what the FastAPI server -# mounts); the static-web and desktop hosts into builder/web/dist// — see -# #895. Both entries must keep matching vite.config.ts's outDirs: when they +# mounts); the static-web host into builder/web/dist/web/. Both entries must keep matching vite.config.ts's outDirs: when they # drifted apart, `npm run build` wrote to an unignored path and 640 KB of bundle # got committed by accident (and the server mounted nothing). builder/web/node_modules/ diff --git a/Cargo.lock b/Cargo.lock index 7ea6b74801..1f1ea6aa1f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4184,7 +4184,6 @@ dependencies = [ "nusb", "obc-flat-device", "obc-link", - "serde", "tokio", ] diff --git a/Cargo.toml b/Cargo.toml index 3d020fce3e..115205023c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -55,13 +55,13 @@ members = [ "sim/phone/host", "sim/desktop", "sim/web-demo", - # Product bridges. obc-desktop carries its own [workspace]. + # Product bridges. "planner/service", "builder/wasm", ] # obc-fw-nrf54l is a standalone board crate (own target + .cargo/config.toml, own empty # [workspace]); it's built on its own, not as part of this host workspace (which builds its -# members for the host target). obc-boot, obc-desktop and obc-sensor-sim carry their own +# members for the host target). obc-boot and obc-sensor-sim carry their own # [workspace] tables, which excludes them automatically for the same reason. exclude = ["firmware/obc-fw-nrf54l"] resolver = "2" diff --git a/builder/__init__.py b/builder/__init__.py index 3f67f2b2d7..51a0a53899 100644 --- a/builder/__init__.py +++ b/builder/__init__.py @@ -1,8 +1,8 @@ """The map builder. -`app/` is the Svelte UI, shared by all three of its hosts — the static web -tier, the Tauri desktop app, and the FastAPI dev server in `server/` (see -`app/vite.config.ts`: one frontend, three hosts). None of them packs anything +`app/` is the Svelte UI, shared by its two hosts — the static web tier and +the FastAPI dev server in `server/` (see `app/vite.config.ts`: one frontend, +two hosts). None of them packs anything itself: they drive the native `obc-pack` packer (`host/obc-pack`) to build OpenStreetMap extracts into `.obcm` maps for the OBC firmware. diff --git a/builder/desktop/.gitignore b/builder/desktop/.gitignore deleted file mode 100644 index f4a858a832..0000000000 --- a/builder/desktop/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -# `tauri-build` regenerates these from tauri.conf.json + capabilities/ on every -# build. They are IDE aids (the `$schema` in capabilities/default.json points at -# one), derived from committed inputs, and platform-specific — so committing them -# would mean a diff every time someone builds on a different OS. -/gen/ diff --git a/builder/desktop/Cargo.lock b/builder/desktop/Cargo.lock deleted file mode 100644 index 6ff8b998aa..0000000000 --- a/builder/desktop/Cargo.lock +++ /dev/null @@ -1,5240 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 4 - -[[package]] -name = "adler2" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa" - -[[package]] -name = "aho-corasick" -version = "1.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddd31a130427c27518df266943a5308ed92d4b226cc639f5a8f1002816174301" -dependencies = [ - "memchr", -] - -[[package]] -name = "alloc-no-stdlib" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" - -[[package]] -name = "alloc-stdlib" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e76a019e91224d279006ff972f1e984179a6e9feb050adba6ce8274aef23195" -dependencies = [ - "alloc-no-stdlib", -] - -[[package]] -name = "android_system_properties" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "819e7219dbd41043ac279b19830f2efc897156490d7fd6ea916720117ee66311" -dependencies = [ - "libc", -] - -[[package]] -name = "anyhow" -version = "1.0.104" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "330a5ed07fa54e4702c9d6c4174f74427fc0ef6e214bbd677ae50a5099946470" - -[[package]] -name = "async-broadcast" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435a87a52755b8f27fcf321ac4f04b2802e337c8c4872923137471ec39c37532" -dependencies = [ - "event-listener", - "event-listener-strategy", - "futures-core", - "pin-project-lite", -] - -[[package]] -name = "async-channel" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "924ed96dd52d1b75e9c1a3e6275715fd320f5f9439fb5a4a11fa51f4221158d2" -dependencies = [ - "concurrent-queue", - "event-listener-strategy", - "futures-core", - "pin-project-lite", -] - -[[package]] -name = "async-executor" -version = "1.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f426a31126c735126297bc5ea7a521263c9faff4f63ca415267ee625651c4f37" -dependencies = [ - "async-task", - "concurrent-queue", - "fastrand", - "futures-lite", - "pin-project-lite", - "slab", -] - -[[package]] -name = "async-io" -version = "2.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "456b8a8feb6f42d237746d4b3e9a178494627745c3c56c6ea55d92ba50d026fc" -dependencies = [ - "autocfg", - "cfg-if", - "concurrent-queue", - "futures-io", - "futures-lite", - "parking", - "polling", - "rustix", - "slab", - "windows-sys 0.61.2", -] - -[[package]] -name = "async-lock" -version = "3.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "290f7f2596bd5b78a9fec8088ccd89180d7f9f55b94b0576823bbbdc72ee8311" -dependencies = [ - "event-listener", - "event-listener-strategy", - "pin-project-lite", -] - -[[package]] -name = "async-process" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc50921ec0055cdd8a16de48773bfeec5c972598674347252c0399676be7da75" -dependencies = [ - "async-channel", - "async-io", - "async-lock", - "async-signal", - "async-task", - "blocking", - "cfg-if", - "event-listener", - "futures-lite", - "rustix", -] - -[[package]] -name = "async-recursion" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b43422f69d8ff38f95f1b2bb76517c91589a924d1559a0e935d7c8ce0274c11" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "async-signal" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52b5aaafa020cf5053a01f2a60e8ff5dccf550f0f77ec54a4e47285ac2bab485" -dependencies = [ - "async-io", - "async-lock", - "atomic-waker", - "cfg-if", - "futures-core", - "futures-io", - "rustix", - "signal-hook-registry", - "slab", - "windows-sys 0.61.2", -] - -[[package]] -name = "async-task" -version = "4.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b75356056920673b02621b35afd0f7dda9306d03c79a30f5c56c44cf256e3de" - -[[package]] -name = "async-trait" -version = "0.1.91" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae36dc4177970ef04fde5178d3e2429882def40e57a451f919c098f72baa6cec" -dependencies = [ - "proc-macro2", - "quote", - "syn 3.0.3", -] - -[[package]] -name = "atk" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "241b621213072e993be4f6f3a9e4b45f65b7e6faad43001be957184b7bb1824b" -dependencies = [ - "atk-sys", - "glib", - "libc", -] - -[[package]] -name = "atk-sys" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c5e48b684b0ca77d2bbadeef17424c2ea3c897d44d566a1617e7e8f30614d086" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "atomic-waker" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" - -[[package]] -name = "autocfg" -version = "1.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53" - -[[package]] -name = "base64" -version = "0.21.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" - -[[package]] -name = "base64" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" - -[[package]] -name = "bit-set" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08807e080ed7f9d5433fa9b275196cfc35414f66a0c79d864dc51a0d825231a3" -dependencies = [ - "bit-vec", -] - -[[package]] -name = "bit-vec" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e764a1d40d510daf35e07be9eb06e75770908c27d411ee6c92109c9840eaaf7" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b588b76d00fde79687d7646a9b5bdf3cc0f655e0bbd080335a95d7e96f3587da" -dependencies = [ - "serde_core", -] - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "block2" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdeb9d870516001442e364c5220d3574d2da8dc765554b4a617230d33fa58ef5" -dependencies = [ - "objc2", -] - -[[package]] -name = "blocking" -version = "1.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e83f8d02be6967315521be875afa792a316e28d57b5a2d401897e2a7921b7f21" -dependencies = [ - "async-channel", - "async-task", - "futures-io", - "futures-lite", - "piper", -] - -[[package]] -name = "brotli" -version = "8.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cc91aac060a7a1e25823bdccbfb6af1875b88f17c6daac97894eed8207166b3" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", - "brotli-decompressor", -] - -[[package]] -name = "brotli-decompressor" -version = "5.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a32acac15fe1967bc3986b2a6347dffc965602354ea6f450ad07e8bfd253583" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", -] - -[[package]] -name = "bs58" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf88ba1141d185c399bee5288d850d63b8369520c1eafc32a0430b5b6c287bf4" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "bumpalo" -version = "3.20.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72f5acc6cb2ba439de613abc23857ec3d78374d8ed5ac84e9d11336e87da8649" - -[[package]] -name = "bytemuck" -version = "1.25.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95832e849adfb21180ccb6826a99da14e5d266ae5c2e668e1602cf234f153797" - -[[package]] -name = "byteorder" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" - -[[package]] -name = "bytes" -version = "1.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc652a48c352aef3ea3aed32080501cf3ef6ed5da78602a020c991775b0aff04" -dependencies = [ - "serde", -] - -[[package]] -name = "cairo-rs" -version = "0.18.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ca26ef0159422fb77631dc9d17b102f253b876fe1586b03b803e63a309b4ee2" -dependencies = [ - "bitflags 2.13.1", - "cairo-sys-rs", - "glib", - "libc", - "once_cell", - "thiserror 1.0.69", -] - -[[package]] -name = "cairo-sys-rs" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "685c9fa8e590b8b3d678873528d83411db17242a73fccaed827770ea0fedda51" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "camino" -version = "1.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f2d30e4173c4026932d51d31d6b0613b1fd3014bf3f9f8943d4ba139c437ba0" -dependencies = [ - "serde_core", -] - -[[package]] -name = "cargo-platform" -version = "0.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e35af189006b9c0f00a064685c727031e3ed2d8020f7ba284d78cc2671bd36ea" -dependencies = [ - "serde", -] - -[[package]] -name = "cargo_metadata" -version = "0.19.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd5eb614ed4c27c5d706420e4320fbe3216ab31fa1c33cd8246ac36dae4479ba" -dependencies = [ - "camino", - "cargo-platform", - "semver", - "serde", - "serde_json", - "thiserror 2.0.19", -] - -[[package]] -name = "cargo_toml" -version = "0.22.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "374b7c592d9c00c1f4972ea58390ac6b18cbb6ab79011f3bdc90a0b82ca06b77" -dependencies = [ - "serde", - "toml 0.9.12+spec-1.1.0", -] - -[[package]] -name = "cc" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5add81bb678e6cb321aff7fa0dc7689ad82b112dbc032cea19f91d6b8e3582b9" -dependencies = [ - "find-msvc-tools", - "shlex", -] - -[[package]] -name = "cesu8" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" - -[[package]] -name = "cfb" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d38f2da7a0a2c4ccf0065be06397cc26a81f4e528be095826eee9d4adbb8c60f" -dependencies = [ - "byteorder", - "fnv", - "uuid", -] - -[[package]] -name = "cfg-expr" -version = "0.15.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d067ad48b8650848b989a59a86c6c36a995d02d2bf778d45c3c5d57bc2718f02" -dependencies = [ - "smallvec", - "target-lexicon", -] - -[[package]] -name = "cfg-if" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9330f8b2ff13f34540b44e946ef35111825727b38d33286ef986142615121801" - -[[package]] -name = "chrono" -version = "0.4.45" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1aa79e62e7697b8e29b513a68abacf485adcd1fe8284a4316c5ae868e6633327" -dependencies = [ - "iana-time-zone", - "num-traits", - "serde", - "windows-link 0.2.1", -] - -[[package]] -name = "combine" -version = "4.6.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba5a308b75df32fe02788e748662718f03fde005016435c444eea572398219fd" -dependencies = [ - "bytes", - "memchr", -] - -[[package]] -name = "concurrent-queue" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ca0197aee26d1ae37445ee532fefce43251d24cc7c166799f4d46817f1d3973" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "cookie" -version = "0.18.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ddef33a339a91ea89fb53151bd0a4689cfce27055c291dfa69945475d22c747" -dependencies = [ - "time", - "version_check", -] - -[[package]] -name = "core-foundation" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2a6cd9ae233e7f62ba4e9353e81a88df7fc8a5987b8d445b4d90c879bd156f6" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b" - -[[package]] -name = "core-graphics" -version = "0.25.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "064badf302c3194842cf2c5d61f56cc88e54a759313879cdf03abdd27d0c3b97" -dependencies = [ - "bitflags 2.13.1", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", -] - -[[package]] -name = "core-graphics-types" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d44a101f213f6c4cdc1853d4b78aef6db6bdfa3468798cc1d9912f4735013eb" -dependencies = [ - "bitflags 2.13.1", - "core-foundation", - "libc", -] - -[[package]] -name = "cpufeatures" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9481c1c90cbf2ac953f07c8d4a58aa3945c425b7185c9154d67a65e4230da511" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-channel" -version = "0.5.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d85363c37faeca707aef026efa9f3b34d077bce547e48f770770625c6013679e" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61803da095bee82a81bb1a452ecc25d3b2f1416d1897eb86430c6159ef717c17" - -[[package]] -name = "crypto-common" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78c8292055d1c1df0cce5d180393dc8cce0abec0a7102adb6c7b1eef6016d60a" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "cssparser" -version = "0.36.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dae61cf9c0abb83bd659dab65b7e4e38d8236824c85f0f804f173567bda257d2" -dependencies = [ - "cssparser-macros", - "dtoa-short", - "itoa", - "phf", - "smallvec", -] - -[[package]] -name = "cssparser-macros" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13b588ba4ac1a99f7f2964d24b3d896ddc6bf847ee3855dbd4366f058cfcd331" -dependencies = [ - "quote", - "syn 2.0.119", -] - -[[package]] -name = "ctor" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "352d39c2f7bef1d6ad73db6f5160efcaed66d94ef8c6c573a8410c00bf909a98" -dependencies = [ - "ctor-proc-macro", - "dtor", -] - -[[package]] -name = "ctor-proc-macro" -version = "0.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52560adf09603e58c9a7ee1fe1dcb95a16927b17c127f0ac02d6e768a0e25bc1" - -[[package]] -name = "darling" -version = "0.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25ae13da2f202d56bd7f91c25fba009e7717a1e4a1cc98a76d844b65ae912e9d" -dependencies = [ - "darling_core", - "darling_macro", -] - -[[package]] -name = "darling_core" -version = "0.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9865a50f7c335f53564bb694ef660825eb8610e0a53d3e11bf1b0d3df31e03b0" -dependencies = [ - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn 2.0.119", -] - -[[package]] -name = "darling_macro" -version = "0.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3984ec7bd6cfa798e62b4a642426a5be0e68f9401cfc2a01e3fa9ea2fcdb8d" -dependencies = [ - "darling_core", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "dbus" -version = "0.9.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab69f03cc8c4340c9c8e315114e1658e6775a9b16a04357973aa21cec22b32e" -dependencies = [ - "libc", - "libdbus-sys", - "windows-sys 0.61.2", -] - -[[package]] -name = "deranged" -version = "0.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7cd812cc2bc1d69d4764bd80df88b4317eaef9e773c75226407d9bc0876b211c" -dependencies = [ - "serde_core", -] - -[[package]] -name = "derive_more" -version = "2.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d751e9e49156b02b44f9c1815bcb94b984cdcc4396ecc32521c739452808b134" -dependencies = [ - "derive_more-impl", -] - -[[package]] -name = "derive_more-impl" -version = "2.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "799a97264921d8623a957f6c3b9011f3b5492f557bbb7a5a19b7fa6d06ba8dcb" -dependencies = [ - "proc-macro2", - "quote", - "rustc_version", - "syn 2.0.119", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer", - "crypto-common", -] - -[[package]] -name = "dirs" -version = "6.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3e8aa94d75141228480295a7d0e7feb620b1a5ad9f12bc40be62411e38cce4e" -dependencies = [ - "dirs-sys", -] - -[[package]] -name = "dirs-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e01a3366d27ee9890022452ee61b2b63a67e6f13f58900b651ff5665f0bb1fab" -dependencies = [ - "libc", - "option-ext", - "redox_users", - "windows-sys 0.59.0", -] - -[[package]] -name = "dispatch2" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e0e367e4e7da84520dedcac1901e4da967309406d1e51017ae1abfb97adbd38" -dependencies = [ - "bitflags 2.13.1", - "block2", - "libc", - "objc2", -] - -[[package]] -name = "displaydoc" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ac70aa55017e108007fbaf5aa0f54b021c98f92ff8af59d42eda9da96e3dd4f" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "dlopen2" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e2c5bd4158e66d1e215c49b837e11d62f3267b30c92f1d171c4d3105e3dc4d4" -dependencies = [ - "dlopen2_derive", - "libc", - "once_cell", - "winapi", -] - -[[package]] -name = "dlopen2_derive" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fbbb781877580993a8707ec48672673ec7b81eeba04cfd2310bd28c08e47c8f" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "dom_query" -version = "0.27.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "521e380c0c8afb8d9a1e83a1822ee03556fc3e3e7dbc1fd30be14e37f9cb3f89" -dependencies = [ - "bit-set", - "cssparser", - "foldhash", - "html5ever", - "precomputed-hash", - "selectors", - "tendril", -] - -[[package]] -name = "dpi" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8b14ccef22fc6f5a8f4d7d768562a182c04ce9a3b3157b91390b52ddfdf1a76" -dependencies = [ - "serde", -] - -[[package]] -name = "dtoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c3cf4824e2d5f025c7b531afcb2325364084a16806f6d47fbc1f5fbd9960590" - -[[package]] -name = "dtoa-short" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd1511a7b6a56299bd043a9c167a6d2bfb37bf84a6dfceaba651168adfb43c87" -dependencies = [ - "dtoa", -] - -[[package]] -name = "dtor" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1057d6c64987086ff8ed0fd3fbf377a6b7d205cc7715868cd401705f715cbe4" -dependencies = [ - "dtor-proc-macro", -] - -[[package]] -name = "dtor-proc-macro" -version = "0.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f678cf4a922c215c63e0de95eb1ff08a958a81d47e485cf9da1e27bf6305cfa5" - -[[package]] -name = "dunce" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813" - -[[package]] -name = "dyn-clone" -version = "1.0.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0881ea181b1df73ff77ffaaf9c7544ecc11e82fba9b5f27b262a3c73a332555" - -[[package]] -name = "embed-resource" -version = "3.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbfdaacccebec3b28e4866b8973543c7647797db5ada1bdab552e48fe665fbbd" -dependencies = [ - "cc", - "memchr", - "rustc_version", - "toml 1.1.3+spec-1.1.0", - "vswhom", - "winreg", -] - -[[package]] -name = "embed_plist" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ef6b89e5b37196644d8796de5268852ff179b44e96276cf4290264843743bb7" - -[[package]] -name = "endi" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66b7e2430c6dff6a955451e2cfc438f09cea1965a9d6f87f7e3b90decc014099" - -[[package]] -name = "enumflags2" -version = "0.7.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1027f7680c853e056ebcec683615fb6fbbc07dbaa13b4d5d9442b146ded4ecef" -dependencies = [ - "enumflags2_derive", - "serde", -] - -[[package]] -name = "enumflags2_derive" -version = "0.7.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67c78a4d8fdf9953a5c9d458f9efe940fd97a0cab0941c075a813ac594733827" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "equivalent" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" - -[[package]] -name = "erased-serde" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2add8a07dd6a8d93ff627029c51de145e12686fbc36ecb298ac22e74cf02dec" -dependencies = [ - "serde", - "serde_core", - "typeid", -] - -[[package]] -name = "errno" -version = "0.3.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "event-listener" -version = "5.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e13b66accf52311f30a0db42147dadea9850cb48cd070028831ae5f5d4b856ab" -dependencies = [ - "concurrent-queue", - "parking", - "pin-project-lite", -] - -[[package]] -name = "event-listener-strategy" -version = "0.5.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8be9f3dfaaffdae2972880079a491a1a8bb7cbed0b8dd7a347f668b4150a3b93" -dependencies = [ - "event-listener", - "pin-project-lite", -] - -[[package]] -name = "fastrand" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da7c62ceae207dd37ea5b845da6a0696c799f85e97da1ab5b7910be3c1c80223" - -[[package]] -name = "fdeflate" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e6853b52649d4ac5c0bd02320cddc5ba956bdb407c4b75a2c6b75bf51500f8c" -dependencies = [ - "simd-adler32", -] - -[[package]] -name = "field-offset" -version = "0.3.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38e2275cc4e4fc009b0669731a1e5ab7ebf11f469eaede2bab9309a5b4d6057f" -dependencies = [ - "memoffset", - "rustc_version", -] - -[[package]] -name = "find-msvc-tools" -version = "0.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5baebc0774151f905a1a2cc41989300b1e6fbb29aff0ceffa1064fdd3088d582" - -[[package]] -name = "flate2" -version = "1.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "843fba2746e448b37e26a819579957415c8cef339bf08564fe8b7ddbd959573c" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foldhash" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb" - -[[package]] -name = "foreign-types" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d737d9aa519fb7b749cbc3b962edcf310a8dd1f4b67c91c4f83975dbdd17d965" -dependencies = [ - "foreign-types-macros", - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-macros" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea5190182e6915eb873ddbc16e23b711b6eb1f9c00a0d0a3a91b5f6228475225" -dependencies = [ - "proc-macro2", - "quote", - "syn 3.0.3", -] - -[[package]] -name = "foreign-types-shared" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b" - -[[package]] -name = "form_urlencoded" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb4cb245038516f5f85277875cdaa4f7d2c9a0fa0468de06ed190163b1581fcf" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futures-channel" -version = "0.3.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "262590f4fe6afeb0bc83be1daa64e52657fe185690a958af7f3ad0e92085c5ae" -dependencies = [ - "futures-core", -] - -[[package]] -name = "futures-core" -version = "0.3.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2cd50c473c80f6d7c3670a752354b8e569b1a7cbfdc0419ec88e5edad85e0dc7" - -[[package]] -name = "futures-executor" -version = "0.3.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6754879cc9f2c66f88c6e5c35344bb0bdb0708b0352b1201815667c7eabc7458" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-io" -version = "0.3.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4577ecaa3c4f96589d473f679a71b596316f6641bc350038b962a5daf0085d7a" - -[[package]] -name = "futures-lite" -version = "2.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f78e10609fe0e0b3f4157ffab1876319b5b0db102a2c60dc4626306dc46b44ad" -dependencies = [ - "fastrand", - "futures-core", - "futures-io", - "parking", - "pin-project-lite", -] - -[[package]] -name = "futures-macro" -version = "0.3.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d6d3cde68c518367be28956066ddfef33813991b77a55005a69dae04bf3b10b" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "futures-sink" -version = "0.3.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e34418ac499d6305c2fb5ad0ed2f6ac998c5f8ca209b4510f7f94242c647e307" - -[[package]] -name = "futures-task" -version = "0.3.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b231ed28831efb4a61a08580c4bc233ec56bc009f4cd8f52da2c3cb97df0c109" - -[[package]] -name = "futures-util" -version = "0.3.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a77a90a256fce34da66415271e30f94ee91c57b04b8a2c042d9cf3220179deaa" -dependencies = [ - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "slab", -] - -[[package]] -name = "gdk" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9f245958c627ac99d8e529166f9823fb3b838d1d41fd2b297af3075093c2691" -dependencies = [ - "cairo-rs", - "gdk-pixbuf", - "gdk-sys", - "gio", - "glib", - "libc", - "pango", -] - -[[package]] -name = "gdk-pixbuf" -version = "0.18.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50e1f5f1b0bfb830d6ccc8066d18db35c487b1b2b1e8589b5dfe9f07e8defaec" -dependencies = [ - "gdk-pixbuf-sys", - "gio", - "glib", - "libc", - "once_cell", -] - -[[package]] -name = "gdk-pixbuf-sys" -version = "0.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9839ea644ed9c97a34d129ad56d38a25e6756f99f3a88e15cd39c20629caf7" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gdk-sys" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c2d13f38594ac1e66619e188c6d5a1adb98d11b2fcf7894fc416ad76aa2f3f7" -dependencies = [ - "cairo-sys-rs", - "gdk-pixbuf-sys", - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "pango-sys", - "pkg-config", - "system-deps", -] - -[[package]] -name = "gdkwayland-sys" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "140071d506d223f7572b9f09b5e155afbd77428cd5cc7af8f2694c41d98dfe69" -dependencies = [ - "gdk-sys", - "glib-sys", - "gobject-sys", - "libc", - "pkg-config", - "system-deps", -] - -[[package]] -name = "gdkx11" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3caa00e14351bebbc8183b3c36690327eb77c49abc2268dd4bd36b856db3fbfe" -dependencies = [ - "gdk", - "gdkx11-sys", - "gio", - "glib", - "libc", - "x11", -] - -[[package]] -name = "gdkx11-sys" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e2e7445fe01ac26f11601db260dd8608fe172514eb63b3b5e261ea6b0f4428d" -dependencies = [ - "gdk-sys", - "glib-sys", - "libc", - "system-deps", - "x11", -] - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "getrandom" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff2abc00be7fca6ebc474524697ae276ad847ad0a6b3faa4bcb027e9a4614ad0" -dependencies = [ - "cfg-if", - "libc", - "wasi", -] - -[[package]] -name = "getrandom" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd" -dependencies = [ - "cfg-if", - "libc", - "r-efi 5.3.0", - "wasip2", -] - -[[package]] -name = "getrandom" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "300e883d756b2e4ec94e02791f39b04b522276138852cfc41d9fb7e904106099" -dependencies = [ - "cfg-if", - "libc", - "r-efi 6.0.0", -] - -[[package]] -name = "gio" -version = "0.18.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4fc8f532f87b79cbc51a79748f16a6828fb784be93145a322fa14d06d354c73" -dependencies = [ - "futures-channel", - "futures-core", - "futures-io", - "futures-util", - "gio-sys", - "glib", - "libc", - "once_cell", - "pin-project-lite", - "smallvec", - "thiserror 1.0.69", -] - -[[package]] -name = "gio-sys" -version = "0.18.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37566df850baf5e4cb0dfb78af2e4b9898d817ed9263d1090a2df958c64737d2" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", - "winapi", -] - -[[package]] -name = "glib" -version = "0.18.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "233daaf6e83ae6a12a52055f568f9d7cf4671dabb78ff9560ab6da230ce00ee5" -dependencies = [ - "bitflags 2.13.1", - "futures-channel", - "futures-core", - "futures-executor", - "futures-task", - "futures-util", - "gio-sys", - "glib-macros", - "glib-sys", - "gobject-sys", - "libc", - "memchr", - "once_cell", - "smallvec", - "thiserror 1.0.69", -] - -[[package]] -name = "glib-macros" -version = "0.18.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bb0228f477c0900c880fd78c8759b95c7636dbd7842707f49e132378aa2acdc" -dependencies = [ - "heck 0.4.1", - "proc-macro-crate 2.0.2", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "glib-sys" -version = "0.18.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "063ce2eb6a8d0ea93d2bf8ba1957e78dbab6be1c2220dd3daca57d5a9d869898" -dependencies = [ - "libc", - "system-deps", -] - -[[package]] -name = "glob" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4eba85ea1d0a966a983acd07deee566e67395d2d96b6fb39e62b5a833f1eb0b" - -[[package]] -name = "gobject-sys" -version = "0.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0850127b514d1c4a4654ead6dedadb18198999985908e6ffe4436f53c785ce44" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gtk" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd56fb197bfc42bd5d2751f4f017d44ff59fbb58140c6b49f9b3b2bdab08506a" -dependencies = [ - "atk", - "cairo-rs", - "field-offset", - "futures-channel", - "gdk", - "gdk-pixbuf", - "gio", - "glib", - "gtk-sys", - "gtk3-macros", - "libc", - "pango", - "pkg-config", -] - -[[package]] -name = "gtk-sys" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f29a1c21c59553eb7dd40e918be54dccd60c52b049b75119d5d96ce6b624414" -dependencies = [ - "atk-sys", - "cairo-sys-rs", - "gdk-pixbuf-sys", - "gdk-sys", - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "pango-sys", - "system-deps", -] - -[[package]] -name = "gtk3-macros" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52ff3c5b21f14f0736fed6dcfc0bfb4225ebf5725f3c0209edeec181e4d73e9d" -dependencies = [ - "proc-macro-crate 1.3.1", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" - -[[package]] -name = "hashbrown" -version = "0.17.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a" - -[[package]] -name = "heck" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" - -[[package]] -name = "heck" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" - -[[package]] -name = "hermit-abi" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc0fef456e4baa96da950455cd02c081ca953b141298e41db3fc7e36b1da849c" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "html5ever" -version = "0.38.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1054432bae2f14e0061e33d23402fbaa67a921d319d56adc6bcf887ddad1cbc2" -dependencies = [ - "log", - "markup5ever", -] - -[[package]] -name = "http" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6970f50e31d6fc17d3fa27329444bfa74e196cf62e95052a3f6fee181dba6425" -dependencies = [ - "bytes", - "itoa", -] - -[[package]] -name = "http-body" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca2a8f2913ee65f60facd6a5905613afaa448497a0230cc41ce022d93290bc2c" -dependencies = [ - "bytes", - "http", -] - -[[package]] -name = "http-body-util" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9f41fd6a08e4d4ec69df65976da761afd5ad5e58a9d4acb46bd1c953a9e3ff2" -dependencies = [ - "bytes", - "futures-core", - "http", - "http-body", - "pin-project-lite", -] - -[[package]] -name = "httparse" -version = "1.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87" - -[[package]] -name = "hyper" -version = "1.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d22053281f852e11534f5198498373cbb59295120a20771d90f7ed1897490a72" -dependencies = [ - "atomic-waker", - "bytes", - "futures-channel", - "futures-core", - "http", - "http-body", - "httparse", - "itoa", - "pin-project-lite", - "smallvec", - "tokio", - "want", -] - -[[package]] -name = "hyper-util" -version = "0.1.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96547c2556ec9d12fb1578c4eaf448b04993e7fb79cbaad930a656880a6bdfa0" -dependencies = [ - "base64 0.22.1", - "bytes", - "futures-channel", - "futures-util", - "http", - "http-body", - "hyper", - "ipnet", - "libc", - "percent-encoding", - "pin-project-lite", - "socket2", - "tokio", - "tower-service", - "tracing", -] - -[[package]] -name = "iana-time-zone" -version = "0.1.65" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e31bc9ad994ba00e440a8aa5c9ef0ec67d5cb5e5cb0cc7f8b744a35b389cc470" -dependencies = [ - "android_system_properties", - "core-foundation-sys", - "iana-time-zone-haiku", - "js-sys", - "log", - "wasm-bindgen", - "windows-core 0.62.2", -] - -[[package]] -name = "iana-time-zone-haiku" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" -dependencies = [ - "cc", -] - -[[package]] -name = "ico" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e795dff5605e0f04bff85ca41b51a96b83e80b281e96231bcaaf1ac35103371" -dependencies = [ - "byteorder", - "png 0.17.16", -] - -[[package]] -name = "icu_collections" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2984d1cd16c883d7935b9e07e44071dca8d917fd52ecc02c04d5fa0b5a3f191c" -dependencies = [ - "displaydoc", - "potential_utf", - "utf8_iter", - "yoke", - "zerofrom", - "zerovec", -] - -[[package]] -name = "icu_locale_core" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92219b62b3e2b4d88ac5119f8904c10f8f61bf7e95b640d25ba3075e6cac2c29" -dependencies = [ - "displaydoc", - "litemap", - "tinystr", - "writeable", - "zerovec", -] - -[[package]] -name = "icu_normalizer" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c56e5ee99d6e3d33bd91c5d85458b6005a22140021cc324cea84dd0e72cff3b4" -dependencies = [ - "icu_collections", - "icu_normalizer_data", - "icu_properties", - "icu_provider", - "smallvec", - "zerovec", -] - -[[package]] -name = "icu_normalizer_data" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da3be0ae77ea334f4da67c12f149704f19f81d1adf7c51cf482943e84a2bad38" - -[[package]] -name = "icu_properties" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bee3b67d0ea5c2cca5003417989af8996f8604e34fb9ddf96208a033901e70de" -dependencies = [ - "icu_collections", - "icu_locale_core", - "icu_properties_data", - "icu_provider", - "zerotrie", - "zerovec", -] - -[[package]] -name = "icu_properties_data" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e2bbb201e0c04f7b4b3e14382af113e17ba4f63e2c9d2ee626b720cbce54a14" - -[[package]] -name = "icu_provider" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "139c4cf31c8b5f33d7e199446eff9c1e02decfc2f0eec2c8d71f65befa45b421" -dependencies = [ - "displaydoc", - "icu_locale_core", - "writeable", - "yoke", - "zerofrom", - "zerotrie", - "zerovec", -] - -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - -[[package]] -name = "idna" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b0875f23caa03898994f6ddc501886a45c7d3d62d04d2d90788d47be1b1e4de" -dependencies = [ - "idna_adapter", - "smallvec", - "utf8_iter", -] - -[[package]] -name = "idna_adapter" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb68373c0d6620ef8105e855e7745e18b0d00d3bdb07fb532e434244cdb9a714" -dependencies = [ - "icu_normalizer", - "icu_properties", -] - -[[package]] -name = "indexmap" -version = "1.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" -dependencies = [ - "autocfg", - "hashbrown 0.12.3", - "serde", -] - -[[package]] -name = "indexmap" -version = "2.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d466e9454f08e4a911e14806c24e16fba1b4c121d1ea474396f396069cf949d9" -dependencies = [ - "equivalent", - "hashbrown 0.17.1", - "serde", - "serde_core", -] - -[[package]] -name = "infer" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a588916bfdfd92e71cacef98a63d9b1f0d74d6599980d11894290e7ddefffcf7" -dependencies = [ - "cfb", -] - -[[package]] -name = "io-kit-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06d3a048d09fbb6597dbf7c69f40d14df4a49487db1487191618c893fc3b1c26" -dependencies = [ - "core-foundation-sys", - "mach2", -] - -[[package]] -name = "ipnet" -version = "2.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d98f6fed1fde3f8c21bc40a1abb88dd75e67924f9cffc3ef95607bad8017f8e2" - -[[package]] -name = "is-docker" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "928bae27f42bc99b60d9ac7334e3a21d10ad8f1835a4e12ec3ec0464765ed1b3" -dependencies = [ - "once_cell", -] - -[[package]] -name = "is-wsl" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "173609498df190136aa7dea1a91db051746d339e18476eed5ca40521f02d7aa5" -dependencies = [ - "is-docker", - "once_cell", -] - -[[package]] -name = "itoa" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682" - -[[package]] -name = "javascriptcore-rs" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca5671e9ffce8ffba57afc24070e906da7fc4b1ba66f2cabebf61bf2ea257fcc" -dependencies = [ - "bitflags 1.3.2", - "glib", - "javascriptcore-rs-sys", -] - -[[package]] -name = "javascriptcore-rs-sys" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af1be78d14ffa4b75b66df31840478fef72b51f8c2465d4ca7c194da9f7a5124" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "jni" -version = "0.21.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a87aa2bb7d2af34197c04845522473242e1aa17c12f4935d5856491a7fb8c97" -dependencies = [ - "cesu8", - "cfg-if", - "combine", - "jni-sys 0.3.1", - "log", - "thiserror 1.0.69", - "walkdir", - "windows-sys 0.45.0", -] - -[[package]] -name = "jni-sys" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41a652e1f9b6e0275df1f15b32661cf0d4b78d4d87ddec5e0c3c20f097433258" -dependencies = [ - "jni-sys 0.4.1", -] - -[[package]] -name = "jni-sys" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6377a88cb3910bee9b0fa88d4f42e1d2da8e79915598f65fb0c7ee14c878af2" -dependencies = [ - "jni-sys-macros", -] - -[[package]] -name = "jni-sys-macros" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38c0b942f458fe50cdac086d2f946512305e5631e720728f2a61aabcd47a6264" -dependencies = [ - "quote", - "syn 2.0.119", -] - -[[package]] -name = "js-sys" -version = "0.3.103" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53b44bfcdb3f8d5837a46dae1ca9660a837176eee74a28b229bc626816589102" -dependencies = [ - "cfg-if", - "futures-util", - "wasm-bindgen", -] - -[[package]] -name = "json-patch" -version = "3.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "863726d7afb6bc2590eeff7135d923545e5e964f004c2ccf8716c25e70a86f08" -dependencies = [ - "jsonptr", - "serde", - "serde_json", - "thiserror 1.0.69", -] - -[[package]] -name = "jsonptr" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dea2b27dd239b2556ed7a25ba842fe47fd602e7fc7433c2a8d6106d4d9edd70" -dependencies = [ - "serde", - "serde_json", -] - -[[package]] -name = "keyboard-types" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b750dcadc39a09dbadd74e118f6dd6598df77fa01df0cfcdc52c28dece74528a" -dependencies = [ - "bitflags 2.13.1", - "serde", - "unicode-segmentation", -] - -[[package]] -name = "libappindicator" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03589b9607c868cc7ae54c0b2a22c8dc03dd41692d48f2d7df73615c6a95dc0a" -dependencies = [ - "glib", - "gtk", - "gtk-sys", - "libappindicator-sys", - "log", -] - -[[package]] -name = "libappindicator-sys" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e9ec52138abedcc58dc17a7c6c0c00a2bdb4f3427c7f63fa97fd0d859155caf" -dependencies = [ - "gtk-sys", - "libloading", - "once_cell", -] - -[[package]] -name = "libc" -version = "0.2.189" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3eaf3ede3fee6db1a4c2ee091bf8a8b4dccdc6d17f656fb07896ee72867612f2" - -[[package]] -name = "libdbus-sys" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "328c4789d42200f1eeec05bd86c9c13c7f091d2ba9a6ea35acdf51f31bc0f043" -dependencies = [ - "pkg-config", -] - -[[package]] -name = "libloading" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b67380fd3b2fbe7527a606e18729d21c6f3951633d0500574c4dc22d2d638b9f" -dependencies = [ - "cfg-if", - "winapi", -] - -[[package]] -name = "libredox" -version = "0.1.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c943259e342f1e06ff2da7a83eabdfe7f92ce10262688dbf1895ff0b3e6e4652" -dependencies = [ - "libc", -] - -[[package]] -name = "linux-raw-sys" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32a66949e030da00e8c7d4434b251670a91556f4144941d37452769c25d58a53" - -[[package]] -name = "litemap" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92daf443525c4cce67b150400bc2316076100ce0b3686209eb8cf3c31612e6f0" - -[[package]] -name = "lock_api" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "224399e74b87b5f3557511d98dff8b14089b3dadafcab6bb93eab67d3aace965" -dependencies = [ - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ceec5bc11778974d1bcb055b18002eba7f4b3518b6a0081b3af5f21666da9ad" - -[[package]] -name = "mach2" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a1b95cd5421ec55b445b5ae102f5ea0e768de1f82bd3001e11f426c269c3aea" -dependencies = [ - "libc", -] - -[[package]] -name = "markup5ever" -version = "0.38.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8983d30f2915feeaaab2d6babdd6bc7e9ed1a00b66b5e6d74df19aa9c0e91862" -dependencies = [ - "log", - "tendril", - "web_atoms", -] - -[[package]] -name = "memchr" -version = "2.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98" - -[[package]] -name = "memoffset" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a" -dependencies = [ - "autocfg", -] - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "miniz_oxide" -version = "0.8.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fa76a2c86f704bdb222d66965fb3d63269ce38518b83cb0575fca855ebb6316" -dependencies = [ - "adler2", - "simd-adler32", -] - -[[package]] -name = "mio" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30d65c71f1ce40ab09135ce117d742b9f8a19ff91a41a8b57ed50bc2de59c427" -dependencies = [ - "libc", - "wasi", - "windows-sys 0.61.2", -] - -[[package]] -name = "muda" -version = "0.19.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd04e60bc0b07438a6771710ee1698f98f6ebbc7f89b61264af1563b8aeb878" -dependencies = [ - "crossbeam-channel", - "dpi", - "gtk", - "keyboard-types", - "objc2", - "objc2-app-kit", - "objc2-core-foundation", - "objc2-foundation", - "once_cell", - "png 0.18.1", - "serde", - "thiserror 2.0.19", - "windows-sys 0.60.2", -] - -[[package]] -name = "ndk" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3f42e7bbe13d351b6bead8286a43aac9534b82bd3cc43e47037f012ebfd62d4" -dependencies = [ - "bitflags 2.13.1", - "jni-sys 0.3.1", - "log", - "ndk-sys", - "num_enum", - "raw-window-handle", - "thiserror 1.0.69", -] - -[[package]] -name = "ndk-sys" -version = "0.6.0+11769913" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee6cda3051665f1fb8d9e08fc35c96d5a244fb1be711a03b71118828afc9a873" -dependencies = [ - "jni-sys 0.3.1", -] - -[[package]] -name = "new_debug_unreachable" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "650eef8c711430f1a879fdd01d4745a7deea475becfb90269c06775983bbf086" - -[[package]] -name = "num-conv" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "521739c6d2bac4aa25192232afe6841231376b2b26d4d9fae5ecf8ca5772e441" - -[[package]] -name = "num-traits" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_enum" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d0bca838442ec211fa11de3a8b0e0e8f3a4522575b5c4c06ed722e005036f26" -dependencies = [ - "num_enum_derive", - "rustversion", -] - -[[package]] -name = "num_enum_derive" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "680998035259dcfcafe653688bf2aa6d3e2dc05e98be6ab46afb089dc84f1df8" -dependencies = [ - "proc-macro-crate 3.5.0", - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "nusb" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1553b6f47685e4c658b2100a6d7262abdc73cb97f423453546ca020155ae9" -dependencies = [ - "core-foundation", - "core-foundation-sys", - "futures-core", - "io-kit-sys", - "linux-raw-sys", - "log", - "once_cell", - "rustix", - "slab", - "tokio", - "windows-sys 0.60.2", -] - -[[package]] -name = "obc-crc" -version = "0.1.0" - -[[package]] -name = "obc-desktop" -version = "0.1.0" -dependencies = [ - "futures-core", - "nusb", - "obc-usb", - "serde", - "serde_json", - "tauri", - "tauri-build", - "tauri-plugin-dialog", - "tauri-plugin-opener", - "tokio", - "ureq", - "url", -] - -[[package]] -name = "obc-link" -version = "0.1.0" -dependencies = [ - "obc-crc", -] - -[[package]] -name = "obc-usb" -version = "0.1.0" -dependencies = [ - "getrandom 0.4.3", - "nusb", - "obc-link", - "serde", - "tokio", -] - -[[package]] -name = "objc2" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a12a8ed07aefc768292f076dc3ac8c48f3781c8f2d5851dd3d98950e8c5a89f" -dependencies = [ - "objc2-encode", - "objc2-exception-helper", -] - -[[package]] -name = "objc2-app-kit" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d49e936b501e5c5bf01fda3a9452ff86dc3ea98ad5f283e1455153142d97518c" -dependencies = [ - "bitflags 2.13.1", - "block2", - "objc2", - "objc2-core-foundation", - "objc2-foundation", -] - -[[package]] -name = "objc2-cloud-kit" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73ad74d880bb43877038da939b7427bba67e9dd42004a18b809ba7d87cee241c" -dependencies = [ - "bitflags 2.13.1", - "objc2", - "objc2-foundation", -] - -[[package]] -name = "objc2-core-data" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b402a653efbb5e82ce4df10683b6b28027616a2715e90009947d50b8dd298fa" -dependencies = [ - "objc2", - "objc2-foundation", -] - -[[package]] -name = "objc2-core-foundation" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a180dd8642fa45cdb7dd721cd4c11b1cadd4929ce112ebd8b9f5803cc79d536" -dependencies = [ - "bitflags 2.13.1", - "dispatch2", - "objc2", -] - -[[package]] -name = "objc2-core-graphics" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e022c9d066895efa1345f8e33e584b9f958da2fd4cd116792e15e07e4720a807" -dependencies = [ - "bitflags 2.13.1", - "dispatch2", - "objc2", - "objc2-core-foundation", - "objc2-io-surface", -] - -[[package]] -name = "objc2-core-image" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5d563b38d2b97209f8e861173de434bd0214cf020e3423a52624cd1d989f006" -dependencies = [ - "objc2", - "objc2-foundation", -] - -[[package]] -name = "objc2-core-location" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca347214e24bc973fc025fd0d36ebb179ff30536ed1f80252706db19ee452009" -dependencies = [ - "objc2", - "objc2-foundation", -] - -[[package]] -name = "objc2-core-text" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0cde0dfb48d25d2b4862161a4d5fcc0e3c24367869ad306b0c9ec0073bfed92d" -dependencies = [ - "bitflags 2.13.1", - "objc2", - "objc2-core-foundation", - "objc2-core-graphics", -] - -[[package]] -name = "objc2-encode" -version = "4.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef25abbcd74fb2609453eb695bd2f860d389e457f67dc17cafc8b8cbc89d0c33" - -[[package]] -name = "objc2-exception-helper" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7a1c5fbb72d7735b076bb47b578523aedc40f3c439bea6dfd595c089d79d98a" -dependencies = [ - "cc", -] - -[[package]] -name = "objc2-foundation" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3e0adef53c21f888deb4fa59fc59f7eb17404926ee8a6f59f5df0fd7f9f3272" -dependencies = [ - "bitflags 2.13.1", - "block2", - "libc", - "objc2", - "objc2-core-foundation", -] - -[[package]] -name = "objc2-io-surface" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "180788110936d59bab6bd83b6060ffdfffb3b922ba1396b312ae795e1de9d81d" -dependencies = [ - "bitflags 2.13.1", - "objc2", - "objc2-core-foundation", -] - -[[package]] -name = "objc2-quartz-core" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96c1358452b371bf9f104e21ec536d37a650eb10f7ee379fff67d2e08d537f1f" -dependencies = [ - "bitflags 2.13.1", - "objc2", - "objc2-core-foundation", - "objc2-foundation", -] - -[[package]] -name = "objc2-ui-kit" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d87d638e33c06f577498cbcc50491496a3ed4246998a7fbba7ccb98b1e7eab22" -dependencies = [ - "bitflags 2.13.1", - "block2", - "objc2", - "objc2-cloud-kit", - "objc2-core-data", - "objc2-core-foundation", - "objc2-core-graphics", - "objc2-core-image", - "objc2-core-location", - "objc2-core-text", - "objc2-foundation", - "objc2-quartz-core", - "objc2-user-notifications", -] - -[[package]] -name = "objc2-user-notifications" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9df9128cbbfef73cda168416ccf7f837b62737d748333bfe9ab71c245d76613e" -dependencies = [ - "objc2", - "objc2-foundation", -] - -[[package]] -name = "objc2-web-kit" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2e5aaab980c433cf470df9d7af96a7b46a9d892d521a2cbbb2f8a4c16751e7f" -dependencies = [ - "bitflags 2.13.1", - "block2", - "objc2", - "objc2-app-kit", - "objc2-core-foundation", - "objc2-foundation", -] - -[[package]] -name = "once_cell" -version = "1.21.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50" - -[[package]] -name = "open" -version = "5.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a0b3d059e795d52b8a72fef45658620edd4d9c359b338564aa14391ffa511ed5" -dependencies = [ - "dunce", - "is-wsl", - "libc", -] - -[[package]] -name = "option-ext" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" - -[[package]] -name = "ordered-stream" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9aa2b01e1d916879f73a53d01d1d6cee68adbb31d6d9177a8cfce093cced1d50" -dependencies = [ - "futures-core", - "pin-project-lite", -] - -[[package]] -name = "pango" -version = "0.18.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ca27ec1eb0457ab26f3036ea52229edbdb74dee1edd29063f5b9b010e7ebee4" -dependencies = [ - "gio", - "glib", - "libc", - "once_cell", - "pango-sys", -] - -[[package]] -name = "pango-sys" -version = "0.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "436737e391a843e5933d6d9aa102cb126d501e815b83601365a948a518555dc5" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "parking" -version = "2.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f38d5652c16fde515bb1ecef450ab0f6a219d619a7274976324d5e377f7dceba" - -[[package]] -name = "parking_lot" -version = "0.12.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93857453250e3077bd71ff98b6a65ea6621a19bb0f559a85248955ac12c45a1a" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2621685985a2ebf1c516881c026032ac7deafcda1a2c9b7850dc81e3dfcb64c1" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-link 0.2.1", -] - -[[package]] -name = "percent-encoding" -version = "2.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220" - -[[package]] -name = "phf" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1562dc717473dbaa4c1f85a36410e03c047b2e7df7f45ee938fbef64ae7fadf" -dependencies = [ - "phf_macros", - "phf_shared", - "serde", -] - -[[package]] -name = "phf_codegen" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49aa7f9d80421bca176ca8dbfebe668cc7a2684708594ec9f3c0db0805d5d6e1" -dependencies = [ - "phf_generator", - "phf_shared", -] - -[[package]] -name = "phf_generator" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "135ace3a761e564ec88c03a77317a7c6b80bb7f7135ef2544dbe054243b89737" -dependencies = [ - "fastrand", - "phf_shared", -] - -[[package]] -name = "phf_macros" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "812f032b54b1e759ccd5f8b6677695d5268c588701effba24601f6932f8269ef" -dependencies = [ - "phf_generator", - "phf_shared", - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "phf_shared" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e57fef6bc5981e38c2ce2d63bfa546861309f875b8a75f092d1d54ae2d64f266" -dependencies = [ - "siphasher", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a89322df9ebe1c1578d689c92318e070967d1042b512afbe49518723f4e6d5cd" - -[[package]] -name = "piper" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c835479a4443ded371d6c535cbfd8d31ad92c5d23ae9770a61bc155e4992a3c1" -dependencies = [ - "atomic-waker", - "fastrand", - "futures-io", -] - -[[package]] -name = "pkg-config" -version = "0.3.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19f132c84eca552bf34cab8ec81f1c1dcc229b811638f9d283dceabe58c5569e" - -[[package]] -name = "plist" -version = "1.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7da1d65da6dd5d1e44199ac0f58712d241c0f439f80adea8924d832384087f85" -dependencies = [ - "base64 0.22.1", - "indexmap 2.14.0", - "quick-xml", - "serde", - "time", -] - -[[package]] -name = "png" -version = "0.17.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82151a2fc869e011c153adc57cf2789ccb8d9906ce52c0b39a6b5697749d7526" -dependencies = [ - "bitflags 1.3.2", - "crc32fast", - "fdeflate", - "flate2", - "miniz_oxide", -] - -[[package]] -name = "png" -version = "0.18.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60769b8b31b2a9f263dae2776c37b1b28ae246943cf719eb6946a1db05128a61" -dependencies = [ - "bitflags 2.13.1", - "crc32fast", - "fdeflate", - "flate2", - "miniz_oxide", -] - -[[package]] -name = "polling" -version = "3.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d0e4f59085d47d8241c88ead0f274e8a0cb551f3625263c05eb8dd897c34218" -dependencies = [ - "cfg-if", - "concurrent-queue", - "hermit-abi", - "pin-project-lite", - "rustix", - "windows-sys 0.61.2", -] - -[[package]] -name = "potential_utf" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0103b1cef7ec0cf76490e969665504990193874ea05c85ff9bab8b911d0a0564" -dependencies = [ - "zerovec", -] - -[[package]] -name = "powerfmt" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391" - -[[package]] -name = "precomputed-hash" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c" - -[[package]] -name = "proc-macro-crate" -version = "1.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" -dependencies = [ - "once_cell", - "toml_edit 0.19.15", -] - -[[package]] -name = "proc-macro-crate" -version = "2.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b00f26d3400549137f92511a46ac1cd8ce37cb5598a96d382381458b992a5d24" -dependencies = [ - "toml_datetime 0.6.3", - "toml_edit 0.20.2", -] - -[[package]] -name = "proc-macro-crate" -version = "3.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e67ba7e9b2b56446f1d419b1d807906278ffa1a658a8a5d8a39dcb1f5a78614f" -dependencies = [ - "toml_edit 0.25.13+spec-1.1.0", -] - -[[package]] -name = "proc-macro-error" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" -dependencies = [ - "proc-macro-error-attr", - "proc-macro2", - "quote", - "syn 1.0.109", - "version_check", -] - -[[package]] -name = "proc-macro-error-attr" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" -dependencies = [ - "proc-macro2", - "quote", - "version_check", -] - -[[package]] -name = "proc-macro2" -version = "1.0.107" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "985e7ec9bb745e6ce6535b544d84d6cd6f7ad8bd711c398938ae983b91a766d9" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quick-xml" -version = "0.41.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e660451e55124f798a69a5af3f49ccfbefbd41910eefd25caf2393e1f3473ec1" -dependencies = [ - "memchr", -] - -[[package]] -name = "quote" -version = "1.0.47" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fbf4db142a473a8d80c26bbf18454ed458bf8d26c8219c331daecfdbd079001" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "r-efi" -version = "5.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f" - -[[package]] -name = "r-efi" -version = "6.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf" - -[[package]] -name = "raw-window-handle" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20675572f6f24e9e76ef639bc5552774ed45f1c30e2951e1e99c59888861c539" - -[[package]] -name = "redox_syscall" -version = "0.5.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed2bf2547551a7053d6fdfafda3f938979645c44812fbfcda098faae3f1a362d" -dependencies = [ - "bitflags 2.13.1", -] - -[[package]] -name = "redox_users" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4e608c6638b9c18977b00b475ac1f28d14e84b27d8d42f70e0bf1e3dec127ac" -dependencies = [ - "getrandom 0.2.17", - "libredox", - "thiserror 2.0.19", -] - -[[package]] -name = "ref-cast" -version = "1.0.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "216e8f773d7923bcba9ceb86a86c93cabb3903a11872fc3f138c49630e50b96d" -dependencies = [ - "ref-cast-impl", -] - -[[package]] -name = "ref-cast-impl" -version = "1.0.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c9283685feec7d69af75fb0e858d5e7378f33fe4fc699383b2916ab9273e03c" -dependencies = [ - "proc-macro2", - "quote", - "syn 3.0.3", -] - -[[package]] -name = "regex" -version = "1.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f020237b6c8eed93db2e2cb53c00c60a8e1bc73da7d073199a1180401450218d" -dependencies = [ - "aho-corasick", - "memchr", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.4.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fcfdb36bda0c880c5931cdc7a2bcdc8ba4556847b9d912bca70bc94708711ad" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4" - -[[package]] -name = "reqwest" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "219c5811de6525e5416c7d5d53bb656d3afdbc6c5af816e0802bcfa42dbdc1c3" -dependencies = [ - "base64 0.22.1", - "bytes", - "futures-core", - "futures-util", - "http", - "http-body", - "http-body-util", - "hyper", - "hyper-util", - "js-sys", - "log", - "percent-encoding", - "pin-project-lite", - "serde", - "serde_json", - "sync_wrapper", - "tokio", - "tokio-util", - "tower", - "tower-http", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "wasm-streams", - "web-sys", -] - -[[package]] -name = "rfd" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a15ad77d9e70a92437d8f74c35d99b4e4691128df018833e99f90bcd36152672" -dependencies = [ - "block2", - "dispatch2", - "glib-sys", - "gobject-sys", - "gtk-sys", - "js-sys", - "log", - "objc2", - "objc2-app-kit", - "objc2-core-foundation", - "objc2-foundation", - "raw-window-handle", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "windows-sys 0.60.2", -] - -[[package]] -name = "ring" -version = "0.17.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4689e6c2294d81e88dc6261c768b63bc4fcdb852be6d1352498b114f61383b7" -dependencies = [ - "cc", - "cfg-if", - "getrandom 0.2.17", - "libc", - "untrusted", - "windows-sys 0.52.0", -] - -[[package]] -name = "rustc-hash" -version = "2.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b1e7f9a428571be2dc5bc0505c13fb6bf936822b894ec87abf8a08a4e51742d" - -[[package]] -name = "rustc_version" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "1.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6fe4565b9518b83ef4f91bb47ce29620ca828bd32cb7e408f0062e9930ba190" -dependencies = [ - "bitflags 2.13.1", - "errno", - "libc", - "linux-raw-sys", - "windows-sys 0.52.0", -] - -[[package]] -name = "rustls" -version = "0.23.46" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48e13bd8c0e9365c43cfa5c9e8f9ad49d3c8444926c9aac819e0e4dc503c8fdf" -dependencies = [ - "log", - "once_cell", - "ring", - "rustls-pki-types", - "rustls-webpki", - "subtle", - "zeroize", -] - -[[package]] -name = "rustls-pki-types" -version = "1.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f4925028c7eb5d1fcdaf196971378ed9d2c1c4efc7dc5d011256f76c99c0a96" -dependencies = [ - "zeroize", -] - -[[package]] -name = "rustls-webpki" -version = "0.103.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4443b1b6d39d7c663139942cc4558262562d2c84123bb6282ef177009ca8b281" -dependencies = [ - "ring", - "rustls-pki-types", - "untrusted", -] - -[[package]] -name = "rustversion" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f" - -[[package]] -name = "same-file" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "schemars" -version = "0.8.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fbf2ae1b8bc8e02df939598064d22402220cd5bbcca1c76f7d6a310974d5615" -dependencies = [ - "dyn-clone", - "indexmap 1.9.3", - "schemars_derive", - "serde", - "serde_json", - "url", - "uuid", -] - -[[package]] -name = "schemars" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4cd191f9397d57d581cddd31014772520aa448f65ef991055d7f61582c65165f" -dependencies = [ - "dyn-clone", - "ref-cast", - "serde", - "serde_json", -] - -[[package]] -name = "schemars" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2b42f36aa1cd011945615b92222f6bf73c599a102a300334cd7f8dbeec726cc" -dependencies = [ - "dyn-clone", - "ref-cast", - "serde", - "serde_json", -] - -[[package]] -name = "schemars_derive" -version = "0.8.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32e265784ad618884abaea0600a9adf15393368d840e0222d101a072f3f7534d" -dependencies = [ - "proc-macro2", - "quote", - "serde_derive_internals", - "syn 2.0.119", -] - -[[package]] -name = "scopeguard" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" - -[[package]] -name = "selectors" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c5d9c0c92a92d33f08817311cf3f2c29a3538a8240e94a6a3c622ce652d7e00c" -dependencies = [ - "bitflags 2.13.1", - "cssparser", - "derive_more", - "log", - "new_debug_unreachable", - "phf", - "phf_codegen", - "precomputed-hash", - "rustc-hash", - "servo_arc", - "smallvec", -] - -[[package]] -name = "semver" -version = "1.0.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd" -dependencies = [ - "serde", - "serde_core", -] - -[[package]] -name = "serde" -version = "1.0.229" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4148590afebada386688f18773da617792bf2ef03ffc1e4cbd2b1d45b023e0ba" -dependencies = [ - "serde_core", - "serde_derive", -] - -[[package]] -name = "serde-untagged" -version = "0.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9faf48a4a2d2693be24c6289dbe26552776eb7737074e6722891fadbe6c5058" -dependencies = [ - "erased-serde", - "serde", - "serde_core", - "typeid", -] - -[[package]] -name = "serde_core" -version = "1.0.229" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67dca2c9c51e58a4791a4b1ed58308b39c64224d349a935ab5039aa360942a48" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.229" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7a5d71263a5a7d47b41f6b3f06ba276f10cc18b0931f1799f710578e2309348" -dependencies = [ - "proc-macro2", - "quote", - "syn 3.0.3", -] - -[[package]] -name = "serde_derive_internals" -version = "0.29.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18d26a20a969b9e3fdf2fc2d9f21eda6c40e2de84c9408bb5d3b05d499aae711" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "serde_json" -version = "1.0.151" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c841b55ecdae098c80dcae9cf767f6f8a0c2cdb3416bbef72181df4d0fe73f14" -dependencies = [ - "itoa", - "memchr", - "serde", - "serde_core", - "zmij", -] - -[[package]] -name = "serde_repr" -version = "0.1.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d3b1629de253c70a0508c3899572da79ca359fdab27c7920ff00406df418906" -dependencies = [ - "proc-macro2", - "quote", - "syn 3.0.3", -] - -[[package]] -name = "serde_spanned" -version = "0.6.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf41e0cfaf7226dca15e8197172c295a782857fcb97fad1808a166870dee75a3" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_spanned" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6662b5879511e06e8999a8a235d848113e942c9124f211511b16466ee2995f26" -dependencies = [ - "serde_core", -] - -[[package]] -name = "serde_with" -version = "3.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76a5c54c7310e7b8b9577c286d7e399ddd876c3e12b3ed917a8aabc4b96e9e8c" -dependencies = [ - "base64 0.22.1", - "bs58", - "chrono", - "hex", - "indexmap 1.9.3", - "indexmap 2.14.0", - "schemars 0.9.0", - "schemars 1.2.1", - "serde_core", - "serde_json", - "serde_with_macros", - "time", -] - -[[package]] -name = "serde_with_macros" -version = "3.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84d57bc0c8b9a17920c178daa6bb924850d54a9c97ab45194bb8c17ad66bb660" -dependencies = [ - "darling", - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "serialize-to-javascript" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04f3666a07a197cdb77cdf306c32be9b7f598d7060d50cfd4d5aa04bfd92f6c5" -dependencies = [ - "serde", - "serde_json", - "serialize-to-javascript-impl", -] - -[[package]] -name = "serialize-to-javascript-impl" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "772ee033c0916d670af7860b6e1ef7d658a4629a6d0b4c8c3e67f09b3765b75d" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "servo_arc" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "170fb83ab34de17dc69aa7c67482b22218ddb85da56546f9bd6b929e32a05930" -dependencies = [ - "stable_deref_trait", -] - -[[package]] -name = "sha2" -version = "0.10.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7507d819769d01a365ab707794a4084392c824f54a7a6a7862f8c3d0892b283" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "shlex" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8fadd59c855ef2080decdef8ff161eb6661b86933c9d82e5ba29dc602a55aba" - -[[package]] -name = "signal-hook-registry" -version = "1.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4db69cba1110affc0e9f7bcd48bbf87b3f4fc7c61fc9155afd4c469eb3d6c1b" -dependencies = [ - "errno", - "libc", -] - -[[package]] -name = "simd-adler32" -version = "0.3.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a219298ac11a56ea9a6d2120044824d6f01aeb034955e7af7bc16858527deea" - -[[package]] -name = "siphasher" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ee5873ec9cce0195efcb7a4e9507a04cd49aec9c83d0389df45b1ef7ba2e649" - -[[package]] -name = "slab" -version = "0.4.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5" - -[[package]] -name = "smallvec" -version = "1.15.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ed6a63f02c8539c91a8685a86f4099661ba3da017932f6ebbea6de3f0fa7c90" - -[[package]] -name = "socket2" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3d1e2c7f27f8d4cb10542a02c49005dbd6e93095799d6f3be745fae9f8fedd4" -dependencies = [ - "libc", - "windows-sys 0.60.2", -] - -[[package]] -name = "softbuffer" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aac18da81ebbf05109ab275b157c22a653bb3c12cf884450179942f81bcbf6c3" -dependencies = [ - "bytemuck", - "js-sys", - "ndk", - "objc2", - "objc2-core-foundation", - "objc2-core-graphics", - "objc2-foundation", - "objc2-quartz-core", - "raw-window-handle", - "redox_syscall", - "tracing", - "wasm-bindgen", - "web-sys", - "windows-sys 0.61.2", -] - -[[package]] -name = "soup3" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "471f924a40f31251afc77450e781cb26d55c0b650842efafc9c6cbd2f7cc4f9f" -dependencies = [ - "futures-channel", - "gio", - "glib", - "libc", - "soup3-sys", -] - -[[package]] -name = "soup3-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ebe8950a680a12f24f15ebe1bf70db7af98ad242d9db43596ad3108aab86c27" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "stable_deref_trait" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596" - -[[package]] -name = "string_cache" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a18596f8c785a729f2819c0f6a7eae6ebeebdfffbfe4214ae6b087f690e31901" -dependencies = [ - "new_debug_unreachable", - "parking_lot", - "phf_shared", - "precomputed-hash", -] - -[[package]] -name = "string_cache_codegen" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "585635e46db231059f76c5849798146164652513eb9e8ab2685939dd90f29b69" -dependencies = [ - "phf_generator", - "phf_shared", - "proc-macro2", - "quote", -] - -[[package]] -name = "strsim" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" - -[[package]] -name = "subtle" -version = "2.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" - -[[package]] -name = "swift-rs" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4057c98e2e852d51fdcfca832aac7b571f6b351ad159f9eda5db1655f8d0c4d7" -dependencies = [ - "base64 0.21.7", - "serde", - "serde_json", -] - -[[package]] -name = "syn" -version = "1.0.109" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" -dependencies = [ - "proc-macro2", - "unicode-ident", -] - -[[package]] -name = "syn" -version = "2.0.119" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "872831b642d1a07999a962a351ed35b955ea2cfc8f3862091e2a240a84f17297" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "syn" -version = "3.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53e9bae58849f64dfa4f5d5ae372c8341f7305f82a3868709269343628b659a3" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "sync_wrapper" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bf256ce5efdfa370213c1dabab5935a12e49f2c58d15e9eac2870d3b4f27263" -dependencies = [ - "futures-core", -] - -[[package]] -name = "synstructure" -version = "0.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "728a70f3dbaf5bab7f0c4b1ac8d7ae5ea60a4b5549c8a5914361c99147a709d2" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "system-deps" -version = "6.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3e535eb8dded36d55ec13eddacd30dec501792ff23a0b1682c38601b8cf2349" -dependencies = [ - "cfg-expr", - "heck 0.5.0", - "pkg-config", - "toml 0.8.2", - "version-compare", -] - -[[package]] -name = "tao" -version = "0.35.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1c93047acf68669466a34690ac58cca7010bd1b201e1ec86f1fd0a75d3dd4a9" -dependencies = [ - "bitflags 2.13.1", - "block2", - "core-foundation", - "core-graphics", - "crossbeam-channel", - "dbus", - "dispatch2", - "dlopen2", - "dpi", - "gdkwayland-sys", - "gdkx11-sys", - "gtk", - "jni", - "libc", - "log", - "ndk", - "ndk-sys", - "objc2", - "objc2-app-kit", - "objc2-foundation", - "objc2-ui-kit", - "once_cell", - "parking_lot", - "percent-encoding", - "raw-window-handle", - "tao-macros", - "unicode-segmentation", - "url", - "windows", - "windows-core 0.61.2", - "windows-version", - "x11-dl", -] - -[[package]] -name = "tao-macros" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4e16beb8b2ac17db28eab8bca40e62dbfbb34c0fcdc6d9826b11b7b5d047dfd" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "target-lexicon" -version = "0.12.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61c41af27dd6d1e27b1b16b489db798443478cef1f06a660c96db617ba5de3b1" - -[[package]] -name = "tauri" -version = "2.11.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "667b20e2726d572dea2de7370da16e188eb06008faf9a92fab7cdc46791190b5" -dependencies = [ - "anyhow", - "bytes", - "cookie", - "dirs", - "dunce", - "embed_plist", - "getrandom 0.3.4", - "glob", - "gtk", - "heck 0.5.0", - "http", - "jni", - "libc", - "log", - "mime", - "muda", - "objc2", - "objc2-app-kit", - "objc2-foundation", - "objc2-ui-kit", - "objc2-web-kit", - "percent-encoding", - "plist", - "raw-window-handle", - "reqwest", - "serde", - "serde_json", - "serde_repr", - "serialize-to-javascript", - "swift-rs", - "tauri-build", - "tauri-macros", - "tauri-runtime", - "tauri-runtime-wry", - "tauri-utils", - "thiserror 2.0.19", - "tokio", - "tray-icon", - "url", - "webkit2gtk", - "webview2-com", - "window-vibrancy", - "windows", -] - -[[package]] -name = "tauri-build" -version = "2.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc9ce40b16101cb6ea63d3e221567affd1c3a9205f95d7bc574941a10636b632" -dependencies = [ - "anyhow", - "cargo_toml", - "dirs", - "glob", - "heck 0.5.0", - "json-patch", - "schemars 0.8.22", - "semver", - "serde", - "serde_json", - "tauri-utils", - "tauri-winres", - "walkdir", -] - -[[package]] -name = "tauri-codegen" -version = "2.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08279169ff42f8fc45a1dbc9dcae888893ba95288142e5880c59b93a26d2cfc5" -dependencies = [ - "base64 0.22.1", - "brotli", - "ico", - "json-patch", - "plist", - "png 0.17.16", - "proc-macro2", - "quote", - "semver", - "serde", - "serde_json", - "sha2", - "syn 2.0.119", - "tauri-utils", - "thiserror 2.0.19", - "time", - "url", - "uuid", - "walkdir", -] - -[[package]] -name = "tauri-macros" -version = "2.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8b394794f399a421811d06966343e7933fcae92d59f5180b9388d1174497a45" -dependencies = [ - "heck 0.5.0", - "proc-macro2", - "quote", - "syn 2.0.119", - "tauri-codegen", - "tauri-utils", -] - -[[package]] -name = "tauri-plugin" -version = "2.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74be5dd4bed9afbd145e5716b5fa2ec28cbc29c34ffa61c258c9273d896c8020" -dependencies = [ - "anyhow", - "glob", - "plist", - "schemars 0.8.22", - "serde", - "serde_json", - "tauri-utils", - "walkdir", -] - -[[package]] -name = "tauri-plugin-dialog" -version = "2.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2d3c1dbe38037e7f590cdf2492594d5ceebe031e7bc7e827509b22a999d2940" -dependencies = [ - "log", - "raw-window-handle", - "rfd", - "serde", - "serde_json", - "tauri", - "tauri-plugin", - "tauri-plugin-fs", - "thiserror 2.0.19", - "url", -] - -[[package]] -name = "tauri-plugin-fs" -version = "2.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7ecc274121aca0c036a2b42d1cbe83d368d348f54e0bb8a735c2b1548e8f371" -dependencies = [ - "anyhow", - "dunce", - "glob", - "log", - "objc2-foundation", - "percent-encoding", - "schemars 0.8.22", - "serde", - "serde_json", - "serde_repr", - "tauri", - "tauri-plugin", - "tauri-utils", - "thiserror 2.0.19", - "toml 1.1.3+spec-1.1.0", - "url", -] - -[[package]] -name = "tauri-plugin-opener" -version = "2.5.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17e1bea14edce6b793a04e2417e3fd924b9bc4faae83cdee7d714156cceeed29" -dependencies = [ - "dunce", - "glob", - "objc2-app-kit", - "objc2-foundation", - "open", - "schemars 0.8.22", - "serde", - "serde_json", - "tauri", - "tauri-plugin", - "thiserror 2.0.19", - "url", - "windows", - "zbus", -] - -[[package]] -name = "tauri-runtime" -version = "2.11.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0b4bc95aed361b0019067d189a1174a603d460d0f6c72606512d59fc9c12ec8" -dependencies = [ - "cookie", - "dpi", - "gtk", - "http", - "jni", - "objc2", - "objc2-ui-kit", - "objc2-web-kit", - "raw-window-handle", - "serde", - "serde_json", - "tauri-utils", - "thiserror 2.0.19", - "url", - "webkit2gtk", - "webview2-com", - "windows", -] - -[[package]] -name = "tauri-runtime-wry" -version = "2.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e6fac707727b7a2f48e4ded90976324267371073edbb415ffb73bb0458d203f" -dependencies = [ - "gtk", - "http", - "jni", - "log", - "objc2", - "objc2-app-kit", - "once_cell", - "percent-encoding", - "raw-window-handle", - "softbuffer", - "tao", - "tauri-runtime", - "tauri-utils", - "url", - "webkit2gtk", - "webview2-com", - "windows", - "wry", -] - -[[package]] -name = "tauri-utils" -version = "2.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e176a18e67764923c4f1ce66f25ae4abe5f688384d5eb1a0fa6c77f3d90f887" -dependencies = [ - "anyhow", - "brotli", - "cargo_metadata", - "ctor", - "dom_query", - "dunce", - "glob", - "http", - "infer", - "json-patch", - "log", - "memchr", - "phf", - "plist", - "proc-macro2", - "quote", - "regex", - "schemars 0.8.22", - "semver", - "serde", - "serde-untagged", - "serde_json", - "serde_with", - "swift-rs", - "thiserror 2.0.19", - "toml 1.1.3+spec-1.1.0", - "url", - "urlpattern", - "uuid", - "walkdir", -] - -[[package]] -name = "tauri-winres" -version = "0.3.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc65d45c68858bfe420dd29e834b5d15dbecf8a07a8a16cf4d532c7b1f69d4b6" -dependencies = [ - "dunce", - "embed-resource", - "toml 1.1.3+spec-1.1.0", -] - -[[package]] -name = "tempfile" -version = "3.27.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32497e9a4c7b38532efcdebeef879707aa9f794296a4f0244f6f69e9bc8574bd" -dependencies = [ - "fastrand", - "getrandom 0.4.3", - "once_cell", - "rustix", - "windows-sys 0.52.0", -] - -[[package]] -name = "tendril" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5fed54709c5b3a53d09bb1c113ea4f5ceafd1e772ddcb0030a82e1d56c087b08" -dependencies = [ - "new_debug_unreachable", -] - -[[package]] -name = "thiserror" -version = "1.0.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52" -dependencies = [ - "thiserror-impl 1.0.69", -] - -[[package]] -name = "thiserror" -version = "2.0.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09a43598840e33d5b0331f38c5e30d13bb11c11210a4b58f0d9b18a5a5eefcd9" -dependencies = [ - "thiserror-impl 2.0.19", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "thiserror-impl" -version = "2.0.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43cbfe0cf76104d42a574802844187e84a305e531ed54455f11fbde0f10541cd" -dependencies = [ - "proc-macro2", - "quote", - "syn 3.0.3", -] - -[[package]] -name = "time" -version = "0.3.54" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e1d5e639ff6bab73cb6885cc7e7b1de96c3f32c68ec55f3952614bec1092244" -dependencies = [ - "deranged", - "num-conv", - "powerfmt", - "serde_core", - "time-core", - "time-macros", -] - -[[package]] -name = "time-core" -version = "0.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e1c906769ad99c88eaa54e728060edef082f8e358ff32030cb7c7d315e81109" - -[[package]] -name = "time-macros" -version = "0.2.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e689342a48d2ea927c87ea50cabf8594854bf940e9310208848d680d668ed85" -dependencies = [ - "num-conv", - "time-core", -] - -[[package]] -name = "tinystr" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8323304221c2a851516f22236c5722a72eaa19749016521d6dff0824447d96d" -dependencies = [ - "displaydoc", - "zerovec", -] - -[[package]] -name = "tinyvec" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb4ebadaa0af04fab11ae01eb5f9fdb5f9c5b875506e210e71c07873528baa7f" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.53.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce3335fa71841cda333a58d7615b03901380ecf09d59b3296d21f8bbac0dde4e" -dependencies = [ - "bytes", - "libc", - "mio", - "pin-project-lite", - "socket2", - "tokio-macros", - "windows-sys 0.61.2", -] - -[[package]] -name = "tokio-macros" -version = "2.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6328af13490e73a9b4694030fafd93f8c8c6a9dede33e821c3fc63eddf8042ba" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "tokio-util" -version = "0.7.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "494815d09bf52b5548659851081238f0ca39ff638363907596da739561c62c52" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "toml" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "185d8ab0dfbb35cf1399a6344d8484209c088f75f8f68230da55d48d95d43e3d" -dependencies = [ - "serde", - "serde_spanned 0.6.9", - "toml_datetime 0.6.3", - "toml_edit 0.20.2", -] - -[[package]] -name = "toml" -version = "0.9.12+spec-1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf92845e79fc2e2def6a5d828f0801e29a2f8acc037becc5ab08595c7d5e9863" -dependencies = [ - "indexmap 2.14.0", - "serde_core", - "serde_spanned 1.1.1", - "toml_datetime 0.7.5+spec-1.1.0", - "toml_parser", - "toml_writer", - "winnow 0.7.15", -] - -[[package]] -name = "toml" -version = "1.1.3+spec-1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53c96ecdfa941c8fc4fcaed14f99ada8ebed502eef533015095a07e3301d4c3c" -dependencies = [ - "indexmap 2.14.0", - "serde_core", - "serde_spanned 1.1.1", - "toml_datetime 1.1.1+spec-1.1.0", - "toml_parser", - "toml_writer", - "winnow 1.0.4", -] - -[[package]] -name = "toml_datetime" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_datetime" -version = "0.7.5+spec-1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92e1cfed4a3038bc5a127e35a2d360f145e1f4b971b551a2ba5fd7aedf7e1347" -dependencies = [ - "serde_core", -] - -[[package]] -name = "toml_datetime" -version = "1.1.1+spec-1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3165f65f62e28e0115a00b2ebdd37eb6f3b641855f9d636d3cd4103767159ad7" -dependencies = [ - "serde_core", -] - -[[package]] -name = "toml_edit" -version = "0.19.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" -dependencies = [ - "indexmap 2.14.0", - "toml_datetime 0.6.3", - "winnow 0.5.40", -] - -[[package]] -name = "toml_edit" -version = "0.20.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "396e4d48bbb2b7554c944bde63101b5ae446cff6ec4a24227428f15eb72ef338" -dependencies = [ - "indexmap 2.14.0", - "serde", - "serde_spanned 0.6.9", - "toml_datetime 0.6.3", - "winnow 0.5.40", -] - -[[package]] -name = "toml_edit" -version = "0.25.13+spec-1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6975367e4d2ef766d86af01ffad14b622fecc8d4357a998fbc4deb6e9bacaf9b" -dependencies = [ - "indexmap 2.14.0", - "toml_datetime 1.1.1+spec-1.1.0", - "toml_parser", - "winnow 1.0.4", -] - -[[package]] -name = "toml_parser" -version = "1.1.2+spec-1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2abe9b86193656635d2411dc43050282ca48aa31c2451210f4202550afb7526" -dependencies = [ - "winnow 1.0.4", -] - -[[package]] -name = "toml_writer" -version = "1.1.2+spec-1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d56353a2a665ad0f41a421187180aab746c8c325620617ad883a99a1cbe66d2" - -[[package]] -name = "tower" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebe5ef63511595f1344e2d5cfa636d973292adc0eec1f0ad45fae9f0851ab1d4" -dependencies = [ - "futures-core", - "futures-util", - "pin-project-lite", - "sync_wrapper", - "tokio", - "tower-layer", - "tower-service", -] - -[[package]] -name = "tower-http" -version = "0.6.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4cfcf7e2740e6fc6d4d688b4ef00650406bb94adf4731e43c096c3a19fe40840" -dependencies = [ - "bitflags 2.13.1", - "bytes", - "futures-util", - "http", - "http-body", - "pin-project-lite", - "tower", - "tower-layer", - "tower-service", - "url", -] - -[[package]] -name = "tower-layer" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e" - -[[package]] -name = "tower-service" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" - -[[package]] -name = "tracing" -version = "0.1.44" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "63e71662fa4b2a2c3a26f570f037eb95bb1f85397f3cd8076caed2f026a6d100" -dependencies = [ - "pin-project-lite", - "tracing-attributes", - "tracing-core", -] - -[[package]] -name = "tracing-attributes" -version = "0.1.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7490cfa5ec963746568740651ac6781f701c9c5ea257c58e057f3ba8cf69e8da" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "tracing-core" -version = "0.1.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db97caf9d906fbde555dd62fa95ddba9eecfd14cb388e4f491a66d74cd5fb79a" -dependencies = [ - "once_cell", -] - -[[package]] -name = "tray-icon" -version = "0.24.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65ba1e5f6b9ef9fd87e21b9c6f351554dbd717960089168fcfdef854686961dc" -dependencies = [ - "crossbeam-channel", - "dirs", - "libappindicator", - "muda", - "objc2", - "objc2-app-kit", - "objc2-core-foundation", - "objc2-core-graphics", - "objc2-foundation", - "once_cell", - "png 0.18.1", - "serde", - "thiserror 2.0.19", - "windows-sys 0.60.2", -] - -[[package]] -name = "try-lock" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" - -[[package]] -name = "typeid" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc7d623258602320d5c55d1bc22793b57daff0ec7efc270ea7d55ce1d5f5471c" - -[[package]] -name = "typenum" -version = "1.20.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6f5e870be6c3b371b77fe0ee0bafb859fa4964b4404c27de1d380043c4dda20" - -[[package]] -name = "uds_windows" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2f6fb2847f6742cd76af783a2a2c49e9375d0a111c7bef6f71cd9e738c72d6e" -dependencies = [ - "memoffset", - "tempfile", - "windows-sys 0.60.2", -] - -[[package]] -name = "unic-char-property" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8c57a407d9b6fa02b4795eb81c5b6652060a15a7903ea981f3d723e6c0be221" -dependencies = [ - "unic-char-range", -] - -[[package]] -name = "unic-char-range" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0398022d5f700414f6b899e10b8348231abf9173fa93144cbc1a43b9793c1fbc" - -[[package]] -name = "unic-common" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80d7ff825a6a654ee85a63e80f92f054f904f21e7d12da4e22f9834a4aaa35bc" - -[[package]] -name = "unic-ucd-ident" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e230a37c0381caa9219d67cf063aa3a375ffed5bf541a452db16e744bdab6987" -dependencies = [ - "unic-char-property", - "unic-char-range", - "unic-ucd-version", -] - -[[package]] -name = "unic-ucd-version" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96bd2f2237fe450fcd0a1d2f5f4e91711124f7857ba2e964247776ebeeb7b0c4" -dependencies = [ - "unic-common", -] - -[[package]] -name = "unicode-ident" -version = "1.0.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75" - -[[package]] -name = "unicode-segmentation" -version = "1.13.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6f5d3c3b1bf09027a88a6bc961fc00497d651009560b5463668dc81b0fa87a8" - -[[package]] -name = "untrusted" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" - -[[package]] -name = "ureq" -version = "3.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dea7109cdcd5864d4eeb1b58a1648dc9bf520360d7af16ec26d0a9354bafcfc0" -dependencies = [ - "base64 0.22.1", - "flate2", - "log", - "percent-encoding", - "rustls", - "rustls-pki-types", - "ureq-proto", - "utf8-zero", - "webpki-roots", -] - -[[package]] -name = "ureq-proto" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e994ba84b0bd1b1b0cf92878b7ef898a5c1760108fe7b6010327e274917a808c" -dependencies = [ - "base64 0.22.1", - "http", - "httparse", - "log", -] - -[[package]] -name = "url" -version = "2.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff67a8a4397373c3ef660812acab3268222035010ab8680ec4215f38ba3d0eed" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", - "serde", - "serde_derive", -] - -[[package]] -name = "urlpattern" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70acd30e3aa1450bc2eece896ce2ad0d178e9c079493819301573dae3c37ba6d" -dependencies = [ - "regex", - "serde", - "unic-ucd-ident", - "url", -] - -[[package]] -name = "utf8-zero" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8c0a043c9540bae7c578c88f91dda8bd82e59ae27c21baca69c8b191aaf5a6e" - -[[package]] -name = "utf8_iter" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be" - -[[package]] -name = "uuid" -version = "1.24.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf3923a6f5c4c6382e0b653c4117f48d631ea17f38ed86e2a828e6f7412f5239" -dependencies = [ - "getrandom 0.4.3", - "js-sys", - "serde_core", - "wasm-bindgen", -] - -[[package]] -name = "version-compare" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03c2856837ef78f57382f06b2b8563a2f512f7185d732608fd9176cb3b8edf0e" - -[[package]] -name = "version_check" -version = "0.9.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" - -[[package]] -name = "vswhom" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be979b7f07507105799e854203b470ff7c78a1639e330a58f183b5fea574608b" -dependencies = [ - "libc", - "vswhom-sys", -] - -[[package]] -name = "vswhom-sys" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb067e4cbd1ff067d1df46c9194b5de0e98efd2810bbc95c5d5e5f25a3231150" -dependencies = [ - "cc", - "libc", -] - -[[package]] -name = "walkdir" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" -dependencies = [ - "same-file", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" -dependencies = [ - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.11.1+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccf3ec651a847eb01de73ccad15eb7d99f80485de043efb2f370cd654f4ea44b" - -[[package]] -name = "wasip2" -version = "1.0.4+wasi-0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b67efb37e106e55ce722a510d6b5f9c17f083e5fc79afc2badeb12cc313d9487" -dependencies = [ - "wit-bindgen", -] - -[[package]] -name = "wasm-bindgen" -version = "0.2.126" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b067c0c11094aef6b7a801c1e34a26affafdf3d051dba08456b868789aaf9a4" -dependencies = [ - "cfg-if", - "once_cell", - "rustversion", - "wasm-bindgen-macro", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.76" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c62df1340f32221cb9c54d6a27b030e3dba64361d4a95bed55f9aacb44da291d" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.126" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "167ce5e579f6bcf889c4f7175a8a5a585de84e8ff93976ce393efa5f2837aab1" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.126" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3997c7839262f4ef12cf90b818d6340c18e80f263f1a94bf157d0ec4420380e" -dependencies = [ - "bumpalo", - "proc-macro2", - "quote", - "syn 2.0.119", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.126" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc1b4cb0cc549fcf58d7dfc081778139b3d283a081644e833e84682ad71cea24" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "wasm-streams" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d1ec4f6517c9e11ae630e200b2b65d193279042e28edd4a2cda233e46670bbb" -dependencies = [ - "futures-util", - "js-sys", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", -] - -[[package]] -name = "web-sys" -version = "0.3.103" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8622dcb61c0bcc9fffa6938bed81210af2da9a7e4a1a834b2e37a59b6dfb6141" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "web_atoms" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "075474b12bcb3d2e3d4546580e9de478eeeead668a1761e2a8860c836b7ef297" -dependencies = [ - "phf", - "phf_codegen", - "string_cache", - "string_cache_codegen", -] - -[[package]] -name = "webkit2gtk" -version = "2.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1027150013530fb2eaf806408df88461ae4815a45c541c8975e61d6f2fc4793" -dependencies = [ - "bitflags 1.3.2", - "cairo-rs", - "gdk", - "gdk-sys", - "gio", - "gio-sys", - "glib", - "glib-sys", - "gobject-sys", - "gtk", - "gtk-sys", - "javascriptcore-rs", - "libc", - "once_cell", - "soup3", - "webkit2gtk-sys", -] - -[[package]] -name = "webkit2gtk-sys" -version = "2.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "916a5f65c2ef0dfe12fff695960a2ec3d4565359fdbb2e9943c974e06c734ea5" -dependencies = [ - "bitflags 1.3.2", - "cairo-sys-rs", - "gdk-sys", - "gio-sys", - "glib-sys", - "gobject-sys", - "gtk-sys", - "javascriptcore-rs-sys", - "libc", - "pkg-config", - "soup3-sys", - "system-deps", -] - -[[package]] -name = "webpki-roots" -version = "1.0.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c1c8e20c8a38fc7d65abfe74eb7280e4aa667e8eec8bc84996d2874810748d9" -dependencies = [ - "rustls-pki-types", -] - -[[package]] -name = "webview2-com" -version = "0.38.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7130243a7a5b33c54a444e54842e6a9e133de08b5ad7b5861cd8ed9a6a5bc96a" -dependencies = [ - "webview2-com-macros", - "webview2-com-sys", - "windows", - "windows-core 0.61.2", - "windows-implement", - "windows-interface", -] - -[[package]] -name = "webview2-com-macros" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67a921c1b6914c367b2b823cd4cde6f96beec77d30a939c8199bb377cf9b9b54" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "webview2-com-sys" -version = "0.38.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "381336cfffd772377d291702245447a5251a2ffa5bad679c99e61bc48bacbf9c" -dependencies = [ - "thiserror 2.0.19", - "windows", - "windows-core 0.61.2", -] - -[[package]] -name = "winapi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" -dependencies = [ - "winapi-i686-pc-windows-gnu", - "winapi-x86_64-pc-windows-gnu", -] - -[[package]] -name = "winapi-i686-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" - -[[package]] -name = "winapi-util" -version = "0.1.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "winapi-x86_64-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" - -[[package]] -name = "window-vibrancy" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9bec5a31f3f9362f2258fd0e9c9dd61a9ca432e7306cc78c444258f0dce9a9c" -dependencies = [ - "objc2", - "objc2-app-kit", - "objc2-core-foundation", - "objc2-foundation", - "raw-window-handle", - "windows-sys 0.59.0", - "windows-version", -] - -[[package]] -name = "windows" -version = "0.61.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9babd3a767a4c1aef6900409f85f5d53ce2544ccdfaa86dad48c91782c6d6893" -dependencies = [ - "windows-collections", - "windows-core 0.61.2", - "windows-future", - "windows-link 0.1.3", - "windows-numerics", -] - -[[package]] -name = "windows-collections" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3beeceb5e5cfd9eb1d76b381630e82c4241ccd0d27f1a39ed41b2760b255c5e8" -dependencies = [ - "windows-core 0.61.2", -] - -[[package]] -name = "windows-core" -version = "0.61.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0fdd3ddb90610c7638aa2b3a3ab2904fb9e5cdbecc643ddb3647212781c4ae3" -dependencies = [ - "windows-implement", - "windows-interface", - "windows-link 0.1.3", - "windows-result 0.3.4", - "windows-strings 0.4.2", -] - -[[package]] -name = "windows-core" -version = "0.62.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8e83a14d34d0623b51dce9581199302a221863196a1dde71a7663a4c2be9deb" -dependencies = [ - "windows-implement", - "windows-interface", - "windows-link 0.2.1", - "windows-result 0.4.1", - "windows-strings 0.5.1", -] - -[[package]] -name = "windows-future" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc6a41e98427b19fe4b73c550f060b59fa592d7d686537eebf9385621bfbad8e" -dependencies = [ - "windows-core 0.61.2", - "windows-link 0.1.3", - "windows-threading", -] - -[[package]] -name = "windows-implement" -version = "0.60.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "053e2e040ab57b9dc951b72c264860db7eb3b0200ba345b4e4c3b14f67855ddf" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "windows-interface" -version = "0.59.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f316c4a2570ba26bbec722032c4099d8c8bc095efccdc15688708623367e358" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "windows-link" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e6ad25900d524eaabdbbb96d20b4311e1e7ae1699af4fb28c17ae66c80d798a" - -[[package]] -name = "windows-link" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5" - -[[package]] -name = "windows-numerics" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9150af68066c4c5c07ddc0ce30421554771e528bde427614c61038bc2c92c2b1" -dependencies = [ - "windows-core 0.61.2", - "windows-link 0.1.3", -] - -[[package]] -name = "windows-result" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56f42bd332cc6c8eac5af113fc0c1fd6a8fd2aa08a0119358686e5160d0586c6" -dependencies = [ - "windows-link 0.1.3", -] - -[[package]] -name = "windows-result" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7781fa89eaf60850ac3d2da7af8e5242a5ea78d1a11c49bf2910bb5a73853eb5" -dependencies = [ - "windows-link 0.2.1", -] - -[[package]] -name = "windows-strings" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56e6c93f3a0c3b36176cb1327a4958a0353d5d166c2a35cb268ace15e91d3b57" -dependencies = [ - "windows-link 0.1.3", -] - -[[package]] -name = "windows-strings" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7837d08f69c77cf6b07689544538e017c1bfcf57e34b4c0ff58e6c2cd3b37091" -dependencies = [ - "windows-link 0.2.1", -] - -[[package]] -name = "windows-sys" -version = "0.45.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" -dependencies = [ - "windows-targets 0.42.2", -] - -[[package]] -name = "windows-sys" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" -dependencies = [ - "windows-targets 0.52.6", -] - -[[package]] -name = "windows-sys" -version = "0.59.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" -dependencies = [ - "windows-targets 0.52.6", -] - -[[package]] -name = "windows-sys" -version = "0.60.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2f500e4d28234f72040990ec9d39e3a6b950f9f22d3dba18416c35882612bcb" -dependencies = [ - "windows-targets 0.53.5", -] - -[[package]] -name = "windows-sys" -version = "0.61.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc" -dependencies = [ - "windows-link 0.2.1", -] - -[[package]] -name = "windows-targets" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e5180c00cd44c9b1c88adb3693291f1cd93605ded80c250a75d472756b4d071" -dependencies = [ - "windows_aarch64_gnullvm 0.42.2", - "windows_aarch64_msvc 0.42.2", - "windows_i686_gnu 0.42.2", - "windows_i686_msvc 0.42.2", - "windows_x86_64_gnu 0.42.2", - "windows_x86_64_gnullvm 0.42.2", - "windows_x86_64_msvc 0.42.2", -] - -[[package]] -name = "windows-targets" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" -dependencies = [ - "windows_aarch64_gnullvm 0.52.6", - "windows_aarch64_msvc 0.52.6", - "windows_i686_gnu 0.52.6", - "windows_i686_gnullvm 0.52.6", - "windows_i686_msvc 0.52.6", - "windows_x86_64_gnu 0.52.6", - "windows_x86_64_gnullvm 0.52.6", - "windows_x86_64_msvc 0.52.6", -] - -[[package]] -name = "windows-targets" -version = "0.53.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3" -dependencies = [ - "windows-link 0.2.1", - "windows_aarch64_gnullvm 0.53.1", - "windows_aarch64_msvc 0.53.1", - "windows_i686_gnu 0.53.1", - "windows_i686_gnullvm 0.53.1", - "windows_i686_msvc 0.53.1", - "windows_x86_64_gnu 0.53.1", - "windows_x86_64_gnullvm 0.53.1", - "windows_x86_64_msvc 0.53.1", -] - -[[package]] -name = "windows-threading" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b66463ad2e0ea3bbf808b7f1d371311c80e115c0b71d60efc142cafbcfb057a6" -dependencies = [ - "windows-link 0.1.3", -] - -[[package]] -name = "windows-version" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4060a1da109b9d0326b7262c8e12c84df67cc0dbc9e33cf49e01ccc2eb63631" -dependencies = [ - "windows-link 0.2.1", -] - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "597a5118570b68bc08d8d59125332c54f1ba9d9adeedeef5b99b02ba2b0698f8" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9d8416fa8b42f5c947f8482c43e7d89e73a173cead56d044f6a56104a6d1b53" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e08e8864a60f06ef0d0ff4ba04124db8b0fb3be5776a5cd47641e942e58c4d43" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9d782e804c2f632e395708e99a94275910eb9100b2114651e04744e9b125006" - -[[package]] -name = "windows_i686_gnu" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c61d927d8da41da96a81f029489353e68739737d3beca43145c8afec9a31a84f" - -[[package]] -name = "windows_i686_gnu" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" - -[[package]] -name = "windows_i686_gnu" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "960e6da069d81e09becb0ca57a65220ddff016ff2d6af6a223cf372a506593a3" - -[[package]] -name = "windows_i686_gnullvm" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" - -[[package]] -name = "windows_i686_gnullvm" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa7359d10048f68ab8b09fa71c3daccfb0e9b559aed648a8f95469c27057180c" - -[[package]] -name = "windows_i686_msvc" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44d840b6ec649f480a41c8d80f9c65108b92d89345dd94027bfe06ac444d1060" - -[[package]] -name = "windows_i686_msvc" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" - -[[package]] -name = "windows_i686_msvc" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e7ac75179f18232fe9c285163565a57ef8d3c89254a30685b57d83a38d326c2" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8de912b8b8feb55c064867cf047dda097f92d51efad5b491dfb98f6bbb70cb36" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c3842cdd74a865a8066ab39c8a7a473c0778a3f29370b5fd6b4b9aa7df4a499" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26d41b46a36d453748aedef1486d5c7a85db22e56aff34643984ea85514e94a3" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ffa179e2d07eee8ad8f57493436566c7cc30ac536a3379fdf008f47f6bb7ae1" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9aec5da331524158c6d1a4ac0ab1541149c0b9505fde06423b02f5ef0106b9f0" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6bbff5f0aada427a1e5a6da5f1f98158182f26556f345ac9e04d36d0ebed650" - -[[package]] -name = "winnow" -version = "0.5.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" -dependencies = [ - "memchr", -] - -[[package]] -name = "winnow" -version = "0.7.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df79d97927682d2fd8adb29682d1140b343be4ac0f08fd68b7765d9c059d3945" - -[[package]] -name = "winnow" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23b97319f7b8343df12cc98938e5c3eb436064524c8d2b4e30a1d3a36eecdf81" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.55.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb5a765337c50e9ec252c2069be9bf91c7df47afb103b642ba3a53bf8101be97" -dependencies = [ - "cfg-if", - "windows-sys 0.59.0", -] - -[[package]] -name = "wit-bindgen" -version = "0.57.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e" - -[[package]] -name = "writeable" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ffae5123b2d3fc086436f8834ae3ab053a283cfac8fe0a0b8eaae044768a4c4" - -[[package]] -name = "wry" -version = "0.55.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "186f9871daa55fd9c016578b810d149de58367113db7fb72b462d2323ce19514" -dependencies = [ - "base64 0.22.1", - "block2", - "cookie", - "crossbeam-channel", - "dirs", - "dom_query", - "dpi", - "dunce", - "gdkx11", - "gtk", - "http", - "javascriptcore-rs", - "jni", - "libc", - "ndk", - "objc2", - "objc2-app-kit", - "objc2-core-foundation", - "objc2-foundation", - "objc2-ui-kit", - "objc2-web-kit", - "once_cell", - "percent-encoding", - "raw-window-handle", - "sha2", - "soup3", - "tao-macros", - "thiserror 2.0.19", - "url", - "webkit2gtk", - "webkit2gtk-sys", - "webview2-com", - "windows", - "windows-core 0.61.2", - "windows-version", - "x11-dl", -] - -[[package]] -name = "x11" -version = "2.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "502da5464ccd04011667b11c435cb992822c2c0dbde1770c988480d312a0db2e" -dependencies = [ - "libc", - "pkg-config", -] - -[[package]] -name = "x11-dl" -version = "2.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38735924fedd5314a6e548792904ed8c6de6636285cb9fec04d5b1db85c1516f" -dependencies = [ - "libc", - "once_cell", - "pkg-config", -] - -[[package]] -name = "yoke" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "709fe23a0424b6a435d82152b1bd3fdfb0833487d5fa90d05d42762a9891fef5" -dependencies = [ - "stable_deref_trait", - "yoke-derive", - "zerofrom", -] - -[[package]] -name = "yoke-derive" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de844c262c8848816172cef550288e7dc6c7b7814b4ee56b3e1553f275f1858e" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", - "synstructure", -] - -[[package]] -name = "zbus" -version = "5.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe18fb60dc696039e738717b76eaea21e7a4489bbb1885020b43c94236d7e98a" -dependencies = [ - "async-broadcast", - "async-executor", - "async-io", - "async-lock", - "async-process", - "async-recursion", - "async-task", - "async-trait", - "blocking", - "enumflags2", - "event-listener", - "futures-core", - "futures-lite", - "hex", - "libc", - "ordered-stream", - "rustix", - "serde", - "serde_repr", - "tracing", - "uds_windows", - "uuid", - "windows-sys 0.61.2", - "winnow 1.0.4", - "zbus_macros", - "zbus_names", - "zvariant", -] - -[[package]] -name = "zbus_macros" -version = "5.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe96480bed92df2b442a1a30df364e12d08eed03aeb061f2b8dc6afb2be91119" -dependencies = [ - "proc-macro-crate 3.5.0", - "proc-macro2", - "quote", - "syn 2.0.119", - "zbus_names", - "zvariant", - "zvariant_utils", -] - -[[package]] -name = "zbus_names" -version = "4.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8bf88b4a3ff53e883001e0e0115b297a9d53c31b9c1edd2bfdd853e3428624e" -dependencies = [ - "serde", - "winnow 1.0.4", - "zvariant", -] - -[[package]] -name = "zerofrom" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ec05a11813ea801ff6d75110ad09cd0824ddba17dfe17128ea0d5f68e6c5272" -dependencies = [ - "zerofrom-derive", -] - -[[package]] -name = "zerofrom-derive" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11532158c46691caf0f2593ea8358fed6bbf68a0315e80aae9bd41fbade684a1" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", - "synstructure", -] - -[[package]] -name = "zeroize" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e13c156562582aa81c60cb29407084cdb54c4164760106ab78e6c5b0858cf64e" - -[[package]] -name = "zerotrie" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f9152d31db0792fa83f70fb2f83148effb5c1f5b8c7686c3459e361d9bc20bf" -dependencies = [ - "displaydoc", - "yoke", - "zerofrom", -] - -[[package]] -name = "zerovec" -version = "0.11.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90f911cbc359ab6af17377d242225f4d75119aec87ea711a880987b18cd7b239" -dependencies = [ - "yoke", - "zerofrom", - "zerovec-derive", -] - -[[package]] -name = "zerovec-derive" -version = "0.11.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "625dc425cab0dca6dc3c3319506e6593dcb08a9f387ea3b284dbd52a92c40555" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - -[[package]] -name = "zmij" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b" - -[[package]] -name = "zvariant" -version = "5.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bee2a0bcd2a907786a456fff45aaaaf54c9ba5f50b71ae9ec1a4edd200c94911" -dependencies = [ - "endi", - "enumflags2", - "serde", - "winnow 1.0.4", - "zvariant_derive", - "zvariant_utils", -] - -[[package]] -name = "zvariant_derive" -version = "5.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38a708216a18780796770bfe3f4739c7c83a3e8f789b755534bbbc06e4e23e12" -dependencies = [ - "proc-macro-crate 3.5.0", - "proc-macro2", - "quote", - "syn 2.0.119", - "zvariant_utils", -] - -[[package]] -name = "zvariant_utils" -version = "3.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90cb9383f9b45290407a1258b202d3f8f01db719eb60b4e4055c6375af4fc7c7" -dependencies = [ - "proc-macro2", - "quote", - "serde", - "syn 2.0.119", - "winnow 1.0.4", -] diff --git a/builder/desktop/Cargo.toml b/builder/desktop/Cargo.toml deleted file mode 100644 index 9b9140dfa0..0000000000 --- a/builder/desktop/Cargo.toml +++ /dev/null @@ -1,75 +0,0 @@ -[package] -name = "obc-desktop" -version = "0.1.0" -edition = "2021" -publish = false # internal app crate — not published to crates.io -description = "OpenBikeComputer desktop app: the published-cell builder in a Tauri shell" - -# A standalone cargo root, like obc-fw-nrf54l and obc-boot — deliberately NOT a -# member of the root Cargo.toml. Tauri drags in wry and a platform webview -# (WebKitGTK on Linux, WebView2 on Windows), so joining the workspace would put a -# GUI toolkit and its system headers in the way of `cargo test` for the renderer. -# The cost is the usual one for an excluded crate: its own Cargo.lock, its own -# fmt/clippy/test invocations, and its own CI job — see the repo AGENTS.md and -# .github/workflows/ci.yml's `desktop` job. -[workspace] - -[features] -# Plain `cargo build` produces a shippable app rather than a dev-server shell. -default = ["custom-protocol"] - -# `tauri/custom-protocol` is what decides whether the app *is* an app: with it, -# `tauri::generate_context!` embeds the built frontend and the webview loads it -# over the `tauri://` protocol; without it, Tauri is in "dev" mode and points the -# window at `build.devUrl`. The Tauri templates leave it off and have their CLI -# add it for `tauri build` — which silently produces a blank window for anyone -# running plain `cargo run`, which is how this repo builds everything. -# -# So it is ON by default here, and the live-reload loop is the explicit opt-out: -# -# npm --prefix ../web run dev -- --mode desktop -# cargo run --no-default-features # follows Vite -custom-protocol = ["tauri/custom-protocol"] - -[build-dependencies] -# Generates the Tauri context (config + the embedded frontend bundle). -tauri-build = { version = "2", features = [] } - -[dependencies] -obc-usb = { path = "../usb" } -tauri = { version = "2", features = [] } -# Native USB (#909). Pure Rust: there is no C library to vendor, no CMake leg, -# and nothing for a user to install. It talks to each platform's own USB -# stack directly — usbfs on Linux, IOKit on macOS, WinUSB on Windows. -# -# `features = ["tokio"]` is load-bearing, not tuning. nusb wraps every blocking -# syscall in a `MaybeFuture`, and without a runtime feature the `.await` arm of -# that type is a `panic!` — it compiles on all three platforms and dies the first -# time anything is actually awaited. Tauri's runtime is tokio, so this is the -# arm to enable. See `usb::runtime_guard` for what stops it happening again. -nusb = { version = "0.2", features = ["tokio"] } -# `HotplugWatch` is a `futures_core::Stream`; this is the trait, and nothing else -# (futures-core has no dependencies of its own). -futures-core = "0.3" -# Tauri's async runtime is tokio, and these are the pieces the USB plane needs: -# `sync` for the per-endpoint mutexes and the cancel epochs, `macros` for the -# select! that makes a parked transfer cancellable, `fs` to read a map off the -# disk without blocking a runtime worker. -tokio = { version = "1", features = ["sync", "macros", "fs", "io-util"] } -# Used from Rust only (no JS permission needed): "show the file I just built" in -# the platform's own file manager. -tauri-plugin-opener = "2" -# The one place the *user* names a directory: relocating the ride library (E2 -# #912). Called from Rust, like the opener above, so `capabilities/default.json` -# stays at `core:default` and no JS gets a file-picker. That is also the crate's -# standing rule about paths, met rather than bent — the frontend still never -# names a place; here the OS's own chooser does, with the person driving it. -tauri-plugin-dialog = "2" -serde = { version = "1", features = ["derive"] } -serde_json = "1" -# Blocking HTTP for the small map catalog document. The caller runs on a worker -# thread, and rustls-by-default avoids an OpenSSL system dependency. -ureq = "3" -# Parses catalog/object URLs so the native fetch command can enforce same-origin -# access instead of handing the webview a general HTTP proxy. -url = "2" diff --git a/builder/desktop/README.md b/builder/desktop/README.md deleted file mode 100644 index 3e75854ea8..0000000000 --- a/builder/desktop/README.md +++ /dev/null @@ -1,150 +0,0 @@ -# obc-desktop - -The website's cell-catalog map builder in a Tauri v2 window. The Svelte coverage UI, digest -verification, corridor selection and wasm assembly engine are the same in both products. Rust -supplies native HTTPS, durable map-set output, USB and the ride library; it does not link -`obc-pack` and it does not process `.osm.pbf` files. - -## Setup - -| | | -|---|---| -| Rust | stable, via `rustup` | -| Node | 22+, for the embedded frontend | -| Linux only | WebKitGTK for `wry`: `libwebkit2gtk-4.1-dev libsoup-3.0-dev libjavascriptcoregtk-4.1-dev libgtk-3-dev librsvg2-dev` | - -No GEOS, CMake, libusb or Python dependency. `nusb` talks to each platform's native USB stack. - -USB on macOS and Windows needs no extra setup. On Linux: - -```sh -sudo cp linux/99-openbikecomputer.rules /etc/udev/rules.d/ -sudo udevadm control --reload-rules -sudo udevadm trigger -# unplug and reconnect the device -``` - -## Build and run - -Build the two wasm bridges and the desktop frontend first, then run the standalone Rust crate: - -```sh -cd builder/web -npm ci -npm run build:wasm -npm run build:desktop - -cd ../desktop -cargo run --release -``` - -`custom-protocol` is a default feature, so plain `cargo run` embeds `builder/web/dist/desktop`. -For the Vite live-reload loop: - -```sh -# terminal 1, from builder/desktop -npm --prefix ../web run dev -- --mode desktop - -# terminal 2 -cargo run --no-default-features -``` - -Packaged builds compile their catalog root from `OBC_CATALOG_URL`, which defaults to -`https://maps.openbikecomputer.com/cell-catalog/catalog.json`. A runtime variable of the same name -overrides it to test an unpublished catalog: - -```sh -OBC_CATALOG_URL=https://maps.example.test/catalog.json cargo run --release -``` - -Rust fetches the catalog root, every satellite and every cell. Object URLs must use the configured -root's HTTPS origin; loopback HTTP is allowed for local testing. The webview never gets a general -network proxy. - -## Basemap - -The region picker, ride library and route previews draw the same basemap from -`tiles.openbikecomputer.com`. Each map reads the active release from -`https://maps.openbikecomputer.com/planner/catalog.json` when it opens. The basemap needs WebGL2 -and shows detail only within the published tile coverage. If it cannot load, the map shows a -notice and keeps the selection or route overlays. It sends no tile requests to a third-party map -server. - -The webview loads tiles, fonts and symbols itself. The Content Security Policy in -`tauri.conf.json` names the two hosts. The asset host must list the app origin in its CORS rules: -`tauri://localhost` on macOS and Linux, `http://tauri.localhost` on Windows. - -## Test - -This is a standalone cargo root, like `obc-fw-nrf54l` and `obc-boot`, so it needs its own checks: - -```sh -cargo fmt -- --check -cargo check --release --locked -cargo clippy --release --locked --all-targets -- -D warnings -cargo test --release --locked -- --nocapture -``` - -The shared Svelte checks run from `builder/web`: `npm run check`, `npm test`, `npm run build:all`. - -### Linux release-launch test - -The manual suite `manual.desktop-linux-launch` opens the real window under Xvfb, checks its -`tauri://localhost` origin, searches for Switzerland and adds it to the map, against a loopback -catalog. CI does not run it. On a Linux host with no OBC device attached, build the release app -first, then from the repository root: - -```sh -sudo apt-get install webkit2gtk-driver xvfb imagemagick dbus-daemon -cargo install tauri-driver --version 2.0.6 --locked -xvfb-run -a dbus-run-session -- uv run --locked --group desktop-e2e python builder/desktop/e2e/launch.py -``` - -**Use a WebKit driver with the same version as the installed WebKitGTK runtime.** -`dbus-run-session` gives the app and the desktop portal services a private session bus with the -Xvfb display. - -`OBC_DESKTOP_BINARY` names an existing release executable. Evidence goes to -`target/desktop-launch`, or `OBC_DESKTOP_EVIDENCE`: `result.json`, native catalog request logs, -application and driver logs, rendered HTML and a screenshot, plus `failure.png` when a webview -session is available. - -The suite covers Linux software launch and catalog integration only: no USB permission, no -enumeration with a physical device and no route upload. Windows launch is not automated, and -Tauri's native WebDriver route does not support macOS. - -## Reference - -| | | -|---|---| -| Assembled maps | `~/Documents/OpenBikeComputer//` | -| Pulled rides (GPX) | `~/Documents/OpenBikeComputer/rides/` — relocatable | -| Ride archive | `/ride-archive/` — internal, not relocatable | - -Each completed assembly is a uniquely named folder. Files are written to `.part`, flushed and -atomically renamed before the assembly is reported complete. The website gets the same -worker-produced bytes through browser downloads. The visible ride folder holds GPX files only; -device ride objects and the index live in the internal archive, and `src/rides.rs` documents the -durable import and relocation rules. Catalog cells are held only for the assembly run: there is no -`.pbf`, land-polygon, Geofabrik-index or persistent cell cache. - -| | | -|---|---| -| `src/main.rs` | Tauri commands and the deliberately small webview capability surface | -| `src/catalog.rs`, `src/http.rs` | Configured catalog root and same-origin native object reads | -| `src/map_output.rs` | Opaque output sessions and atomic map-set writes | -| `src/storage.rs`, `src/paths.rs` | Visible app-owned locations | -| `src/rides.rs` | Managed GPX library plus the durable ride archive | -| `src/usb/` | Native USB discovery and byte pipes beneath the shared TypeScript protocol | - -The window has `core:default` and no filesystem, shell or HTTP plugin; Rust commands hold those -policies. `dragDropEnabled: false` in `tauri.conf.json` turns off Tauri's OS-level interception so -the shared HTML5 GPX drop targets get files. - -The device protocol is the shared TypeScript implementation in `builder/web/src/lib/usb/`; Rust -supplies the native pipes only. Large app-owned files stream from the maps folder without entering -the webview. A newly assembled volume set streams to the device with the manifest last. The device -page also accepts a standalone `.obcm` from elsewhere. - -There are no installers, signing or auto-update. There is no native arbitrary-file picker; files -selected in the webview use the ordinary chunked transfer path. diff --git a/builder/desktop/build.rs b/builder/desktop/build.rs deleted file mode 100644 index 261851f6b6..0000000000 --- a/builder/desktop/build.rs +++ /dev/null @@ -1,3 +0,0 @@ -fn main() { - tauri_build::build(); -} diff --git a/builder/desktop/capabilities/default.json b/builder/desktop/capabilities/default.json deleted file mode 100644 index 61c5f8d64b..0000000000 --- a/builder/desktop/capabilities/default.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "$schema": "../gen/schemas/desktop-schema.json", - "identifier": "default", - "description": "The app's own commands need no permission; this grants the core set the webview itself uses (window, event, IPC channels). Nothing here opens a filesystem, shell or HTTP capability to JavaScript — every one of those is a Rust command with the policy written in Rust, which is the reason the backend exists.", - "windows": ["main"], - "permissions": ["core:default"] -} diff --git a/builder/desktop/e2e/launch.py b/builder/desktop/e2e/launch.py deleted file mode 100644 index 81190fe337..0000000000 --- a/builder/desktop/e2e/launch.py +++ /dev/null @@ -1,138 +0,0 @@ -#!/usr/bin/env python3 -"""Launch the embedded Linux frontend and select a local catalog region.""" - -from contextlib import suppress -import json -import os -from pathlib import Path -import shlex -import signal -import socket -import subprocess -import sys -from tempfile import TemporaryDirectory -import traceback -from urllib.parse import urlsplit - -from selenium import webdriver -from selenium.webdriver.common.by import By -from selenium.webdriver.remote.client_config import ClientConfig -from selenium.webdriver.support import expected_conditions as EC -from selenium.webdriver.support.ui import WebDriverWait -from selenium.webdriver.webkitgtk.options import Options - -ROOT = Path(__file__).resolve().parents[3] -sys.path.insert(0, str(ROOT / "tools")) - -from fixture_catalog import CatalogServer, schema_examples # noqa: E402 — needs ROOT on the path - - -def main(): - if sys.platform != "linux": - raise SystemExit("The release-launch suite requires Linux and Xvfb.") - binary = Path(os.environ.get("OBC_DESKTOP_BINARY", ROOT / "builder/desktop/target/release/obc-desktop")).resolve() - evidence = Path(os.environ.get("OBC_DESKTOP_EVIDENCE", ROOT / "target/desktop-launch")).resolve() - evidence.mkdir(parents=True, exist_ok=True) - for name in ("result.json", "failure.png", "ready.png", "page.html", "driver.log", "application.log", "catalog.jsonl", "processes.txt"): - (evidence / name).unlink(missing_ok=True) - result = {"passed": False, "binary": str(binary)} - browser = process = server = None - objects = schema_examples() - - with TemporaryDirectory(prefix="obc-desktop-launch-") as scratch, (evidence / "driver.log").open("w") as driver_log: - try: - if not binary.is_file() or not os.access(binary, os.X_OK): - raise RuntimeError(f"Missing executable release app: {binary}") - server = CatalogServer(objects, log=evidence / "catalog.jsonl").start() - catalog_url = f"{server.origin}/catalog.json" - # WebKit launches this wrapper once. exec preserves its PID and captures Rust output. - wrapper = Path(scratch) / "application.sh" - pidfile = Path(scratch) / "application.pid" - wrapper.write_text("#!/bin/sh\n" + f"echo $$ > {shlex.quote(str(pidfile))}\n" + - f"exec > {shlex.quote(str(evidence / 'application.log'))} 2>&1\n" + - 'printf "automation=%s inspector=%s display=%s\\n" "$TAURI_WEBVIEW_AUTOMATION" "$WEBKIT_INSPECTOR_SERVER" "$DISPLAY"\n' + - f'exec {shlex.quote(str(binary))} "$@"\n') - wrapper.chmod(0o755) - environment = {**os.environ, "OBC_CATALOG_URL": catalog_url, "RUST_BACKTRACE": "1", - "XDG_DATA_HOME": scratch, "XDG_CONFIG_HOME": scratch, "XDG_CACHE_HOME": scratch} - process = subprocess.Popen(["tauri-driver"], env=environment, stdout=driver_log, - stderr=subprocess.STDOUT, start_new_session=True) - - def listening(_): - if process.poll() is not None: - raise RuntimeError("tauri-driver exited before readiness") - try: - with socket.create_connection(("127.0.0.1", 4444), timeout=1): - return True - except OSError: - return False - - WebDriverWait(None, 15).until(listening, "tauri-driver did not listen") - options = Options() - options.set_capability("browserName", "wry") - options.set_capability("tauri:options", {"application": str(wrapper)}) - browser = webdriver.Remote(command_executor="http://127.0.0.1:4444", options=options, - client_config=ClientConfig(remote_server_addr="http://127.0.0.1:4444", timeout=30)) - wait = WebDriverWait(browser, 30) - search = wait.until(EC.visibility_of_element_located((By.CSS_SELECTOR, '[aria-label="Search regions"]'))) - result["url"] = browser.current_url - origin = urlsplit(result["url"]) - if (origin.scheme, origin.netloc) != ("tauri", "localhost"): - raise AssertionError(f"Expected embedded custom-protocol frontend, got {result['url']}") - search.send_keys("Switzerland") - wait.until(EC.element_to_be_clickable((By.CSS_SELECTOR, '[aria-label="Add Switzerland (1.0 KB)"]'))).click() - wait.until(EC.visibility_of_element_located((By.CSS_SELECTOR, '[aria-label="Switzerland is already in the map"]'))) - wait.until(EC.text_to_be_present_in_element((By.CSS_SELECTOR, '.ledger .total'), "1.0 KB")) - if browser.find_elements(By.CSS_SELECTOR, '.catalog-error, .ledger .error, .parts .retry'): - raise AssertionError("Catalog or region resolution failed") - missing = set(objects) - set(server.requests) - if missing: - raise AssertionError(f"Native catalog requests missing: {sorted(missing)}") - result["region"] = "Switzerland" - result["price"] = browser.find_element(By.CSS_SELECTOR, '.ledger .total').text - result["capabilities"] = browser.capabilities - browser.save_screenshot(str(evidence / "ready.png")) - (evidence / "page.html").write_text(browser.page_source) - browser.quit() - browser = None - pid = int(pidfile.read_text()) - WebDriverWait(None, 10).until(lambda _: not Path(f"/proc/{pid}").exists(), "Application did not exit after session quit") - result["application_exited"] = True - if "panicked at" in (evidence / "application.log").read_text(): - raise AssertionError("The release app panicked") - result["passed"] = True - except Exception: - result["error"] = traceback.format_exc() - with suppress(Exception): - # A session can fail before WebDriver can capture the still-open app window. - subprocess.run(["import", "-window", "root", str(evidence / "failure.png")], - check=True, timeout=5) - (evidence / "processes.txt").write_text(subprocess.check_output( - ["ps", "-eo", "pid,ppid,stat,comm"], text=True, timeout=5)) - if browser: - with suppress(Exception): - browser.save_screenshot(str(evidence / "failure.png")) - (evidence / "page.html").write_text(browser.page_source) - raise - finally: - if browser: - with suppress(Exception): - browser.quit() - if process: - with suppress(ProcessLookupError): - os.killpg(process.pid, signal.SIGTERM) - try: - process.wait(timeout=5) - except subprocess.TimeoutExpired: - os.killpg(process.pid, signal.SIGKILL) - process.wait() - if server: - server.shutdown() - server.server_close() - result["requests"] = server.requests if server else [] - (evidence / "result.json").write_text(json.dumps(result, indent=2) + "\n") - print(json.dumps(result, indent=2)) - - -if __name__ == "__main__": - main() diff --git a/builder/desktop/icons/128x128.png b/builder/desktop/icons/128x128.png deleted file mode 100644 index 8152165d9296bc44a2d9f3388cf2d0bac9271e0c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4001 zcmV;S4_@$zP)%_*y4NeS>?Ie(zMlBT(3!4B%0uiKEB1+mSP!I|bXi@km zv=EhwRIM6CYATQ*1X>Zw9}p1`iXy;jl9Grd#i^lDSUYY^>?F>9@6OzNPXBn%ow+kR z>z)0YGdpu1X*@f3W<2NK_c_lw=Y8MvUd1XfHF37p;Sjh8xB~cH-~g~2xDY4<1t3_> z@AfbZFbhlrXMi!_81NYIgnM0S{!)2(+lqfst>jCK82)15&A<`hAg~iCcId+OI_7}W zz~jJ=fd_!65yI545+W>{08PdZfY$-<1O5nj6`*}ztvk1?fQM*Oh2;>TZ349D z^_K%50^S3xT!S*K2IIhez@5OufKA?LmjrDQpvm}~ft!F2BV&CA|2PYL1-JtlDuDJ# zup|MRjDHny8}Qb4zMG-r_)p+7z=P?7=Oe;-jhHgN0LW|9|Zmu81a2}8QQ`u@MWaK&L#(2k)Y*_y~+3=2mYSS_!|iY;M2etSYj!@ zfB;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k7QHd1uG0a7Z`A9KS6=Gg_@LGz)+p)=Azk?Fw+%4jRf-Gb8 zfDl53uIi_DJwLtMAl=UH+8@{j3Xo(4+2zTq3gm((y;0{~Pjt6z4@;0MQ?&y;^z);f ze&HN*k!GeUMxKjcK2}s>MJ1N1VUYo26p=A(*?Iwc-hBhb(N`>T3wfGm?deS|-DBXT z;F$mx^27Daprm|ySP)4KOLh6o4NLC}hb4@h91n`_^8=s<>k_R3ln$xRO!1TNk8xsb z8l^>P7VIooP$^8I8Y+Bshg`1*{1U(#7`Yr?|IcE)u;|9tl&mHdwp3bDo8#imJ+g6V z(A2krWoU$d1;~xS<}LJ+tZpRup9Et2?>+%t1P%1=0GDA&XkgZNBQp4d2Bv*CB7-*= z4V>}aiVWWHvIfR{w<3c#oYKHC->t~t4Nqy{F_3#FWaujx;86`c0i5>TnhYJs%fKVa z9N=-^t;x`F90!hRWLwUUeYYk<$MGO=E(ydx06govMHxDVao`6~uMhAv@FU-?%Fr5>QvaH4yl@CeeINq91pE^j2{tOeflTP9VWIJ1=}Muqz+WRo$U?>& z2QhFL@DbqL`98Sl;wZH$0LTIFN9F}R;Unl_Od@0c?WFQOTlIceVqbO>2|%1gw*d!z zpJj%YIF5AE?~qFOU(EQ>=EnRcB3uOA0^A6U_&(zdfOz=6jSSVbrQZ1rpP+63SQ7~X z;7!2Iz+s?I3;lRU1@Z0Q0o?Ci1ML|fmRXvk#gI?{4gog+*8rowuSlO@90}>(jRbZk z(r>nFd{|*^mKH?F0|$U>5k=SsY(9KPd-lkNvdJiozFw;aPKSk;E<7DNCT z0`>yG=N|ikUBDJHLbQv-;HQA6fJcExkQDv}%es{qKEeM3(B7@QQyG3c00000NkvXX Hu0mjf(^zBV diff --git a/builder/desktop/icons/128x128@2x.png b/builder/desktop/icons/128x128@2x.png deleted file mode 100644 index 2b13445fbeee6ef09fcaeae82bc29f6d71095fcd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 7903 zcmb`s_g9n86E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x8{ euE+Y9YV$uugPT((^GU=tps#JB)vVzd^M3%Xeqa>< diff --git a/builder/desktop/icons/32x32.png b/builder/desktop/icons/32x32.png deleted file mode 100644 index 2f1c11b7456fe3ae564cb3b47b92698159086f13..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1152 zcmV-`1b_R9P)NklL4;N*R9$2#V%1GuxDXL>p-?ye38F<@ zD>lKM2o^We7OSa=McRlaL^_$KP9~XjX5Kw6?tPP&%#X~(c;NDWpYy%vdw#s5iiI2z z*$cb^ya4P6Qf!T^0M~)9fphL002Kjn95@RM18R#5uNMJ+0p173qX3ROWc~k>;q{UO zUIoTgv5?yfd?)2+YX^CpJ0)XfFq*9qqRU8IR``Ccn zfO7>(f!n1q0q4(u#^mHBl!Ai?k1{%X2G8?51#!y9Mtf_+D>(>Oz)OM`2hl9#=a`+n zfe3W(yc+N#nJm=m)GwxbF_j9rxNwT`t60$q1U1QOkl z=&3W>vFNy^p?M560DwT|J{bA{22QNr>r@2r65zG2=8f}43?zHu(7O=pf|)TJkRpJw z$XyJGvt~k0Y6VIhfJ7~Q+XoPWi0^=h-h#ekP`(9~B2*WVa)GH|f1r4KmQ)P7yE63e z>Oq-1HeF5G9{n!RiA{JQ3c^c6?^D=VaQh9aeE0o7T={7MPs5SJBfR$9J9x@i!$HYr zPM8U7#sg6@>r%+lU<6D66%&KRPVnOnXqXW})AVZ-fU;>>+r6u7B6vzj_=2w?d8gz6$xib$ov%=FK!EX|YjVOuIr_x3I@ zcfeHa0_b@h4!i+79&TEaTa;oC@)zOan|4>VD(EVq@@f$;BI{H~C`b*!{V&6wlP(_C zil&wLY0$o-Rj-y<*8tM z9$N!Q+9eVxFztv~rWDZs3=F;v=>gXx+65rkBBB$3an!H6Q0p)|Tw>swmiBD}(lO|L z8Xi0YiEKmT8+ZWg{`4L&E4IgbY49_MmuBMk-Xjg+Vh9C$Cf}m65lc8}~I~@ZY08Rs^fPFx$6U{B83QPlIz$d`9@WH>uJ)qa) S{C-OS0000QC diff --git a/builder/desktop/icons/icon.icns b/builder/desktop/icons/icon.icns deleted file mode 100644 index 9537f6d4b7e7b2694e6ef54cd81e79c83c2b0dde..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 123390 zcmcG!by!qi^f!8D7+~lj1tf;<76hrGL!`S)KxvVZ8oC<LQlFf@30Q}7zzW*mEuOVFn09Z9jvQpY!p!H0n7^)u9Ftw4v z-#)cpmwN0`_AXGNP7i4!?)NRi1dIsYJTVZKvNby05zI@eFl3D`F)2+4iO=L!7)wb(s^K8*gY`_* zn&G1t*o7%Phd0<4_!puF$}MH$=kqFoTzMI4bM}+(MVi*3z5W;%2(e&_zaK5#{BdhS zQ&)h8k>t;_t-tF&Mtl?5ADM97SmyMWqLhCzC;xuvflUPVIP1=ol?MR+*yCTaT%g16aR0zAt`J z@O-;Kfnauenua6wLwL&1$3m=t;8e2`$>LudP~M!sKkI>1=$>@ZCcT-w4#;s}orr97 zROs~u#ixi*vj!E!!0%}i1~x6L5xzSRai9BV0@Iji6G(k=aGez!HGh{N=iJWz<`)`_ zJqlKM^aaGFCnWRquM{ZH#Kb@8O)d@Z?0w!$M-zkSx3sM~T)iu{re_m`!_$KsAa%)^?ha>5s`a(kgK>MY*3Sn8eDt>8Cl1sGZHI6B zWPG(snbc%MxS^RJ<;`5jfABki2wl5AAx6jGxhdzAdd^Ur@cBHQ5U{b?D4oe!tl#kD z&B;p28dqZOr^{7GZqeabHumh= zcL+WfW@#SJ$n>gjw9zDC{sD$dzQjaW^&R4x^`C8f+5|t!@r9+>v5|N@OuY|marqPk z3aGhRfs));Bo}=P1Ju9iAUAA4{_vi;mycxM*SryEOe!AlPS-RwMzO4;AzHCR0w=QS zZZS5!{0jXPD1p9?wX)lt+)8Rld(930F2{r1v<=HZukT6-C&9(WtZw&p$2J*H6sRE`sHxQ zl9Ms56naWI5cb_WLg4=UBV*!qN~U4Lo6qLYk3C&_s`$<~pXAglvyn_76B4`kJoEPU&~B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G5U z#>9vNh)3rmd9t_SXWA3fxOgan1~ROlbz=nyE3fZdbJsJDi{zGqMX zBy~^wd3$04l$1Kb2}lTLmQCy@C4$`07*CY1orDY8)x#5fvz7=z`JI$No%V8b4Z!d~ zu!{tztz2eS$J|2Q{yp%!&}&vUYcvWK5DmM_!O1VMW9M!g3Ex0(?~ct|xVG~0*_v4? zoOKJuoC4S16`hc9^>)EvZgca17)hqv+qOp|qM4&vtbJX4+?=-ZfuGz0TwMZOyix9Z z(Qaql&~Co2Zq}ZzDBtBe1$Xfg2+=HWghfQfPOa3meB;TLk8T*GnU#U3YXBg`1s!@@ zRQ#lwmH96MSh;sf>`~D$HnFg>ck%EGKNk}lmynorJ+-8)s=9{!qW%5QvYi1h*s@hw Meo3rc*8WcYAHef#`v3p{ diff --git a/builder/desktop/icons/icon.ico b/builder/desktop/icons/icon.ico deleted file mode 100644 index c2dbaabbc277e7ed8a2c6c2193d6cd0a4e1d0ac1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 285478 zcmeHw37k~bm3|wYac2HA6Mr+4`Nst5W~ZSWjboxw6EHDqG%?0xWCvLlQ9*G96kJ$E z;)a3?h$5SS3bKjFDvRv9$i6m9FD$o-SZEG}4d-c})&OP6` z=bn4+xj8xKhPavJAdkaGj}FT2e7J-IKa7<3^hq}--A+R~$R;dqDR-v$xy9Y8OD7JznxPJvh_ ze+Mb%l?OE~1Al?sodF#LeGYmPbPwoi(04%J0#(un>4CQNDMctA;n+o>Yd~z@XM@P& zuR%3k$NE0yc{DOWop2nq6f_Lgm2^S+ATTv00Z)Q;<3Hk90jM`lXgbxQmPP9$UKwB? zwFvY+s1@k{gR)8w1b;7nvtNH3Xe#I=C|(}x{mMfx$N+uRi$L8$-vec|9ti$E{Qeiv z&7kR^GLRSQOv|YClxP{CKWiDNGl>4ejMD=_-*i5H{|Gb|R18WqKlORaQ!mQEIbebQ zu3JI>3<~Ih)b-Nid$ao+{QIyjVwCX05km%K+QN(V#+5Kn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4TY&W)A(et^FQetp#$;N{zk;2#eJZP6YP+(*y%iG{riG+ISHV&$ZCjwiaiR?S}zb< zcK9Vg=|I^-0?PB&c7=yBuiT=%u1QEmrF}1M4Wn-N1pBD|8#3uHZvy1WO?RBQ40nFq z^i<`jvaykwJP>cYkH0W--O%!W%Y@Y%upk*mpJO@lD<`J{KEC2LIE%Hi=t8(i@l!cY zzEs?|eF4zW0&~tm$nnDH`PozCQ;!br0I4jgtxU9z?He-d_fS2BSnx@ol1onK!5xi8 z&rx<;^%#NeUIZJY0S1&dBFHm@hDD3?4=dGz&@fm#=PQIbhrU3lF7CLW0;t=Wl?*5v z=RnZnbOz7^R3?6^36gLvhzX%dIX2~lm_XoR)YeHCi@8fQn7ax*SB90igm6@VmTf5 z7>N7v`>PXXN(UkEx>>vS0r&4N5(rGnQ%P1#Hvizo1?~t%oFPsHRE;DLp3a2NnKZFu z=c1#@Tol28$?>k%qJvUS+lA%hReSIK@I!Ye9FPP+lYO;mxIytO%qhS*1@&mtsmtM5ct8GTs%`^ I = option_env!("OBC_CATALOG_URL"); - -/// The manifest body plus the URL it was read from. Relative references resolve against the -/// manifest's own location, and only this side knows it. -#[derive(Serialize)] -#[serde(rename_all = "camelCase")] -pub struct FetchedCatalog { - pub url: String, - pub body: String, -} - -pub fn url() -> String { - selected_url(std::env::var("OBC_CATALOG_URL").ok()) -} - -fn selected_url(runtime: Option) -> String { - runtime - .filter(|value| !value.trim().is_empty()) - .or_else(|| COMPILED_CATALOG_URL.filter(|value| !value.trim().is_empty()).map(str::to_owned)) - .unwrap_or_else(|| DEFAULT_CATALOG_URL.to_owned()) -} - -pub fn fetch() -> Result { - let url = url(); - let body = crate::http::get_text(&url).map_err(|e| format!("map catalog: {e}"))?; - Ok(FetchedCatalog { url, body }) -} - -#[cfg(test)] -mod tests { - use super::*; - - #[test] - fn the_catalog_url_is_absolute_and_overridable() { - // It must be absolute: the frontend resolves catalog references against it. - assert_eq!(selected_url(None), "https://maps.openbikecomputer.com/cell-catalog/catalog.json"); - assert_eq!( - selected_url(Some("https://example.invalid/catalog.json".into())), - "https://example.invalid/catalog.json" - ); - assert_ne!(selected_url(Some(String::new())), "", "an empty override must fall back"); - } -} diff --git a/builder/desktop/src/http.rs b/builder/desktop/src/http.rs deleted file mode 100644 index 37f6b33e1a..0000000000 --- a/builder/desktop/src/http.rs +++ /dev/null @@ -1,74 +0,0 @@ -//! The desktop app's small native network surface. Map selection, verification and assembly are -//! shared with the web builder; Rust moves the catalog bytes, because the Tauri webview has no -//! blanket network permission. - -use std::io::Read; -use std::sync::OnceLock; -use std::time::Duration; - -/// A cell is megabytes and a connection to a CDN edge can wedge half-open, and without a deadline -/// that read never returns. Sized for the largest object over a poor link: the point is to fail a -/// long stall, not to police a slow connection. -/// -/// Retrying is not done here. Every catalog object is digest-pinned, and the frontend's -/// `fetchVerified` owns that policy for both this host and the website. -const CONNECT_TIMEOUT: Duration = Duration::from_secs(15); -const RESPONSE_TIMEOUT: Duration = Duration::from_secs(30); -const BODY_TIMEOUT: Duration = Duration::from_secs(300); - -fn agent() -> &'static ureq::Agent { - static AGENT: OnceLock = OnceLock::new(); - AGENT.get_or_init(|| { - ureq::Agent::config_builder() - .timeout_connect(Some(CONNECT_TIMEOUT)) - .timeout_recv_response(Some(RESPONSE_TIMEOUT)) - .timeout_recv_body(Some(BODY_TIMEOUT)) - .build() - .into() - }) -} - -/// Read a small text document whole. -pub fn get_text(url: &str) -> Result { - let mut response = agent().get(url).call().map_err(|e| format!("GET {url}: {e}"))?; - response.body_mut().read_to_string().map_err(|e| format!("read {url}: {e}")) -} - -/// Read one digest-pinned catalog object. It is not a general HTTP proxy: every URL must share the -/// configured catalog root's origin. -pub fn get_catalog_object(url: &str) -> Result, String> { - same_catalog_origin(url, &crate::catalog::url())?; - let mut response = agent().get(url).call().map_err(|e| format!("GET {url}: {e}"))?; - let mut bytes = Vec::new(); - response.body_mut().as_reader().read_to_end(&mut bytes).map_err(|e| format!("read {url}: {e}"))?; - Ok(bytes) -} - -fn same_catalog_origin(requested: &str, catalog: &str) -> Result<(), String> { - let requested = url::Url::parse(requested).map_err(|e| format!("catalog object URL: {e}"))?; - let catalog = url::Url::parse(catalog).map_err(|e| format!("configured catalog URL: {e}"))?; - let local_http = - requested.scheme() == "http" && matches!(requested.host_str(), Some("localhost" | "127.0.0.1" | "::1")); - if requested.scheme() != "https" && !local_http { - return Err("catalog objects must use https (or loopback http for local testing)".into()); - } - if requested.origin() != catalog.origin() { - return Err(format!("catalog objects must stay on {}", catalog.origin().ascii_serialization())); - } - Ok(()) -} - -#[cfg(test)] -mod tests { - use super::*; - - #[test] - fn catalog_reads_are_https_and_same_origin() { - let root = "https://maps.example.test/prefix/catalog.json"; - assert!(same_catalog_origin("https://maps.example.test/prefix/cells/fine/index.json", root).is_ok()); - assert!(same_catalog_origin("https://other.example.test/cell.obcm", root).is_err()); - assert!(same_catalog_origin("http://maps.example.test/cell.obcm", root).is_err()); - assert!(same_catalog_origin("file:///tmp/cell.obcm", root).is_err()); - assert!(same_catalog_origin("http://127.0.0.1:8123/cell.obcm", "http://127.0.0.1:8123/catalog.json").is_ok()); - } -} diff --git a/builder/desktop/src/main.rs b/builder/desktop/src/main.rs deleted file mode 100644 index 06842624b3..0000000000 --- a/builder/desktop/src/main.rs +++ /dev/null @@ -1,224 +0,0 @@ -//! The OpenBikeComputer desktop app: the same published-cell map builder as the website, in a -//! Tauri shell with native storage and device access. -//! -//! It adds three things the webview cannot do itself: [`catalog`] fetches the published map -//! catalog, [`usb`] drives the device because the webview has no WebUSB, and [`rides`] keeps a -//! durable copy of a ride. -//! -//! The window is granted `core:default` and nothing else: no filesystem, no shell, no HTTP. Every -//! one of those policies is written in Rust, where it can be read, and catalog object reads are -//! restricted to the configured catalog origin. - -mod catalog; -mod http; -mod map_output; -mod paths; -mod rides; -mod usb; - -use std::sync::Arc; - -use tauri::Manager; - -/// The published cell catalog, body and base URL. -#[tauri::command] -async fn catalog() -> Result { - tauri::async_runtime::spawn_blocking(catalog::fetch).await.map_err(|e| e.to_string())? -} - -/// One catalog satellite or cell, restricted to the catalog root's origin. -#[tauri::command] -async fn catalog_get(url: String) -> Result { - let bytes = tauri::async_runtime::spawn_blocking(move || http::get_catalog_object(&url)) - .await - .map_err(|e| e.to_string())??; - Ok(tauri::ipc::Response::new(bytes)) -} - -#[tauri::command] -fn map_output_begin( - app: tauri::AppHandle, - outputs: tauri::State<'_, Arc>, - name: String, -) -> Result { - outputs.begin(&maps_dir(&app), &name) -} - -#[tauri::command] -async fn map_output_write( - outputs: tauri::State<'_, Arc>, - request: tauri::ipc::Request<'_>, -) -> Result { - let header = |name: &str| { - request - .headers() - .get(name) - .and_then(|value| value.to_str().ok()) - .ok_or_else(|| format!("a map output write is missing its `{name}` header")) - }; - let id: u64 = header("output-id")?.parse().map_err(|_| "a map output write has an invalid id".to_string())?; - let name = header("filename")?.to_owned(); - let tauri::ipc::InvokeBody::Raw(bytes) = request.body() else { - return Err("a map output write must carry raw bytes".into()); - }; - let bytes = bytes.clone(); - let outputs = outputs.inner().clone(); - tauri::async_runtime::spawn_blocking(move || outputs.write(id, &name, &bytes)).await.map_err(|e| e.to_string())? -} - -#[tauri::command] -async fn map_output_finish(outputs: tauri::State<'_, Arc>, id: u64) -> Result<(), String> { - let outputs = outputs.inner().clone(); - tauri::async_runtime::spawn_blocking(move || outputs.finish(id)).await.map_err(|e| e.to_string())? -} - -#[tauri::command] -async fn map_output_discard(outputs: tauri::State<'_, Arc>, id: u64) -> Result<(), String> { - let outputs = outputs.inner().clone(); - tauri::async_runtime::spawn_blocking(move || outputs.discard(id)).await.map_err(|e| e.to_string())? -} - -/// Where built maps go. Shown in the UI, so the user can act on it. -fn maps_dir(app: &tauri::AppHandle) -> std::path::PathBuf { - paths::maps_dir(app.path().document_dir().ok()) -} - -/// Show a produced file in the platform's file manager. -/// -/// Scoped to the folders this app owns: a webview can call this command, and revealing any path is -/// a wider door than the features need. The ride library is listed separately from the maps folder, -/// because a relocated library is not inside it. -#[tauri::command] -fn reveal_file(app: tauri::AppHandle, path: String) -> Result<(), String> { - let path = std::path::PathBuf::from(path); - let roots = [maps_dir(&app), ride_library(&app).0.root().to_path_buf()]; - if !roots.iter().any(|root| path.starts_with(root)) { - let names: Vec = roots.iter().map(|r| r.display().to_string()).collect(); - return Err(format!("only files under {} can be revealed", names.join(" or "))); - } - tauri_plugin_opener::reveal_item_in_dir(&path).map_err(|e| format!("reveal {}: {e}", path.display())) -} - -/// The library, and whether its visible GPX folder is the default one. -/// -/// Resolved per call rather than held in state: the folder can move while the app is running, and a -/// cached root would then be wrong exactly when a rider is looking at it. The archive lives in app -/// data and never moves. -fn ride_library(app: &tauri::AppHandle) -> (rides::Library, bool) { - let default = paths::rides_dir(app.path().document_dir().ok()); - let archive = paths::ride_archive_dir(app.path().app_data_dir().ok()); - let (root, is_default) = match app.path().app_config_dir().ok().and_then(|dir| rides::configured(&dir)) { - Some(chosen) if chosen != default => (chosen, false), - _ => (default, true), - }; - (rides::Library::new(root, archive), is_default) -} - -/// The library folder and everything in it. -#[tauri::command] -fn rides_index(app: tauri::AppHandle) -> rides::IndexView { - let (library, is_default) = ride_library(&app); - library.view(is_default) -} - -/// Land one pulled ride durably, and only then resolve. -/// -/// It lands the bytes with `fsync` before it resolves, so a ride the frontend believes it has is a -/// ride on this disk. A ride whose write failed rejects here and is absent from the durable index, -/// so a power cut costs at worst a re-download. -/// -/// It runs on the blocking pool, because `fsync` blocks. -#[tauri::command] -async fn rides_import(app: tauri::AppHandle, request: rides::ImportRequest) -> Result { - let (library, _) = ride_library(&app); - tauri::async_runtime::spawn_blocking(move || library.import(&request)).await.map_err(|e| e.to_string())? -} - -/// The stored ride object of one key, which a GPX re-export decodes. -#[tauri::command] -async fn rides_read(app: tauri::AppHandle, key: String) -> Result { - let (library, _) = ride_library(&app); - let bytes = - tauri::async_runtime::spawn_blocking(move || library.read_object(&key)).await.map_err(|e| e.to_string())??; - // The raw path, like `usb_read`: a ride object is hundreds of kilobytes and a JSON number - // array would be four times that in text. - Ok(tauri::ipc::Response::new(bytes)) -} - -/// Write one ride's GPX into the visible folder: the repair for a GPX somebody deleted, and the -/// fallback when the file to show is not there yet. -#[tauri::command] -async fn rides_write_gpx(app: tauri::AppHandle, key: String, gpx: String) -> Result { - let (library, _) = ride_library(&app); - tauri::async_runtime::spawn_blocking(move || library.write_gpx(&key, &gpx)).await.map_err(|e| e.to_string())? -} - -/// Let the rider pick a new home for the library, and move it there. -/// -/// The native chooser is opened from Rust, because the frontend names a file and never a place, and -/// the OS's own directory picker is the one way a person can name a place without the webview being -/// handed a filesystem. It answers `None` when the chooser was dismissed, which is an ordinary -/// outcome. -#[tauri::command] -async fn rides_choose_folder(app: tauri::AppHandle) -> Result, String> { - use tauri_plugin_dialog::DialogExt; - - let (library, _) = ride_library(&app); - let from = library.root().to_path_buf(); - let (tx, rx) = std::sync::mpsc::channel(); - app.dialog().file().set_title("Where should pulled rides be kept?").pick_folder(move |picked| { - let _ = tx.send(picked); - }); - // The chooser answers on the UI thread, so parking a blocking-pool thread on the reply keeps - // the event loop free to run it. - let picked = - tauri::async_runtime::spawn_blocking(move || rx.recv().ok().flatten()).await.map_err(|e| e.to_string())?; - let Some(picked) = picked else { return Ok(None) }; - let to = picked.into_path().map_err(|e| format!("that folder could not be used: {e}"))?; - - let config = app.path().app_config_dir().map_err(|e| format!("no config directory: {e}"))?; - let moved = to.clone(); - tauri::async_runtime::spawn_blocking(move || { - rides::relocate(&from, &moved)?; - rides::remember(&config, &moved) - }) - .await - .map_err(|e| e.to_string())??; - Ok(Some(to.display().to_string())) -} - -fn main() { - tauri::Builder::default() - .plugin(tauri_plugin_opener::init()) - // Registered for its Rust API only, which `rides_choose_folder` calls. No JS permission is - // granted, so the webview cannot open a picker of its own. - .plugin(tauri_plugin_dialog::init()) - .manage(Arc::new(usb::UsbState::default())) - .manage(Arc::new(map_output::Outputs::default())) - .invoke_handler(tauri::generate_handler![ - catalog, - catalog_get, - map_output_begin, - map_output_write, - map_output_finish, - map_output_discard, - reveal_file, - // The library is a folder plus an index, and the ack follows `rides_import`. - rides_index, - rides_import, - rides_read, - rides_write_gpx, - rides_choose_folder, - // Bytes only: the protocol lives once, in TypeScript, over these. - usb::usb_watch, - usb::usb_list, - usb::usb_open, - usb::usb_close, - usb::usb_read, - usb::usb_write, - usb::usb_cancel, - usb::usb_reset, - ]) - .run(tauri::generate_context!()) - .expect("run the OpenBikeComputer app"); -} diff --git a/builder/desktop/src/map_output.rs b/builder/desktop/src/map_output.rs deleted file mode 100644 index 7b9600042f..0000000000 --- a/builder/desktop/src/map_output.rs +++ /dev/null @@ -1,144 +0,0 @@ -//! Native landing place for verified assemblies. -//! -//! The wasm worker produces the same bytes in every host. The website hands each file to the -//! browser downloader; the desktop writes the files into one newly created folder under the maps -//! directory. An opaque id keeps the webview from turning this into a write-anywhere command. - -use std::collections::HashMap; -use std::io::Write; -use std::path::{Path, PathBuf}; -use std::sync::atomic::{AtomicU64, Ordering}; -use std::sync::Mutex; - -use serde::Serialize; - -#[derive(Serialize)] -#[serde(rename_all = "camelCase")] -pub struct Opened { - pub id: u64, - pub path: String, -} - -#[derive(Default)] -pub struct Outputs { - next: AtomicU64, - open: Mutex>, -} - -impl Outputs { - pub fn begin(&self, maps: &Path, name: &str) -> Result { - std::fs::create_dir_all(maps).map_err(|e| format!("{}: {e}", maps.display()))?; - let base = folder_name(name); - let path = (1..10_000) - .find_map(|n| { - let candidate = maps.join(if n == 1 { base.clone() } else { format!("{base}-{n}") }); - match std::fs::create_dir(&candidate) { - Ok(()) => Some(Ok(candidate)), - Err(e) if e.kind() == std::io::ErrorKind::AlreadyExists => None, - Err(e) => Some(Err(format!("{}: {e}", candidate.display()))), - } - }) - .ok_or_else(|| format!("{}: could not allocate an output folder", maps.display()))??; - let id = self.next.fetch_add(1, Ordering::Relaxed).wrapping_add(1); - self.open.lock().map_err(|_| "map output registry is poisoned".to_string())?.insert(id, path.clone()); - Ok(Opened { id, path: path.display().to_string() }) - } - - pub fn write(&self, id: u64, name: &str, bytes: &[u8]) -> Result { - let open = self.open.lock().map_err(|_| "map output registry is poisoned".to_string())?; - let root = open.get(&id).ok_or_else(|| "that map output session is not open".to_string())?; - write_file(root, name, bytes) - } - - pub fn finish(&self, id: u64) -> Result<(), String> { - self.take(id)?; - Ok(()) - } - - pub fn discard(&self, id: u64) -> Result<(), String> { - let mut open = self.open.lock().map_err(|_| "map output registry is poisoned".to_string())?; - let path = open.get(&id).ok_or_else(|| "that map output session is not open".to_string())?; - match std::fs::remove_dir_all(path) { - Ok(()) => {} - Err(e) if e.kind() == std::io::ErrorKind::NotFound => {} - Err(e) => return Err(format!("discard {}: {e}", path.display())), - } - open.remove(&id); - Ok(()) - } - - fn take(&self, id: u64) -> Result { - self.open - .lock() - .map_err(|_| "map output registry is poisoned".to_string())? - .remove(&id) - .ok_or_else(|| "that map output session is not open".into()) - } -} - -fn write_file(root: &Path, name: &str, bytes: &[u8]) -> Result { - validate_filename(name)?; - let final_path = root.join(name); - let part_path = root.join(format!(".{name}.part")); - let result = (|| { - let mut file = std::fs::OpenOptions::new() - .write(true) - .create_new(true) - .open(&part_path) - .map_err(|e| format!("{}: {e}", part_path.display()))?; - file.write_all(bytes).map_err(|e| format!("{}: {e}", part_path.display()))?; - file.sync_all().map_err(|e| format!("{}: {e}", part_path.display()))?; - std::fs::rename(&part_path, &final_path).map_err(|e| format!("{}: {e}", final_path.display())) - })(); - if result.is_err() { - let _ = std::fs::remove_file(&part_path); - } - result?; - Ok(final_path.display().to_string()) -} - -fn folder_name(name: &str) -> String { - let cleaned: String = - name.trim().chars().filter(|c| c.is_alphanumeric() || matches!(c, ' ' | '_' | '-')).take(80).collect(); - if cleaned.is_empty() { - "Map".into() - } else { - cleaned - } -} - -fn validate_filename(name: &str) -> Result<(), String> { - let safe = !name.is_empty() - && name != "." - && name != ".." - && name.chars().all(|c| c.is_ascii_alphanumeric() || matches!(c, '.' | '_' | '-')); - if safe { - Ok(()) - } else { - Err(format!("unsafe map output filename `{name}`")) - } -} - -#[cfg(test)] -mod tests { - use super::*; - - #[test] - fn an_output_is_grouped_and_cannot_escape() { - let maps = std::env::temp_dir().join(format!("obc-map-output-{}", std::process::id())); - let _ = std::fs::remove_dir_all(&maps); - let outputs = Outputs::default(); - let opened = outputs.begin(&maps, "Baden-Württemberg / tour").unwrap(); - let path = outputs.write(opened.id, "MS1.OBS", b"set").unwrap(); - assert!(Path::new(&path).starts_with(&maps)); - assert_eq!(std::fs::read(path).unwrap(), b"set"); - assert!(outputs.write(opened.id, "../escape", b"no").is_err()); - outputs.finish(opened.id).unwrap(); - assert!(outputs.write(opened.id, "MS1.OBS", b"late").is_err()); - let discarded = outputs.begin(&maps, "Discarded").unwrap(); - outputs.write(discarded.id, "MS1.OBS", b"partial").unwrap(); - outputs.discard(discarded.id).unwrap(); - assert!(!Path::new(&discarded.path).exists()); - let _ = std::fs::remove_dir_all(&maps); - } -} diff --git a/builder/desktop/src/paths.rs b/builder/desktop/src/paths.rs deleted file mode 100644 index c3ada6052e..0000000000 --- a/builder/desktop/src/paths.rs +++ /dev/null @@ -1,72 +0,0 @@ -//! Where the app keeps things. -//! -//! Two locations are visible to the user. Assembled maps go somewhere the user can find them: the -//! desktop tier exists because it has a real filesystem, and a build that landed in an opaque -//! app-support directory would be a download manager with extra steps. Pulled rides live beside -//! them in a relocatable GPX folder, with their durable archive in app data. - -use std::path::PathBuf; - -/// The visible output folder for built maps. -pub fn maps_dir(documents: Option) -> PathBuf { - documents.unwrap_or_else(home).join("OpenBikeComputer") -} - -/// The default home of the managed ride library, beside the maps, so one folder answers where this -/// app puts things and `reveal_file`'s rule covers it without widening. -/// -/// It is only the default. A rider whose rides belong on an external drive relocates it, and the -/// choice is remembered in the app's config directory: a folder that named itself could not be -/// found once it moved. -pub fn rides_dir(documents: Option) -> PathBuf { - maps_dir(documents).join("rides") -} - -/// The internal ride archive: the index plus the ride objects the library keeps behind the visible -/// GPX folder. It is app data and not user files, and it does not follow the GPX folder when the -/// rider moves it, because a store that follows another folder around is two ways to lose it. -/// -/// `app_data` is Tauri's per-app data directory. The fallback exists so a platform that cannot name -/// one still gets a deterministic, private location rather than a panic. -pub fn ride_archive_dir(app_data: Option) -> PathBuf { - app_data.unwrap_or_else(|| home().join(".openbikecomputer")).join("ride-archive") -} - -fn home() -> PathBuf { - #[cfg(windows)] - let var = "USERPROFILE"; - #[cfg(not(windows))] - let var = "HOME"; - std::env::var_os(var).map(PathBuf::from).unwrap_or_else(std::env::temp_dir) -} - -/// The same rule for any suffix: strip every path separator, keep only characters that mean nothing -/// to a shell or a filesystem, and force the extension. It is the reason a name typed into the -/// window cannot name a place. `fallback` is the stem used when nothing survives the filter. -pub fn sanitize_basename(name: &str, ext: &str, fallback: &str) -> String { - let base = name.trim().rsplit(['/', '\\']).next().unwrap_or(""); - let mut cleaned: String = - base.chars().filter(|c| c.is_alphanumeric() || matches!(c, '.' | '_' | '-' | ' ')).collect(); - cleaned = cleaned.trim().to_string(); - if cleaned.is_empty() || cleaned == ext { - cleaned = fallback.to_string(); - } - if !cleaned.ends_with(ext) { - cleaned.push_str(ext); - } - cleaned -} - -#[cfg(test)] -mod tests { - use super::*; - - #[test] - fn the_same_rule_forces_any_other_suffix() { - assert_eq!(sanitize_basename("bikepacking", ".json", "style"), "bikepacking.json"); - assert_eq!(sanitize_basename("../../.ssh/config", ".json", "style"), "config.json"); - assert_eq!(sanitize_basename("", ".json", "style"), "style.json"); - assert_eq!(sanitize_basename(".json", ".json", "style"), "style.json"); - assert_eq!(sanitize_basename("obcm-style-default.json", ".json", "style"), "obcm-style-default.json"); - } -} diff --git a/builder/desktop/src/rides.rs b/builder/desktop/src/rides.rs deleted file mode 100644 index a80656e5c6..0000000000 --- a/builder/desktop/src/rides.rs +++ /dev/null @@ -1,1144 +0,0 @@ -//! Durable desktop ride library. [`Library::import`] returns only after it has flushed -//! the ride object, GPX, and index in that order. -//! -//! ```text -//! / rider-owned, relocatable GPX files -//! 2026-07-20-schauinsland.gpx -//! -//! /ride-archive/ internal, fixed-location archive -//! index.json -//! 2026-07-20-schauinsland.obcride -//! ``` -//! -//! The lossless `.obcride` copy makes GPX re-export possible. Identity is -//! `(serial, store_id, id)` because object ids can be reused after a card change. - -use std::fs::File; -use std::io::{self, Write}; -use std::path::{Path, PathBuf}; -use std::sync::{Mutex, MutexGuard}; -use std::time::{SystemTime, UNIX_EPOCH}; - -use serde::{Deserialize, Serialize}; - -/// Serializes imports and relocation so temp names and index updates cannot interleave. -static LIBRARY_LOCK: Mutex<()> = Mutex::new(()); - -fn lock() -> MutexGuard<'static, ()> { - // A panic while holding the lock poisons it; the disk state is still governed by the - // rename-last discipline, so the next operation may simply proceed. - LIBRARY_LOCK.lock().unwrap_or_else(|poisoned| poisoned.into_inner()) -} - -/// The index's filename. It is readable JSON on purpose: it is the record a person can open and -/// read. -pub const INDEX_FILE: &str = "index.json"; -/// Bumped only when an older index can no longer be read. An unreadable index is not fatal: it -/// re-imports and never deletes. -const INDEX_VERSION: u32 = 2; -/// The stored ride object's extension, chosen so it cannot be mistaken for a GPX. -const RIDE_EXT: &str = "obcride"; -const GPX_EXT: &str = "gpx"; - -/// Largest ride object this command accepts. It is a ceiling and not an expectation: it is roughly -/// ten days of continuous recording, and it exists because a Tauri command is a door. -const MAX_RIDE_BYTES: usize = 16 * 1024 * 1024; -/// The GPX is the same track as text, five to six times the object, so its ceiling keeps the same -/// margin. -const MAX_GPX_BYTES: usize = 128 * 1024 * 1024; -/// Preview tracks are drawn a few hundred pixels wide, so more points than this would be index -/// weight nobody can see. The frontend downsamples to it and this is the enforcement. -const MAX_TRACK_POINTS: usize = 512; -/// Longest filename stem the library will mint, before its extension. -const MAX_STEM: usize = 64; - -/// The pointer file that remembers a relocated library. It lives in the app's config directory: a -/// folder that named itself could not be found once it moved. -const LOCATION_FILE: &str = "ride-library.json"; - -/// One ride in the library, as `index.json` stores it. -/// -/// It holds only facts that stay true: no absolute paths, because the GPX folder can move, and no -/// existence, because a person can delete a GPX in the file manager. Those are [`RideEntry`]'s, -/// recomputed on every read. -#[derive(Serialize, Deserialize, Clone, Debug, PartialEq)] -#[serde(rename_all = "camelCase")] -pub struct LibraryRide { - /// `serial:storeId:objectId`, minted here and never taken from the caller. - pub key: String, - pub serial: String, - #[serde(deserialize_with = "deserialize_store_id")] - pub store_id: String, - #[serde(serialize_with = "serialize_object_id", deserialize_with = "deserialize_object_id")] - pub object_id: u64, - pub name: String, - /// Ride start, unix seconds UTC. `0` on a device that never had a trusted clock. - pub start_time: u32, - pub distance_m: u32, - pub moving_time_s: u32, - pub climb_m: u32, - pub points: u32, - /// Length of the stored ride object, bytes. - pub bytes: u64, - /// The device's whole-object CRC-32, kept so the stored copy can be re-checked without the - /// device. - pub crc32: u32, - /// When this app first landed the ride, unix seconds. Never re-stamped, so a second pull is a - /// no-op, which matches the first-ack-wins rule on the device. - pub imported_at: u64, - /// Basename of the archived ride object, in the archive directory. - pub ride_file: String, - /// Basename of the GPX, in the visible folder. - pub gpx_file: String, - /// A downsampled `[lat, lon]` track for the list's preview, in degrees, drawn from the ride's - /// own points. - pub track: Vec<[f64; 2]>, -} - -/// One ride as the UI reads it: the stored record plus what only the filesystem can say. -/// -/// The two extra pairs are recomputed on every read and never written down. `present` means the -/// archive file exists: a ride whose object is gone is not a durable copy, so it is not acked and -/// it is pulled again. A missing GPX is only a re-export away, because the archive is its source. -#[derive(Serialize, Clone, Debug)] -#[serde(rename_all = "camelCase")] -pub struct RideEntry { - #[serde(flatten)] - pub ride: LibraryRide, - pub ride_path: String, - pub gpx_path: String, - pub present: bool, - pub gpx_present: bool, -} - -/// So an entry reads as the ride it describes. The wrapper adds facts about the filesystem; it is -/// not a different kind of thing. -impl std::ops::Deref for RideEntry { - type Target = LibraryRide; - - fn deref(&self) -> &LibraryRide { - &self.ride - } -} - -/// The index file's whole body. -#[derive(Serialize, Deserialize, Clone, Debug, Default)] -struct Index { - version: u32, - rides: Vec, -} - -/// What the UI is handed: where the visible folder is, and what is in the library. -#[derive(Serialize, Clone, Debug)] -#[serde(rename_all = "camelCase")] -pub struct IndexView { - pub folder: String, - /// True when the folder is the app's default rather than one the user picked. - pub is_default: bool, - pub rides: Vec, -} - -/// One ride, as the pull hands it over. The bytes and the GPX both cross the IPC boundary here. -/// -/// A ride is orders of magnitude smaller than the maps and firmware images that need the raw-body -/// path in [`crate::usb`], and the GPX beside it is text, so a structured command with a stated -/// ceiling is the cheaper thing to review. -#[derive(Deserialize, Clone, Debug)] -#[serde(rename_all = "camelCase")] -pub struct ImportRequest { - pub serial: String, - #[serde(deserialize_with = "deserialize_store_id")] - pub store_id: String, - #[serde(deserialize_with = "deserialize_object_id")] - pub object_id: u64, - pub name: String, - pub start_time: u32, - pub distance_m: u32, - pub moving_time_s: u32, - pub climb_m: u32, - /// Points in the recorded track, from the caller's decode of the object. This crate has no - /// ride-object decoder and must not grow one: the codecs live once, in `lib/usb/objects.ts`. - pub points: u32, - pub crc32: u32, - pub track: Vec<[f64; 2]>, - /// The ride object exactly as it came off the wire. - pub object: Vec, - /// The GPX 1.1 document, from the same `obc_route::track_to_gpx` the device runs. There is no - /// GPX writer in this crate and there must never be one. - pub gpx: String, -} - -/// [`Library::import`]'s answer. `imported` is false when the ride was already in the library, -/// which is the idempotent case and must not re-stamp anything. -#[derive(Serialize, Clone, Debug)] -#[serde(rename_all = "camelCase")] -pub struct Imported { - pub ride: RideEntry, - pub imported: bool, -} - -/// Where a durable write is interrupted. -/// -/// Production constructs a [`Library`] with [`CrashPoint::None`], and nothing outside this module -/// can ask for anything else. The other variants exist so the rule that the ack follows the fsync -/// is checked by running the real code with the power cut at a chosen instant. -#[derive(Clone, Copy, Debug, Default, PartialEq, Eq)] -pub enum CrashPoint { - #[default] - None, - /// The bytes reached `write()` and the process died before `fsync`: the case that decides - /// whether this feature can lose a ride. - BeforeObjectFsync, - /// The ride's two files are durable and the process died before the index committed. - BeforeIndexCommit, -} - -/// The message a simulated crash returns, so a test can tell it from a real IO error. -const CRASH_MSG: &str = "simulated power loss"; - -pub struct Library { - /// The visible, relocatable GPX folder. - root: PathBuf, - /// The internal archive: `index.json` plus the ride objects. It is app data, so it does not - /// move when the rider moves the GPX folder. - archive: PathBuf, - crash: CrashPoint, -} - -impl Library { - pub fn new(root: PathBuf, archive: PathBuf) -> Self { - Library { root, archive, crash: CrashPoint::None } - } - - /// A library that dies at `crash`. Test-only by construction, not by convention. - #[cfg(test)] - fn crashing_at(root: PathBuf, archive: PathBuf, crash: CrashPoint) -> Self { - Library { root, archive, crash } - } - - pub fn root(&self) -> &Path { - &self.root - } - - /// The index as it is on disk right now, with existence recomputed per ride. - /// - /// A missing index is an empty library, and so is a corrupt one. That is the safe direction: - /// the worst it costs is re-downloading rides the device still holds, while salvaging a - /// half-parsed index risks writing over the files it half-understood. - fn load(&self) -> Index { - read_index(&self.archive.join(INDEX_FILE)) - .unwrap_or_else(|| Index { version: INDEX_VERSION, rides: Vec::new() }) - } - - /// A stored record, joined to the filesystem as it is right now. - fn entry(&self, ride: LibraryRide) -> RideEntry { - let ride_path = self.archive.join(&ride.ride_file); - let gpx_path = self.root.join(&ride.gpx_file); - // Existence alone is not durability. `present` feeds the ack, so a truncated or swapped - // archive file must read as absent: the ride is then pulled again, which costs a download - // instead of a ride. The index's own `bytes` is the cheap whole-file check; hashing every - // archive on every read would make listing a library cost its size. - let present = std::fs::metadata(&ride_path).is_ok_and(|m| m.is_file() && m.len() == ride.bytes); - RideEntry { - present, - gpx_present: gpx_path.is_file(), - ride_path: ride_path.display().to_string(), - gpx_path: gpx_path.display().to_string(), - ride, - } - } - - fn entries(&self) -> Vec { - self.load().rides.into_iter().map(|ride| self.entry(ride)).collect() - } - - pub fn view(&self, is_default: bool) -> IndexView { - let _guard = lock(); - IndexView { folder: self.root.display().to_string(), is_default, rides: self.entries() } - } - - /// Land one pulled ride durably. Idempotent on its `(serial, store_id, id)` key. - /// - /// It returns only after the ride object, the GPX and the index have each been fsynced. The - /// caller may ack after this resolves and at no earlier point. - pub fn import(&self, req: &ImportRequest) -> Result { - let _guard = lock(); - if req.serial.is_empty() { - return Err("this device reports no serial number, so a ride from it cannot be keyed".into()); - } - validate_store_id(&req.store_id)?; - if req.object_id == 0 { - return Err("objectId zero names no object".into()); - } - if req.object.is_empty() { - return Err("that ride object is empty".into()); - } - if req.object.len() > MAX_RIDE_BYTES { - return Err(format!("that ride object is {} bytes; the limit is {MAX_RIDE_BYTES}", req.object.len())); - } - if req.gpx.is_empty() { - return Err("that ride converted to an empty GPX".into()); - } - if req.gpx.len() > MAX_GPX_BYTES { - return Err(format!("that GPX is {} bytes; the limit is {MAX_GPX_BYTES}", req.gpx.len())); - } - if req.track.len() > MAX_TRACK_POINTS { - return Err(format!("a preview track carries at most {MAX_TRACK_POINTS} points")); - } - - std::fs::create_dir_all(&self.root).map_err(|e| format!("create {}: {e}", self.root.display()))?; - std::fs::create_dir_all(&self.archive).map_err(|e| format!("create {}: {e}", self.archive.display()))?; - let mut index = self.load(); - let key = ride_key(&req.serial, &req.store_id, req.object_id); - - // The idempotent path: everything is already here, so nothing is written or re-stamped. - if let Some(existing) = index.rides.iter().find(|r| r.key == key) { - let entry = self.entry(existing.clone()); - if entry.present && entry.gpx_present { - return Ok(Imported { ride: entry, imported: false }); - } - } - - let existing = index.rides.iter().position(|r| r.key == key); - let (ride_file, gpx_file, imported_at) = match existing { - // A repair: the record survived and a file did not. Keep the names and the original - // `imported_at`, because this is the same ride arriving again. - Some(at) => { - let r = &index.rides[at]; - (r.ride_file.clone(), r.gpx_file.clone(), r.imported_at) - } - None => { - let stem = unique_stem(&index, &self.root, &self.archive, &key, &stem_for(req))?; - (format!("{stem}.{RIDE_EXT}"), format!("{stem}.{GPX_EXT}"), now_secs()) - } - }; - - // Order is the contract: the lossless object, then the portable GPX, then the index that - // claims both. A crash at any point leaves an index that does not name this ride. - durable_write(&self.archive, &ride_file, &req.object, self.crash_at(CrashPoint::BeforeObjectFsync)) - .map_err(|e| format!("write {}: {e}", self.archive.join(&ride_file).display()))?; - durable_write(&self.root, &gpx_file, req.gpx.as_bytes(), CrashPoint::None) - .map_err(|e| format!("write {}: {e}", self.root.join(&gpx_file).display()))?; - - let ride = LibraryRide { - key: key.clone(), - serial: req.serial.clone(), - store_id: req.store_id.clone(), - object_id: req.object_id, - name: req.name.clone(), - start_time: req.start_time, - distance_m: req.distance_m, - moving_time_s: req.moving_time_s, - climb_m: req.climb_m, - points: req.points, - bytes: req.object.len() as u64, - crc32: req.crc32, - imported_at, - ride_file, - gpx_file, - track: req.track.clone(), - }; - - match existing { - Some(at) => index.rides[at] = ride.clone(), - None => index.rides.push(ride.clone()), - } - if self.crash == CrashPoint::BeforeIndexCommit { - return Err(format!("{CRASH_MSG} before the index committed")); - } - self.commit(&index)?; - Ok(Imported { ride: self.entry(ride), imported: existing.is_none() }) - } - - /// The stored ride object of one key, which is what a re-export reads. - pub fn read_object(&self, key: &str) -> Result, String> { - let _guard = lock(); - let ride = self.find(key)?; - std::fs::read(self.archive.join(&ride.ride_file)) - .map_err(|e| format!("read {}: {e}", self.archive.join(&ride.ride_file).display())) - } - - /// Write one ride's GPX durably into the visible folder: the repair for a GPX somebody deleted - /// or renamed. The archived object is the source, so it can always be run again. - pub fn write_gpx(&self, key: &str, gpx: &str) -> Result { - let _guard = lock(); - if gpx.is_empty() || gpx.len() > MAX_GPX_BYTES { - return Err(format!("a GPX of {} bytes is outside 1..={MAX_GPX_BYTES}", gpx.len())); - } - let ride = self.find(key)?; - std::fs::create_dir_all(&self.root).map_err(|e| format!("create {}: {e}", self.root.display()))?; - durable_write(&self.root, &ride.gpx_file, gpx.as_bytes(), CrashPoint::None) - .map_err(|e| format!("write {}: {e}", self.root.join(&ride.gpx_file).display()))?; - Ok(self.root.join(&ride.gpx_file).display().to_string()) - } - - fn find(&self, key: &str) -> Result { - self.load().rides.into_iter().find(|r| r.key == key).ok_or_else(|| format!("no ride {key} in this library")) - } - - /// Rewrite the index durably, through its own temp and rename, so a crash mid-write leaves the - /// previous index whole and loses only the last ride's record. - fn commit(&self, index: &Index) -> Result<(), String> { - let body = serde_json::to_vec_pretty(index).map_err(|e| format!("encode {INDEX_FILE}: {e}"))?; - durable_write(&self.archive, INDEX_FILE, &body, CrashPoint::None) - .map_err(|e| format!("write {}: {e}", self.archive.join(INDEX_FILE).display())) - } - - fn crash_at(&self, point: CrashPoint) -> CrashPoint { - if self.crash == point { - point - } else { - CrashPoint::None - } - } -} - -/// Read and parse an index file. `None` means missing or unreadable, and the caller decides what -/// that means. -fn read_index(path: &Path) -> Option { - let bytes = std::fs::read(path).ok()?; - match serde_json::from_slice::(&bytes) { - Ok(index) if index.version == INDEX_VERSION => Some(index), - Ok(_) => None, - Err(e) => { - eprintln!("ride library: {} is unreadable ({e}); treating it as empty", path.display()); - None - } - } -} - -/// Move one file into `dir/name` so that no point of interruption loses it: `rename` on the same -/// volume, otherwise copy, fsync, atomic rename into place, and only then unlink the source. The -/// copy path makes a cross-filesystem move as safe as a same-volume one. -fn move_file_durably(source: &Path, dir: &Path, name: &str) -> Result<(), String> { - if std::fs::rename(source, dir.join(name)).is_ok() { - return sync_dir(dir).map_err(|e| format!("sync {}: {e}", dir.display())); - } - let bytes = std::fs::read(source).map_err(|e| format!("read {}: {e}", source.display()))?; - durable_write(dir, name, &bytes, CrashPoint::None) - .map_err(|e| format!("write {}: {e}", dir.join(name).display()))?; - std::fs::remove_file(source).map_err(|e| format!("remove {}: {e}", source.display())) -} - -/// Shared with `lib/device/rides.ts`: full StoreId hex and decimal u64 ObjectId. -pub fn ride_key(serial: &str, store_id: &str, object_id: u64) -> String { - format!("{serial}:{store_id}:{object_id}") -} - -fn validate_store_id(value: &str) -> Result<(), String> { - if value.len() == 32 && value.bytes().all(|b| b.is_ascii_digit() || (b'a'..=b'f').contains(&b)) { - Ok(()) - } else { - Err("storeId must contain exactly 32 lowercase hexadecimal digits".into()) - } -} - -fn deserialize_store_id<'de, D: serde::Deserializer<'de>>(deserializer: D) -> Result { - let value = String::deserialize(deserializer)?; - validate_store_id(&value).map_err(serde::de::Error::custom)?; - Ok(value) -} - -fn serialize_object_id(value: &u64, serializer: S) -> Result { - serializer.collect_str(value) -} - -fn deserialize_object_id<'de, D: serde::Deserializer<'de>>(deserializer: D) -> Result { - let text = String::deserialize(deserializer)?; - let value = text.parse::().map_err(serde::de::Error::custom)?; - if value == 0 || text != value.to_string() { - return Err(serde::de::Error::custom("objectId must be a canonical nonzero decimal u64 string")); - } - Ok(value) -} - -/// Write `bytes` to `dir/name` so that a power cut cannot leave a half-file behind. -/// -/// Four steps, none of them optional. The write goes into a `.part` sibling, so the destination -/// keeps its previous contents for the whole write. `sync_all` puts the bytes and the inode on the -/// disk; on macOS Rust's std implements it as `F_FULLFSYNC`, which also flushes the drive's own -/// write cache, where plain `fsync` does not. The `rename` is atomic on every filesystem this app -/// runs on, so a reader sees the old file or the new one. The directory fsync makes that rename -/// durable; skipping it is the classic failure where the data survives and the name does not. -/// -/// A real IO failure cleans its `.part` up. A [`CrashPoint`] does not, because the point of -/// simulating a power cut is to leave the mess a power cut leaves. -fn durable_write(dir: &Path, name: &str, bytes: &[u8], crash: CrashPoint) -> io::Result<()> { - let tmp = dir.join(format!(".{name}.part")); - let result = write_and_sync(&tmp, bytes, crash); - if result.is_err() { - if crash == CrashPoint::None { - let _ = std::fs::remove_file(&tmp); - } - return result; - } - std::fs::rename(&tmp, dir.join(name))?; - sync_dir(dir) -} - -fn write_and_sync(tmp: &Path, bytes: &[u8], crash: CrashPoint) -> io::Result<()> { - let mut file = File::create(tmp)?; - file.write_all(bytes)?; - if crash != CrashPoint::None { - // The process dies here. The bytes are in the page cache, the rename never happened, and - // nothing above this line told anyone the ride was safe. - return Err(io::Error::new(io::ErrorKind::Interrupted, format!("{CRASH_MSG} before fsync"))); - } - file.sync_all() -} - -/// fsync the directory entry, so the rename itself survives a power cut. -/// -/// Unix opens the directory read-only and fsyncs the handle. Windows has no equivalent and does not -/// need one: `File::open` on a directory fails without `FILE_FLAG_BACKUP_SEMANTICS`, and NTFS -/// records a rename in its metadata log, which is committed before `MoveFileEx` returns, so the -/// file's own flush is the whole requirement there. -#[cfg(unix)] -fn sync_dir(dir: &Path) -> io::Result<()> { - File::open(dir)?.sync_all() -} - -#[cfg(not(unix))] -fn sync_dir(_dir: &Path) -> io::Result<()> { - Ok(()) -} - -/// `YYYY-MM-DD-some-ride-name`, or just the name when the device had no clock. -/// -/// The date leads because a folder sorts by name and rides are read in order. It is UTC, matching -/// the ride object's `start_time`: rendering it locally would file a late-evening ride under the -/// wrong day for anyone west of Greenwich. -fn stem_for(req: &ImportRequest) -> String { - let name = crate::paths::sanitize_basename(&req.name, "", "ride"); - let mut stem = match utc_date(req.start_time) { - Some(date) => format!("{date}-{name}"), - None => name, - }; - if stem.len() > MAX_STEM { - // On a char boundary: a stem is a filename, and half a UTF-8 sequence is not one. - let cut = (0..=MAX_STEM).rev().find(|&n| stem.is_char_boundary(n)).unwrap_or(0); - stem.truncate(cut); - } - stem.trim().trim_end_matches(['.', '-']).to_string() -} - -/// A stem unclaimed by the index or either folder, including files from an unreadable index. -fn unique_stem(index: &Index, root: &Path, archive: &Path, key: &str, base: &str) -> Result { - let taken = |candidate: &str| { - let ride_file = format!("{candidate}.{RIDE_EXT}"); - let gpx_file = format!("{candidate}.{GPX_EXT}"); - index.rides.iter().any(|r| r.ride_file == ride_file || r.gpx_file == gpx_file) - || archive.join(ride_file).exists() - || root.join(gpx_file).exists() - }; - let base = if base.is_empty() { "ride" } else { base }; - if !taken(base) { - return Ok(base.to_string()); - } - let with_id = format!("{base}-{}", key.rsplit(':').next().unwrap_or("0")); - if !taken(&with_id) { - return Ok(with_id); - } - (2..10_000) - .map(|n| format!("{with_id}-{n}")) - .find(|candidate| !taken(candidate)) - .ok_or_else(|| "no unused ride filename is available".into()) -} - -/// `YYYY-MM-DD` in UTC, or `None` for a device whose clock was never set. -/// -/// Civil-from-days arithmetic, because a date is fifteen lines and a date library is a dependency. -/// Valid for every timestamp a `u32` can hold. -fn utc_date(start_time: u32) -> Option { - if start_time == 0 { - return None; - } - let days = (start_time / 86_400) as i64; - let z = days + 719_468; - let era = z.div_euclid(146_097); - let doe = z.rem_euclid(146_097); - let yoe = (doe - doe / 1460 + doe / 36_524 - doe / 146_096) / 365; - let y = yoe + era * 400; - let doy = doe - (365 * yoe + yoe / 4 - yoe / 100); - let mp = (5 * doy + 2) / 153; - let d = doy - (153 * mp + 2) / 5 + 1; - let m = if mp < 10 { mp + 3 } else { mp - 9 }; - let y = if m <= 2 { y + 1 } else { y }; - Some(format!("{y:04}-{m:02}-{d:02}")) -} - -fn now_secs() -> u64 { - SystemTime::now().duration_since(UNIX_EPOCH).map(|d| d.as_secs()).unwrap_or(0) -} - -#[derive(Serialize, Deserialize)] -struct Location { - dir: String, -} - -/// The folder the user relocated the library to, if they did. -/// -/// A folder that no longer exists is not replaced by the default: the app would then start a second -/// library on an unplugged external drive and report nothing missing. The caller surfaces it. -pub fn configured(config_dir: &Path) -> Option { - let bytes = std::fs::read(config_dir.join(LOCATION_FILE)).ok()?; - let location: Location = serde_json::from_slice(&bytes).ok()?; - let dir = PathBuf::from(location.dir); - (!dir.as_os_str().is_empty()).then_some(dir) -} - -/// Remember a relocated library. Durable, because forgetting where the rides went is its own kind -/// of data loss. -pub fn remember(config_dir: &Path, dir: &Path) -> Result<(), String> { - std::fs::create_dir_all(config_dir).map_err(|e| format!("create {}: {e}", config_dir.display()))?; - let body = serde_json::to_vec_pretty(&Location { dir: dir.display().to_string() }) - .map_err(|e| format!("encode {LOCATION_FILE}: {e}"))?; - durable_write(config_dir, LOCATION_FILE, &body, CrashPoint::None) - .map_err(|e| format!("write {}: {e}", config_dir.join(LOCATION_FILE).display())) -} - -/// Move the visible library, the GPX files, to a new folder. -/// -/// The internal archive stays in app data. Existing destination files are never replaced. -/// Cross-filesystem moves copy and flush before unlinking the source, and the caller updates the -/// configured location only after success. -pub fn relocate(from: &Path, to: &Path) -> Result<(), String> { - let _guard = lock(); - if from == to { - return Ok(()); - } - if to.starts_with(from) || from.starts_with(to) { - return Err("pick a folder that is not inside the current one".into()); - } - std::fs::create_dir_all(to).map_err(|e| format!("create {}: {e}", to.display()))?; - if !from.exists() { - return Ok(()); - } - - let entries = std::fs::read_dir(from).map_err(|e| format!("read {}: {e}", from.display()))?; - let mut names: Vec = entries - .flatten() - .filter(|entry| entry.path().is_file()) - .filter_map(|entry| entry.file_name().to_str().map(str::to_owned)) - .filter(|name| !name.starts_with('.') && Path::new(name).extension().is_some_and(|e| e == GPX_EXT)) - .collect(); - names.sort(); - - // Two passes: the first discovers a collision before anything has moved, and the second - // re-checks per file, because `rename` clobbers and std has no portable no-clobber rename. The - // re-check narrows the race to the one rename; a file another program drops into that window - // can still be lost. The library lock rules out this process racing itself. - for name in &names { - if to.join(name).exists() { - return Err(format!("{} already contains a file named {name} — pick another folder", to.display())); - } - } - for name in &names { - if to.join(name).exists() { - return Err(format!("{} now contains a file named {name} — nothing further was moved", to.display())); - } - move_file_durably(&from.join(name), to, name)?; - } - sync_dir(to).map_err(|e| format!("sync {}: {e}", to.display()))?; - let _ = sync_dir(from); - // Best effort: an empty folder left behind is untidy and a failed move is not. A folder that - // still holds the rider's other files stays. - let _ = std::fs::remove_dir(from); - Ok(()) -} - -#[cfg(test)] -mod tests { - /// The ack set, as a test helper: which rides are durably on this disk. It is a filter over - /// `view()`'s entries, and the tests below are about that property. - fn durable_ids(lib: &Library, serial: &str, store_id: u128) -> Vec { - let mut ids: Vec = lib - .view(false) - .rides - .into_iter() - .filter(|e| e.present && e.ride.serial == serial && e.ride.store_id == format!("{store_id:032x}")) - .map(|e| e.ride.object_id) - .collect(); - ids.sort_unstable(); - ids.dedup(); - ids - } - - use super::*; - - fn temp(tag: &str) -> PathBuf { - let dir = std::env::temp_dir().join(format!( - "obc-rides-{tag}-{}-{:?}", - std::process::id(), - std::time::SystemTime::now().duration_since(UNIX_EPOCH).unwrap().subsec_nanos() - )); - std::fs::create_dir_all(&dir).expect("temp dir"); - dir - } - - /// A library over a visible folder and an internal archive: the production shape, in a - /// sandbox. - fn library(base: &Path) -> Library { - Library::new(base.join("rides"), base.join("archive")) - } - - fn request(serial: &str, store_id: u128, id: u64, name: &str) -> ImportRequest { - ImportRequest { - serial: serial.into(), - store_id: format!("{store_id:032x}"), - object_id: id, - name: name.into(), - start_time: 1_764_547_200, // 2025-12-01 - distance_m: 42_195, - moving_time_s: 7_200, - climb_m: 640, - points: 4_211, - crc32: 0xdead_beef, - track: vec![[48.0, 7.85], [48.01, 7.86]], - object: format!("ride-object-{name}-{id}").into_bytes(), - gpx: format!("{name}"), - } - } - - fn file_names(dir: &Path) -> Vec { - let mut names: Vec = std::fs::read_dir(dir) - .map(|entries| entries.flatten().filter_map(|e| e.file_name().to_str().map(str::to_owned)).collect()) - .unwrap_or_default(); - names.sort(); - names - } - - #[test] - fn a_second_import_of_the_same_ride_writes_nothing_and_re_stamps_nothing() { - let base = temp("idem"); - let lib = library(&base); - let req = request("OBC-24-000317", 0xa1b2c3d4, 7, "Dawn Patrol"); - - let first = lib.import(&req).expect("first import"); - assert!(first.imported, "the first pull lands the ride"); - let stamp = first.ride.imported_at; - let archive = base.join("archive"); - let ride_mtime = std::fs::metadata(archive.join(&first.ride.ride_file)).unwrap().modified().unwrap(); - - let second = lib.import(&req).expect("second import"); - assert!(!second.imported, "the second pull is a no-op, not a duplicate"); - assert_eq!(second.ride.imported_at, stamp, "imported_at is first-import-wins, like synced_at"); - assert_eq!(second.ride.key, first.ride.key); - assert_eq!( - std::fs::metadata(archive.join(&first.ride.ride_file)).unwrap().modified().unwrap(), - ride_mtime, - "the ride file was not rewritten" - ); - assert_eq!(lib.load().rides.len(), 1, "one record, not two"); - assert_eq!(durable_ids(&lib, "OBC-24-000317", 0xa1b2c3d4), vec![7]); - - let _ = std::fs::remove_dir_all(&base); - } - - /// The visible folder holds GPX and nothing else; the archive holds the object and the - /// index. - #[test] - fn an_import_leaves_only_gpx_in_the_visible_folder() { - let base = temp("split"); - let lib = library(&base); - let landed = lib.import(&request("S", 1, 1, "Split")).expect("import"); - - assert_eq!(file_names(&base.join("rides")), vec![landed.ride.gpx_file.clone()]); - let mut archived = vec![INDEX_FILE.to_string(), landed.ride.ride_file.clone()]; - archived.sort(); - assert_eq!(file_names(&base.join("archive")), archived); - assert!(landed.ride.ride_path.starts_with(base.join("archive").to_str().unwrap())); - assert!(landed.ride.gpx_path.starts_with(base.join("rides").to_str().unwrap())); - - let _ = std::fs::remove_dir_all(&base); - } - - /// The power goes out between `write()` and `fsync()`. The real `import` runs, and what is - /// checked is what a restart then sees, because that is what the ack list is computed from. The - /// ride must be absent from it, so the device is never told and the next pull fetches it - /// again. - #[test] - fn a_crash_between_write_and_fsync_leaves_the_ride_unacked() { - let base = temp("crash"); - let good = request("OBC-24-000317", 7, 1, "Landed"); - let lost = request("OBC-24-000317", 7, 2, "Interrupted"); - - library(&base).import(&good).expect("the first ride lands"); - - let err = Library::crashing_at(base.join("rides"), base.join("archive"), CrashPoint::BeforeObjectFsync) - .import(&lost) - .expect_err("a crash before fsync must not report success"); - assert!(err.contains(CRASH_MSG), "unexpected failure: {err}"); - - // Restart: a new Library over the same folders, reading the index a relaunched app would - // read. - let restarted = library(&base); - assert_eq!( - durable_ids(&restarted, "OBC-24-000317", 7), - vec![1], - "only the fsynced ride is ackable; the interrupted one is not" - ); - assert!( - !base.join("archive").join(format!("2025-12-01-Interrupted.{RIDE_EXT}")).exists(), - "nothing was committed under the destination name" - ); - assert_eq!(restarted.load().rides.len(), 1, "the index never learned about the lost ride"); - - // The next pull, with the power on, lands it and only then makes it ackable. - library(&base).import(&lost).expect("the retry lands"); - assert_eq!(durable_ids(&library(&base), "OBC-24-000317", 7), vec![1, 2]); - - let _ = std::fs::remove_dir_all(&base); - } - - /// The other half of the ordering: the files are durable and the index never committed. The - /// ride is still not ackable, and the retry repairs the record without minting a second one. - #[test] - fn a_crash_before_the_index_commits_also_leaves_the_ride_unacked() { - let base = temp("crash-index"); - let req = request("OBC-24-000317", 7, 3, "Half landed"); - - Library::crashing_at(base.join("rides"), base.join("archive"), CrashPoint::BeforeIndexCommit) - .import(&req) - .expect_err("crash"); - let restarted = library(&base); - assert!(durable_ids(&restarted, "OBC-24-000317", 7).is_empty(), "an uncommitted index acks nothing"); - assert!(base.join("archive").join(format!("2025-12-01-Half landed.{RIDE_EXT}")).exists(), "the bytes did land"); - - let retry = restarted.import(&req).expect("the retry commits"); - assert!(retry.imported); - assert_eq!(restarted.load().rides.len(), 1, "the retry did not mint a second record"); - - let _ = std::fs::remove_dir_all(&base); - } - - /// Card identities that share their first 32 bits must keep recycled object ids distinct. - #[test] - fn a_card_change_with_a_recycled_id_keeps_both_rides() { - let base = temp("store_id"); - let lib = library(&base); - let serial = "OBC-24-000317"; - - let old = - lib.import(&request(serial, 0xa1b2c3d4_00000000_00000000_00000000, 1, "Old era ride")).expect("old era"); - let new = - lib.import(&request(serial, 0xa1b2c3d4_00000000_00000000_00000001, 1, "New era ride")).expect("new era"); - - assert!(old.imported && new.imported, "the recycled id is a different ride, not a duplicate"); - assert_ne!(old.ride.key, new.ride.key); - assert_ne!(old.ride.ride_file, new.ride.ride_file, "and it gets its own file"); - assert_eq!(lib.load().rides.len(), 2); - - // Each era acks only its own ids. The old era's record is archival: it names a ride the - // device no longer has, and nothing in the new era may claim it. - assert_eq!(durable_ids(&lib, serial, 0xa1b2c3d4_00000000_00000000_00000000), vec![1]); - assert_eq!(durable_ids(&lib, serial, 0xa1b2c3d4_00000000_00000000_00000001), vec![1]); - // A different device with the same id is a third ride again. - assert!(durable_ids(&lib, "OBC-24-000999", 0xa1b2c3d4_00000000_00000000_00000001).is_empty()); - - let _ = std::fs::remove_dir_all(&base); - } - - /// What the device is told matches what is on the disk, including after something deletes an - /// archive file, which `present` must notice. - #[test] - fn durable_ids_follow_the_filesystem_not_the_index() { - let base = temp("present"); - let lib = library(&base); - let serial = "OBC-24-000317"; - for id in [4u64, 5, 6] { - lib.import(&request(serial, 9, id, &format!("Ride {id}"))).expect("import"); - } - assert_eq!(durable_ids(&lib, serial, 9), vec![4, 5, 6]); - - let gone = lib.load().rides.iter().find(|r| r.object_id == 5).expect("ride 5").ride_file.clone(); - std::fs::remove_file(base.join("archive").join(&gone)).expect("delete the archive file"); - - assert_eq!(durable_ids(&lib, serial, 9), vec![4, 6], "a deleted ride is not durable and is not acked"); - let listed = lib.entries(); - assert_eq!(listed.len(), 3, "the record survives so the UI can say the file is missing"); - assert!(!listed.iter().find(|r| r.object_id == 5).unwrap().present); - - let _ = std::fs::remove_dir_all(&base); - } - - #[test] - fn a_missing_gpx_is_repaired_without_re_downloading_the_ride() { - let base = temp("regpx"); - let lib = library(&base); - let landed = lib.import(&request("S", 1, 8, "Export me")).expect("import"); - std::fs::remove_file(base.join("rides").join(&landed.ride.gpx_file)).expect("delete the gpx"); - assert!(!lib.entries()[0].gpx_present); - - let object = lib.read_object(&landed.ride.key).expect("the archive is still there"); - assert_eq!(object, request("S", 1, 8, "Export me").object); - lib.write_gpx(&landed.ride.key, "rebuilt").expect("re-export"); - assert!(lib.entries()[0].gpx_present); - assert_eq!( - std::fs::read_to_string(base.join("rides").join(&landed.ride.gpx_file)).unwrap(), - "rebuilt" - ); - - let _ = std::fs::remove_dir_all(&base); - } - - #[test] - fn a_corrupt_index_reads_as_empty_rather_than_as_nonsense() { - let base = temp("corrupt"); - let lib = library(&base); - lib.import(&request("S", 1, 1, "A ride")).expect("import"); - std::fs::write(base.join("archive").join(INDEX_FILE), b"{ this is not json").expect("corrupt it"); - - assert!(lib.load().rides.is_empty(), "an unreadable index is an empty library"); - assert!(durable_ids(&lib, "S", 1).is_empty(), "and acks nothing — the safe direction"); - // The files are still there, so the next pull re-imports over them. - assert!(lib.import(&request("S", 1, 1, "A ride")).expect("re-import").imported); - - let _ = std::fs::remove_dir_all(&base); - } - - #[test] - fn two_rides_that_want_the_same_filename_get_different_ones() { - let base = temp("stems"); - let lib = library(&base); - let a = lib.import(&request("S", 1, 11, "Commute")).expect("a"); - let b = lib.import(&request("S", 1, 12, "Commute")).expect("b"); - assert_ne!(a.ride.ride_file, b.ride.ride_file); - assert_eq!(a.ride.ride_file, format!("2025-12-01-Commute.{RIDE_EXT}")); - assert_eq!(b.ride.ride_file, format!("2025-12-01-Commute-12.{RIDE_EXT}")); - let _ = std::fs::remove_dir_all(&base); - } - - #[test] - fn a_ride_name_can_never_name_a_place() { - let req = request("S", 1, 1, "../../.ssh/authorized_keys"); - let stem = stem_for(&req); - assert!(!stem.contains('/') && !stem.contains('\\') && !stem.contains(".."), "{stem}"); - assert_eq!(stem, "2025-12-01-authorized_keys"); - assert_eq!(stem_for(&request("S", 1, 1, "")), "2025-12-01-ride"); - } - - #[test] - fn dates_are_utc_and_absent_when_the_device_had_no_clock() { - assert_eq!(utc_date(0), None); - assert_eq!(utc_date(1).as_deref(), Some("1970-01-01")); - assert_eq!(utc_date(1_764_547_200).as_deref(), Some("2025-12-01")); - assert_eq!(utc_date(1_767_225_599).as_deref(), Some("2025-12-31")); - assert_eq!(utc_date(1_767_225_600).as_deref(), Some("2026-01-01")); - // A leap day, and the last instant a u32 can hold. - assert_eq!(utc_date(1_709_164_800).as_deref(), Some("2024-02-29")); - assert_eq!(utc_date(u32::MAX).as_deref(), Some("2106-02-07")); - } - - #[test] - fn the_key_uses_full_store_hex_and_decimal_u64() { - let store = "a1b2c3d4000000000000000000000000"; - for id in [65536, 9007199254740993, u64::MAX] { - assert_eq!(ride_key("OBC-24-000317", store, id), format!("OBC-24-000317:{store}:{id}")); - } - assert_eq!(ride_key("a:b", store, 2), "a:b:a1b2c3d4000000000000000000000000:2"); - } - - fn json_request() -> serde_json::Value { - serde_json::json!({ - "serial": "OBC-24-000317", - "storeId": "a1b2c3d4000000000000000000000000", - "objectId": "65536", - "name": "Same name", - "startTime": 1764547200_u32, - "distanceM": 42195, - "movingTimeS": 7200, - "climbM": 640, - "points": 1, - "crc32": 0, - "track": [], - "object": [1, 2, 3], - "gpx": "" - }) - } - - #[test] - fn json_identity_survives_import_reload_and_duplicate_detection() { - let base = temp("full-identity"); - for store in ["a1b2c3d4000000000000000000000000", "a1b2c3d4000000000000000000000001"] { - for id in ["65536", "9007199254740993", "18446744073709551615"] { - let mut json = json_request(); - json["storeId"] = store.into(); - json["objectId"] = id.into(); - let req: ImportRequest = serde_json::from_value(json).expect("JSON request"); - let landed = library(&base).import(&req).expect("import"); - assert!(landed.imported); - assert_eq!(landed.ride.key, format!("OBC-24-000317:{store}:{id}")); - let reply = serde_json::to_value(&landed).expect("JSON response"); - assert_eq!(reply["ride"]["storeId"], store); - assert_eq!(reply["ride"]["objectId"], id); - assert!(!library(&base).import(&req).expect("reload and repeat").imported); - } - } - let rides = library(&base).view(false).rides; - assert_eq!(rides.len(), 6); - assert!(rides.iter().all(|r| r.present && r.gpx_present)); - let _ = std::fs::remove_dir_all(base); - } - - #[test] - fn malformed_json_identity_is_refused_before_file_creation() { - let base = temp("invalid-identity"); - for field in ["storeId", "objectId"] { - let invalid = if field == "storeId" { - vec![ - serde_json::json!(7), - serde_json::json!(null), - "".into(), - "a1b2c3d4".into(), - "A1B2C3D4000000000000000000000000".into(), - "g1b2c3d4000000000000000000000000".into(), - ] - } else { - vec![ - serde_json::json!(65536), - serde_json::json!(null), - "".into(), - "0".into(), - "-1".into(), - "+1".into(), - "01".into(), - "1.0".into(), - "1e3".into(), - "18446744073709551616".into(), - ] - }; - for value in invalid { - let mut json = json_request(); - json[field] = value; - assert!(serde_json::from_value::(json).is_err(), "invalid {field}"); - } - } - let mut req = request("S", 1, 1, "Bad card"); - req.store_id = "invalid".into(); - assert!(library(&base).import(&req).is_err()); - assert!(file_names(&base).is_empty()); - let _ = std::fs::remove_dir_all(base); - } - - #[test] - fn an_old_index_never_overwrites_archived_objects_or_gpx() { - let base = temp("old-index"); - let req = request("S", 1, 1, "Same name"); - let old = library(&base).import(&req).unwrap(); - let object_path = PathBuf::from(&old.ride.ride_path); - let gpx_path = PathBuf::from(&old.ride.gpx_path); - let mut index: serde_json::Value = - serde_json::from_slice(&std::fs::read(base.join("archive").join(INDEX_FILE)).unwrap()).unwrap(); - index["version"] = 1.into(); - index["rides"][0].as_object_mut().unwrap().remove("storeId"); - index["rides"][0]["epoch"] = 1.into(); - index["rides"][0]["objectId"] = 1.into(); - std::fs::write(base.join("archive").join(INDEX_FILE), serde_json::to_vec(&index).unwrap()).unwrap(); - assert!(library(&base).view(false).rides.is_empty()); - let mut new_req = req.clone(); - new_req.object = b"different ride".to_vec(); - new_req.gpx = "different ride".into(); - let new = library(&base).import(&new_req).unwrap(); - assert!(new.imported); - assert_ne!(new.ride.ride_path, old.ride.ride_path); - assert_ne!(new.ride.gpx_path, old.ride.gpx_path); - assert_eq!(std::fs::read(object_path).unwrap(), req.object); - assert_eq!(std::fs::read_to_string(gpx_path).unwrap(), req.gpx); - let _ = std::fs::remove_dir_all(base); - } - - #[test] - fn oversized_and_empty_imports_are_refused_before_anything_is_written() { - let base = temp("limits"); - let lib = library(&base); - let mut req = request("S", 1, 1, "Huge"); - req.object = vec![0; MAX_RIDE_BYTES + 1]; - assert!(lib.import(&req).is_err()); - let mut req = request("S", 1, 1, "Empty"); - req.object.clear(); - assert!(lib.import(&req).is_err()); - let mut req = request("", 1, 1, "No serial"); - req.serial.clear(); - assert!(lib.import(&req).is_err(), "a device with no serial cannot key a ride"); - assert!(lib.load().rides.is_empty(), "nothing was written"); - let _ = std::fs::remove_dir_all(&base); - } - - /// `present` is not bare existence: a truncated archive file must read as not durable, drop out - /// of the ack list, and be repaired by the next pull. - #[test] - fn a_truncated_archive_is_not_durable_and_is_repaired() { - let base = temp("truncated"); - let lib = library(&base); - let landed = lib.import(&request("S", 1, 4, "Torn")).expect("import"); - assert_eq!(durable_ids(&lib, "S", 1), vec![4]); - - let path = base.join("archive").join(&landed.ride.ride_file); - let whole = std::fs::read(&path).expect("read"); - std::fs::write(&path, &whole[..whole.len() / 2]).expect("truncate"); - - assert!(durable_ids(&lib, "S", 1).is_empty(), "a torn file acks nothing"); - assert!(!lib.entries()[0].present, "…and the UI sees it as missing"); - - let repaired = lib.import(&request("S", 1, 4, "Torn")).expect("the next pull repairs it"); - assert!(!repaired.imported, "the same ride arriving again, not a new one"); - assert_eq!(durable_ids(&lib, "S", 1), vec![4]); - assert_eq!(std::fs::read(&path).expect("whole again"), whole); - - let _ = std::fs::remove_dir_all(&base); - } - - // Relocation. - - #[test] - fn relocating_moves_the_gpx_files_and_only_them() { - let base = temp("move"); - let from = base.join("old"); - let to = base.join("new"); - - let lib = Library::new(from.clone(), base.join("archive")); - let landed = lib.import(&request("S", 1, 1, "Travelling")).expect("import"); - - assert!(relocate(&from, &from.join("inside")).is_err(), "a move into itself is not a move"); - - relocate(&from, &to).expect("relocate"); - let moved = Library::new(to.clone(), base.join("archive")); - assert_eq!(durable_ids(&moved, "S", 1), vec![1], "the archive did not move, so nothing was lost"); - assert!(to.join(&landed.ride.gpx_file).is_file()); - assert!(moved.entries()[0].gpx_present); - assert!(!from.exists(), "the old folder is gone once it is empty"); - - // Moving into a folder the app has never used works, and a second relocate from an already - // moved source is a no-op rather than an error. - relocate(&from, &base.join("third")).expect("nothing to move"); - - let _ = std::fs::remove_dir_all(&base); - } - - #[test] - fn relocating_refuses_to_overwrite_a_same_named_file() { - let base = temp("move-collide"); - let from = base.join("old"); - let to = base.join("new"); - let lib = Library::new(from.clone(), base.join("archive")); - let landed = lib.import(&request("S", 1, 1, "Collides")).expect("import"); - std::fs::create_dir_all(&to).expect("to"); - std::fs::write(to.join(&landed.ride.gpx_file), b"someone else's file").expect("occupy"); - - assert!(relocate(&from, &to).is_err(), "an existing file is never overwritten"); - assert!(from.join(&landed.ride.gpx_file).is_file(), "and the source did not move"); - - let _ = std::fs::remove_dir_all(&base); - } - - #[test] - fn the_configured_location_survives_a_restart() { - let base = temp("location"); - let config = base.join("config"); - assert_eq!(configured(&config), None); - remember(&config, &base.join("rides")).expect("remember"); - assert_eq!(configured(&config), Some(base.join("rides"))); - let _ = std::fs::remove_dir_all(&base); - } -} diff --git a/builder/desktop/src/usb/mod.rs b/builder/desktop/src/usb/mod.rs deleted file mode 100644 index b587f7a166..0000000000 --- a/builder/desktop/src/usb/mod.rs +++ /dev/null @@ -1,252 +0,0 @@ -//! Native USB: `nusb` under the shared byte-pipe seam. -//! -//! Tauri's webview has no WebUSB, so the desktop app drives USB itself. This is the only universal -//! USB path, and it is what a Safari or Firefox user installs the app for. -//! -//! The protocol is not reimplemented here. The object model, the descriptor codecs, the -//! whole-object CRC and the client live once, in TypeScript, over a pluggable `BytePipe`, so a -//! second host drops a transport underneath them instead of growing a parallel implementation that -//! drifts from a byte-exact wire contract. This module moves bytes and nothing else: every `0x` in -//! the non-test code is USB's own vocabulary, a vendor id, a product id, an interface class or an -//! endpoint-address direction bit. -//! -//! The control plane carries the protocol's control records and the stream plane carries its stream -//! records, both over IPC. -//! -//! There is no path that streams a file straight from disk into the endpoint. A record stream is -//! framed, and a raw byte streamer cannot produce one without a second implementation of the wire -//! contract. If a measurement ever says the IPC boundary is the bottleneck, the honest shape is a -//! Rust-side record sender that shares the codec. -//! -//! Both IPC directions carry raw binary and not JSON: a command result is [`tauri::ipc::Response`] -//! and a write arrives as [`tauri::ipc::InvokeBody::Raw`] with its handle and plane in headers. A -//! `Vec` argument would be serialised as a JSON array of numbers, about four bytes of text per -//! byte of payload. -//! -//! The window has no filesystem capability. A file the rider picks arrives through the webview as a -//! `File` with no path at all, exactly as it does on the web. - -pub mod runtime_guard; -pub mod watch; - -use std::collections::HashMap; -use std::sync::atomic::{AtomicU32, Ordering}; -use std::sync::{Arc, Mutex}; - -use tauri::ipc::{Channel, InvokeBody, Request, Response}; -use tauri::State; - -use obc_usb::{Dir, OpenLink, OpenedLink, PipeFault, Plane}; -use watch::{DeviceSummary, UsbEvent}; - -pub use obc_usb::{PRODUCT_ID, VENDOR_ID}; - -/// Every device this app has open, plus the one hot-plug watch behind them. -#[derive(Default)] -pub struct UsbState { - links: Mutex>>, - next_handle: AtomicU32, - /// Where the watch task sends events. Replaceable, so a window that reloaded re-points the - /// existing watch at its new channel instead of starting a second one. - sink: Mutex>>, - watching: Mutex, -} - -impl UsbState { - fn link(&self, handle: u32) -> Result, PipeFault> { - self.links - .lock() - .expect("usb links") - .get(&handle) - .cloned() - .ok_or_else(|| PipeFault::closed("The device link is closed.")) - } - - /// Fail and forget every link on a device that has gone away. - fn disconnected(&self, device_id: &str) { - let mut links = self.links.lock().expect("usb links"); - links.retain(|_, link| { - if link.device_id == device_id { - link.cancel_all(); - false - } else { - true - } - }); - } - - fn drop_all(&self) { - for (_, link) in self.links.lock().expect("usb links").drain() { - link.cancel_all(); - } - } -} - -/// Start or re-point the hot-plug watch and report what is attached now. -/// -/// It answers the matching devices after the watch is live, which is the order that cannot miss a -/// device plugged in during the call. -/// -/// Any link left over from a previous page load is dropped first. A reloaded window has no handles -/// but the backend still holds the interface claim, and a stale claim is what makes the next -/// `usb_open` fail as busy. -#[tauri::command] -pub async fn usb_watch( - state: State<'_, Arc>, - on_event: Channel, -) -> Result, String> { - let state = Arc::clone(&state); - state.drop_all(); - *state.sink.lock().expect("usb sink") = Some(on_event); - - { - let mut watching = state.watching.lock().expect("usb watching"); - if !*watching { - *watching = true; - let for_events = Arc::clone(&state); - let for_disconnect = Arc::clone(&state); - // One long-lived watch serves a window that reloads, because the task resolves the - // sink per event rather than capturing the channel it was born with. - watch::spawn( - Arc::new(move |event: UsbEvent| { - if let Some(channel) = for_events.sink.lock().expect("usb sink").as_ref() { - let _ = channel.send(event); - } - }), - Arc::new(move |device_id: &str| for_disconnect.disconnected(device_id)), - ); - } - } - - watch::list().await -} - -/// The matching devices attached right now, without touching the watch. A native host has no -/// chooser, so asking for a device is looking again. -#[tauri::command] -pub async fn usb_list() -> Result, String> { - watch::list().await -} - -/// Open, configure and claim a device; hand back a handle and the two pipes' packet sizes. -#[tauri::command] -pub async fn usb_open(state: State<'_, Arc>, device_id: String) -> Result { - let devices = - nusb::list_devices().await.map_err(|e| PipeFault::device(format!("USB devices could not be listed: {e}")))?; - let info = devices - .filter(watch::matches) - .find(|info| watch::device_key(info.id()) == device_id) - .ok_or_else(|| PipeFault::closed("That device is no longer attached."))?; - - let (link, mut opened) = obc_usb::open(&info, device_id).await?; - let handle = state.next_handle.fetch_add(1, Ordering::Relaxed) + 1; - opened.handle = handle; - state.links.lock().expect("usb links").insert(handle, link); - Ok(opened) -} - -/// Release a link. Idempotent; everything parked on it settles first. -#[tauri::command] -pub fn usb_close(state: State<'_, Arc>, handle: u32) { - let link = state.links.lock().expect("usb links").remove(&handle); - // The cancel lets a pending read return instead of holding the interface claim until the - // device says something. The claim drops with the last `Arc`, which the cancelled transfers - // hold. - if let Some(link) = link { - link.cancel_all(); - } -} - -/// One transfer's worth of bytes off a plane's IN endpoint. -/// -/// A read is not a message on the bulk plane: it hands back whatever the transport delivered, and -/// the client accumulates to the length its descriptor announced. -#[tauri::command] -pub async fn usb_read(state: State<'_, Arc>, handle: u32, plane: Plane) -> Result { - let link = state.link(handle)?; - let bytes = link.plane(plane).read().await?; - // `Response` is the raw path: the frontend gets an ArrayBuffer, not a JSON array of numbers. - Ok(Response::new(bytes)) -} - -/// Write one transfer to a plane's OUT endpoint. -/// -/// It takes the raw invoke body rather than a `Vec` argument. `handle` and `plane` ride in -/// headers, because a raw body is the whole payload. -#[tauri::command] -pub async fn usb_write(state: State<'_, Arc>, request: Request<'_>) -> Result<(), PipeFault> { - let header = |name: &str| { - request - .headers() - .get(name) - .and_then(|v| v.to_str().ok()) - .ok_or_else(|| PipeFault::device(format!("a usb_write is missing its `{name}` header."))) - }; - let handle: u32 = - header("handle")?.parse().map_err(|_| PipeFault::device("a usb_write carried an unreadable handle."))?; - let plane = match header("plane")? { - "control" => Plane::Control, - "bulk" => Plane::Bulk, - other => return Err(PipeFault::device(format!("a usb_write named an unknown plane `{other}`."))), - }; - let InvokeBody::Raw(bytes) = request.body() else { - return Err(PipeFault::device("a usb_write must carry its bytes as a raw body.")); - }; - let link = state.link(handle)?; - link.plane(plane).write(bytes).await -} - -/// Cancel whatever is parked on one direction of a plane, so the caller's `AbortSignal` reaches the -/// transport rather than only releasing the JavaScript promise. -#[tauri::command] -pub fn usb_cancel(state: State<'_, Arc>, handle: u32, plane: Plane, dir: Option) { - if let Ok(link) = state.link(handle) { - link.plane(plane).cancel(dir); - } -} - -/// Return a plane to a known-empty state. -#[tauri::command] -pub async fn usb_reset(state: State<'_, Arc>, handle: u32, plane: Plane) -> Result<(), PipeFault> { - state.link(handle)?.plane(plane).reset().await -} - -#[cfg(test)] -mod tests { - /// The policy without a Tauri app handle: the same canonicalise-then-prefix rule, over a real - /// temp tree so the symlink case is real. - fn allowed(root: &std::path::Path, candidate: &std::path::Path) -> bool { - let (Ok(root), Ok(candidate)) = (std::fs::canonicalize(root), std::fs::canonicalize(candidate)) else { - return false; - }; - candidate.is_file() && candidate.starts_with(&root) - } - - #[test] - fn only_files_inside_an_app_owned_root_are_sendable() { - let base = std::env::temp_dir().join(format!("obc-usb-policy-{}", std::process::id())); - let root = base.join("maps"); - let outside = base.join("elsewhere"); - std::fs::create_dir_all(&root).expect("root"); - std::fs::create_dir_all(&outside).expect("outside"); - std::fs::write(root.join("ok.obcm"), b"x").expect("write"); - std::fs::write(outside.join("secret"), b"x").expect("write"); - - assert!(allowed(&root, &root.join("ok.obcm"))); - assert!(!allowed(&root, &outside.join("secret"))); - // The traversal a prefix check alone would admit, and canonicalising does not. - assert!(!allowed(&root, &root.join("../elsewhere/secret"))); - // A directory is not a file. - assert!(!allowed(&root, &root)); - - #[cfg(unix)] - { - // Why both sides are canonicalised: a symlink inside the root that points out of it - // resolves to its target, and the target fails the prefix check. - let link = root.join("escape"); - std::os::unix::fs::symlink(outside.join("secret"), &link).expect("symlink"); - assert!(!allowed(&root, &link)); - } - let _ = std::fs::remove_dir_all(&base); - } -} diff --git a/builder/desktop/src/usb/runtime_guard.rs b/builder/desktop/src/usb/runtime_guard.rs deleted file mode 100644 index 5b86155c3a..0000000000 --- a/builder/desktop/src/usb/runtime_guard.rs +++ /dev/null @@ -1,51 +0,0 @@ -//! A test that the cargo feature which makes `nusb` usable from an async context is still on. -//! -//! `nusb` returns [`MaybeFuture`](nusb::MaybeFuture) rather than a plain future, so the same call -//! serves a blocking caller and an async one. The async arm needs somewhere to put the blocking -//! syscall, and which executor that is comes from the `smol` or `tokio` cargo feature. With neither -//! enabled, `BlockingTask::spawn` panics. That is not a compile error: the crate builds, clippy is -//! happy, and every `.await` on a `nusb` future panics the first time a real device is touched. -//! -//! What enforces it: Windows builds `list_devices()` from a blocking arm, so awaiting it reaches -//! the panic with no device attached, and the Windows CI leg fails if the feature is dropped. Linux -//! and macOS build the same call from a ready arm, so only the second half of this module covers -//! them, and that half runs only where a device is plugged in. - -#[cfg(test)] -mod tests { - /// Await a `nusb` `MaybeFuture` and require it not to panic. - /// - /// `list_devices()` is the only entry point that needs no hardware, so it is the one a CI - /// machine can run. The assertion is about reaching the result and not about its contents: a - /// machine with no USB devices is a legitimate pass. - #[tokio::test] - async fn awaiting_nusb_does_not_panic() { - let devices = nusb::list_devices().await.expect("the USB bus should be enumerable"); - // Draining it proves this is a real iterator and not an unpolled future. - let count = devices.count(); - println!("nusb enumerated {count} device(s)"); - } - - /// The half that covers macOS and Linux, on any machine with the device plugged in. - /// - /// Opening is blocking on all three platforms, so this reaches the panicking arm everywhere. It - /// skips loudly when the device is absent, because a silent skip would read as coverage that - /// does not exist. - #[tokio::test] - async fn opening_the_device_does_not_panic() { - let Some(info) = nusb::list_devices() - .await - .expect("the USB bus should be enumerable") - .find(|d| d.vendor_id() == super::super::VENDOR_ID && d.product_id() == super::super::PRODUCT_ID) - else { - println!("no OpenBikeComputer attached — skipping (this half needs hardware)"); - return; - }; - // The failure this guards is a panic, not an `Err`. A device held open by the app is an - // ordinary `Err` and must not fail the test. - match info.open().await { - Ok(_) => println!("opened the device"), - Err(e) => println!("device present but not openable ({e}) — the await itself is what mattered"), - } - } -} diff --git a/builder/desktop/src/usb/watch.rs b/builder/desktop/src/usb/watch.rs deleted file mode 100644 index 902d4dcc7c..0000000000 --- a/builder/desktop/src/usb/watch.rs +++ /dev/null @@ -1,130 +0,0 @@ -//! Discovery and hot-plug: what makes plugging a cable in light the window up. -//! -//! Plugging in must light up the UI within about a second, and unplugging must not leave a stuck -//! spinner. The browser gets that from `navigator.usb`'s events; here it comes from the OS -//! notification streams nusb wraps, which are edge-driven rather than polled, so the latency budget -//! is spent on the device side. -//! -//! A native host has no chooser and no permission prompt, so it sees the device the moment it -//! appears. The session shape stays the same as the browser's anyway: `requestDevice()` here is -//! looking again, so the same button keeps working and no UI branches on the transport. - -use std::sync::Arc; - -use futures_core::Stream; -use nusb::hotplug::HotplugEvent; -use nusb::DeviceInfo; -use serde::Serialize; - -use super::{PRODUCT_ID, VENDOR_ID}; - -/// A device the app is willing to talk to, as the frontend sees it. -#[derive(Debug, Clone, Serialize)] -#[serde(rename_all = "camelCase")] -pub struct DeviceSummary { - /// Opaque and stable for as long as the device stays plugged in: the key `usb_open` takes and - /// the key a `disconnected` event carries. Never parsed by the frontend. - pub id: String, - pub vendor_id: u16, - pub product_id: u16, - pub product: Option, - /// The nRF `FICR.DEVICEID`, which is what tells two boards apart. - pub serial_number: Option, -} - -/// What the watch task tells the frontend. -#[derive(Debug, Clone, Serialize)] -#[serde(rename_all = "camelCase", tag = "type")] -pub enum UsbEvent { - Connected { - device: DeviceSummary, - }, - Disconnected { - id: String, - }, - /// The OS notification stream ended or could not be started. Reported rather than swallowed: a - /// watch that died silently looks like nothing ever being plugged in. - WatchFailed { - message: String, - }, -} - -/// The frontend's handle on a device, stable for the life of the connection. -/// -/// `DeviceId` is opaque and platform-specific in shape, so it is stringified rather than -/// interpreted. The only property anything depends on is that one physical connection produces the -/// same string in a `connected` event, in `usb_list` and in the matching `disconnected`. -pub fn device_key(id: nusb::DeviceId) -> String { - format!("{id:?}") -} - -/// Is this one of ours? -/// -/// The pair is pid.codes' prototype and testing range, and the firmware declares the same one. -/// Allocating a real product id moves this constant, the firmware's `PRODUCT_ID` and the web -/// filters together. -pub fn matches(info: &DeviceInfo) -> bool { - info.vendor_id() == VENDOR_ID && info.product_id() == PRODUCT_ID -} - -pub fn summarize(info: &DeviceInfo) -> DeviceSummary { - DeviceSummary { - id: device_key(info.id()), - vendor_id: info.vendor_id(), - product_id: info.product_id(), - product: info.product_string().map(str::to_owned), - serial_number: info.serial_number().map(str::to_owned), - } -} - -/// Every matching device attached right now. -pub async fn list() -> Result, String> { - let devices = nusb::list_devices().await.map_err(|e| format!("USB devices could not be listed: {e}"))?; - Ok(devices.filter(matches).map(|info| summarize(&info)).collect()) -} - -/// What the watch task hands its events to. -/// -/// A closure rather than a [`Channel`], because the channel is replaceable: a window that reloads -/// opens a new one, and the watch outlives the page. -pub type Emit = Arc; - -/// Follow hot-plug forever. -/// -/// `on_disconnect` runs before the event reaches the frontend, and that ordering matters: it is -/// where the pipes of a link on the vanished device are failed, so an in-flight transfer's UI says -/// unplugged now instead of spinning until a timeout. -pub fn spawn(emit: Emit, on_disconnect: Arc) { - // Created before the caller lists devices: a device attached in the window between listing - // and watching would otherwise be missed. - let mut watch = match nusb::watch_devices() { - Ok(watch) => watch, - Err(e) => { - emit(UsbEvent::WatchFailed { message: format!("USB hot-plug is unavailable: {e}") }); - return; - } - }; - tauri::async_runtime::spawn(async move { - loop { - let event = std::future::poll_fn(|cx| std::pin::Pin::new(&mut watch).poll_next(cx)).await; - let Some(event) = event else { - emit(UsbEvent::WatchFailed { message: "The system stopped reporting USB device changes.".into() }); - return; - }; - match event { - HotplugEvent::Connected(info) if matches(&info) => { - emit(UsbEvent::Connected { device: summarize(&info) }); - } - HotplugEvent::Connected(_) => {} - HotplugEvent::Disconnected(id) => { - // Not filtered by vendor and product id: a disconnect carries only an id, and - // an id with no link is a no-op on both sides. Filtering here would mean - // keeping a device table only to discard events that are already ignored. - let key = device_key(id); - on_disconnect(&key); - emit(UsbEvent::Disconnected { id: key }); - } - } - } - }); -} diff --git a/builder/desktop/tauri.conf.json b/builder/desktop/tauri.conf.json deleted file mode 100644 index be82ac6bc2..0000000000 --- a/builder/desktop/tauri.conf.json +++ /dev/null @@ -1,40 +0,0 @@ -{ - "$schema": "https://schema.tauri.app/config/2", - "productName": "OpenBikeComputer", - "version": "0.1.0", - "identifier": "de.timohueser.openbikecomputer", - "build": { - "frontendDist": "../web/dist/desktop", - "devUrl": "http://localhost:5173", - "beforeDevCommand": "npm --prefix ../web run dev -- --mode desktop", - "beforeBuildCommand": "npm --prefix ../web run build:desktop" - }, - "app": { - "windows": [ - { - "label": "main", - "title": "OpenBikeComputer", - "width": 1360, - "height": 900, - "minWidth": 900, - "minHeight": 620, - "dragDropEnabled": false - } - ], - "security": { - "csp": "default-src 'self'; img-src 'self' data: blob:; style-src 'self' 'unsafe-inline'; script-src 'self' 'wasm-unsafe-eval'; connect-src 'self' ipc: http://ipc.localhost https://tiles.openbikecomputer.com https://maps.openbikecomputer.com" - } - }, - "bundle": { - "active": true, - "targets": "all", - "icon": [ - "icons/32x32.png", - "icons/128x128.png", - "icons/128x128@2x.png", - "icons/icon.ico", - "icons/icon.icns", - "icons/icon.png" - ] - } -} diff --git a/builder/usb/Cargo.toml b/builder/usb/Cargo.toml index 4a7192d255..4e4c9528b5 100644 --- a/builder/usb/Cargo.toml +++ b/builder/usb/Cargo.toml @@ -3,13 +3,12 @@ name = "obc-usb" version = "0.1.0" edition = "2021" publish = false -description = "Shared native USB byte transport and maintenance CLI for OpenBikeComputer" +description = "Native USB byte transport and card-format CLI for OpenBikeComputer" [dependencies] getrandom = { workspace = true } nusb = { version = "=0.2.5", features = ["tokio"] } obc-link = { workspace = true, features = ["client"] } -serde = { workspace = true, features = ["derive"] } tokio = { workspace = true, features = ["macros", "rt-multi-thread", "sync", "time"] } [dev-dependencies] diff --git a/builder/usb/README.md b/builder/usb/README.md new file mode 100644 index 0000000000..711818ec0e --- /dev/null +++ b/builder/usb/README.md @@ -0,0 +1,24 @@ +# obc-usb + +The native USB byte transport and the flat-store client over it, for a computer that talks to the +device over the cable. Its one program is `obc-format-card`, which `obc format-card` runs. + +## Linux USB permission + +macOS and Windows need no setup. On Linux, the USB device node belongs to root, so a program +cannot open the device until a udev rule gives the person at the machine access. Chrome and Edge +need the same rule for WebUSB. + +```sh +sudo cp builder/usb/linux/99-openbikecomputer.rules /etc/udev/rules.d/ +sudo udevadm control --reload-rules +sudo udevadm trigger +# unplug and reconnect the device +``` + +## Test + +```sh +obc test -p obc-usb +obc exec cargo clippy -p obc-usb --all-targets -- -D warnings +``` diff --git a/builder/desktop/linux/99-openbikecomputer.rules b/builder/usb/linux/99-openbikecomputer.rules similarity index 79% rename from builder/desktop/linux/99-openbikecomputer.rules rename to builder/usb/linux/99-openbikecomputer.rules index d46b583c73..e3142011cd 100644 --- a/builder/desktop/linux/99-openbikecomputer.rules +++ b/builder/usb/linux/99-openbikecomputer.rules @@ -1,16 +1,17 @@ -# OpenBikeComputer — let a logged-in desktop session open the device (#909). +# OpenBikeComputer — let the person at the machine open the device over USB, +# from Chrome or Edge (WebUSB) or from `obc format-card`. # # Linux is the only platform that needs anything. The device declares a -# vendor-specific interface (class 0xFF, #889), and: +# vendor-specific interface (class 0xFF), and: # # * macOS lets an application open one with no driver, no entitlement and no # kext — IOKit hands it over as long as nothing else has claimed it. # * Windows binds WinUSB automatically from the MS OS 2.0 BOS descriptors the # firmware ships, so there is no .inf, no Zadig and no driver install. # * Linux exposes it through usbfs at /dev/bus/usb/BBB/DDD, which is -# root-owned by default. Without a rule the app can enumerate the device and -# then fail to open it, which reads as "Permission denied" and looks like a -# bug in the app. +# root-owned by default. Without a rule a program can enumerate the device +# and then fail to open it, which reads as "Permission denied" and looks like +# a bug in the program. # # TAG+="uaccess" is the modern answer: systemd-logind grants the *currently # active local session* an ACL on the node, so the person sitting at the machine diff --git a/builder/usb/src/client/usb.rs b/builder/usb/src/client/usb.rs index 5115d87d2b..5d1bdd9a5f 100644 --- a/builder/usb/src/client/usb.rs +++ b/builder/usb/src/client/usb.rs @@ -158,7 +158,7 @@ pub(super) struct UsbTransport { impl UsbTransport { pub(super) async fn open(info: &nusb::DeviceInfo) -> Result { - let (link, _) = crate::open(info, format!("{:?}", info.id())).await?; + let link = crate::open(info).await?; let readers = Readers::start(&link); Ok(Self { link: Some(link), readers: Some(readers), serial: info.serial_number().map(str::to_owned) }) } @@ -249,7 +249,7 @@ impl Transport for UsbTransport { if devices.next().is_some() { return Err(PipeFault::device("More than one device has the saved serial number.")); } - if let Ok((link, _)) = crate::open(&info, format!("{:?}", info.id())).await { + if let Ok(link) = crate::open(&info).await { self.readers = Some(Readers::start(&link)); self.link = Some(link); return Ok(()); diff --git a/builder/usb/src/lib.rs b/builder/usb/src/lib.rs index 5a2d0bd901..5622715748 100644 --- a/builder/usb/src/lib.rs +++ b/builder/usb/src/lib.rs @@ -1,8 +1,8 @@ //! One claimed device: endpoint discovery, and the two byte pipes over it. //! //! Everything here moves **bytes**. Nothing in this file knows what a transfer descriptor is, what -//! a status envelope means, or which object an upload belongs to. The desktop app and maintenance -//! CLI share this transport; their protocol clients sit above it. +//! a status envelope means, or which object an upload belongs to. The protocol client in `client` +//! sits above it. pub mod client; @@ -10,7 +10,6 @@ use std::sync::Arc; use nusb::transfer::{Buffer, Bulk, Completion, In, Out, TransferError}; use nusb::{Device, DeviceInfo, Endpoint, Interface}; -use serde::{Deserialize, Serialize}; use tokio::sync::{watch, Mutex}; /// pid.codes' prototype/testing pair, shared with the board descriptors and WebUSB filter. @@ -35,8 +34,7 @@ const USB_BINDING_MAJOR: u8 = 5; const BULK_READ_TARGET: usize = 16 * 1024; /// Which of the two planes a call means. The names match `lib/usb/pipe.ts`'s `DeviceLink`. -#[derive(Debug, Clone, Copy, PartialEq, Eq, Deserialize)] -#[serde(rename_all = "lowercase")] +#[derive(Debug, Clone, Copy, PartialEq, Eq)] pub enum Plane { Control, Bulk, @@ -44,8 +42,7 @@ pub enum Plane { /// Which half of an endpoint pair. Cancellation is per-direction: an abort on a download must not /// also tear down the write the caller is about to make. -#[derive(Debug, Clone, Copy, PartialEq, Eq, Deserialize)] -#[serde(rename_all = "lowercase")] +#[derive(Debug, Clone, Copy, PartialEq, Eq)] pub enum Dir { In, Out, @@ -53,11 +50,8 @@ pub enum Dir { /// A transport failure, in the vocabulary `lib/usb/pipe.ts`'s `PipeError` already speaks. /// -/// The `code` is the contract — the TS side switches on it — and the `message` is for a human. -/// `unsupported` never appears here: it means "this browser has no WebUSB", which is exactly the -/// condition the desktop app exists to not have. -#[derive(Debug, Clone, Serialize)] -#[serde(rename_all = "camelCase")] +/// `unsupported` never appears here: it means "this browser has no WebUSB". +#[derive(Debug, Clone)] pub struct PipeFault { /// `closed` | `aborted` | `device-error`. pub code: &'static str, @@ -170,10 +164,7 @@ fn check_binding_major(interface_protocol: u8, device_release: u16) -> Result<() /// The mechanism is a `watch` channel rather than a `Notify` because the race matters: a cancel /// that arrives between the caller deciding to abort and the read parking itself must not be lost. /// A monotonic epoch the reader snapshots before it parks cannot miss one. -/// that arrives between "the caller decided to abort" and "the read parked itself" must not be -/// lost. A monotonic epoch the reader snapshots before it parks cannot miss one. pub struct Pipe { - pub max_packet: usize, read_len: usize, ep_in: Mutex>, ep_out: Mutex>, @@ -194,7 +185,6 @@ impl Pipe { // OS would fail the URB anyway. Round down, floor at one packet. let read_len = (target_read / max_packet).max(1) * max_packet; Ok(Self { - max_packet, read_len, ep_in: Mutex::new(ep_in), ep_out: Mutex::new(ep_out), @@ -329,10 +319,6 @@ async fn cancel_and_drain(ep: &mut Endpoin /// The `Interface` is held for its whole life because dropping it releases the claim — nothing /// reads it directly. pub struct OpenLink { - /// The stable key the frontend knows this device by; a hot-plug `Disconnected` carries the same - /// one, which is how a pulled cable reaches the pipes without waiting for a transfer to time - /// out. - pub device_id: String, pub control: Pipe, pub bulk: Pipe, _interface: Interface, @@ -345,29 +331,10 @@ impl OpenLink { Plane::Bulk => &self.bulk, } } - - /// Fail everything parked on both planes. Called on an unplug and on close. - pub fn cancel_all(&self) { - self.control.cancel(None); - self.bulk.cancel(None); - } -} - -/// What `usb_open` tells the frontend about the link it just got. -#[derive(Debug, Clone, Serialize)] -#[serde(rename_all = "camelCase")] -pub struct OpenedLink { - pub handle: u32, - pub device_id: String, - pub interface_number: u8, - pub control_packet_size: usize, - pub bulk_packet_size: usize, - pub product: Option, - pub serial_number: Option, } /// Open, configure and claim a device, returning its two pipes. -pub async fn open(info: &DeviceInfo, device_id: String) -> Result<(Arc, OpenedLink), PipeFault> { +pub async fn open(info: &DeviceInfo) -> Result, PipeFault> { let device: Device = info .open() .await @@ -414,23 +381,14 @@ pub async fn open(info: &DeviceInfo, device_id: String) -> Result<(Arc let control = Pipe::new(&interface, layout.control.0, layout.control.1, layout.control.2)?; let bulk = Pipe::new(&interface, layout.bulk.0, layout.bulk.1, BULK_READ_TARGET)?; - let opened = OpenedLink { - handle: 0, // filled in by the registry - device_id: device_id.clone(), - interface_number: layout.interface, - control_packet_size: control.max_packet, - bulk_packet_size: bulk.max_packet, - product: info.product_string().map(str::to_owned), - serial_number: info.serial_number().map(str::to_owned), - }; - Ok((Arc::new(OpenLink { device_id, control, bulk, _interface: interface }), opened)) + Ok(Arc::new(OpenLink { control, bulk, _interface: interface })) } /// The two failures whose remedy is not "try again", spelled out where they happen. /// /// On Linux the usbfs node is root-owned unless a udev rule says otherwise, and the error the user /// would otherwise read is a bare `Permission denied` with nothing to suggest that a one-line file -/// fixes it (`builder/desktop/linux/`). macOS needs nothing for a vendor interface; Windows +/// fixes it (`builder/usb/linux/`). macOS needs nothing for a vendor interface; Windows /// binds WinUSB from the MS OS 2.0 descriptors the firmware already ships. /// /// `Busy` is the other one, and it is not platform-specific: an interface may be claimed once, so a @@ -439,7 +397,7 @@ pub async fn open(info: &DeviceInfo, device_id: String) -> Result<(Arc fn permission_hint(error: &nusb::Error) -> &'static str { match error.kind() { nusb::ErrorKind::PermissionDenied if cfg!(target_os = "linux") => { - " — install the udev rule from the app's `linux/` folder, then unplug and re-plug the device." + " — install the udev rule from `builder/usb/linux/`, then unplug and re-plug the device." } nusb::ErrorKind::PermissionDenied => " — this account is not allowed to open the device.", nusb::ErrorKind::Busy => " — something else has it open. Close the other app or browser tab and try again.", diff --git a/builder/web/package-lock.json b/builder/web/package-lock.json index 568ae6854c..ab829fbd19 100644 --- a/builder/web/package-lock.json +++ b/builder/web/package-lock.json @@ -11,7 +11,6 @@ "@mapbox/vector-tile": "^3.0.0", "@maplibre/maplibre-gl-leaflet": "^0.1.4", "@protomaps/basemaps": "^5.7.2", - "@tauri-apps/api": "^2.11.1", "earcut": "^3.2.4", "leaflet": "^1.9.4", "maplibre-contour": "^0.1.1", @@ -1042,16 +1041,6 @@ "vite": "^6.3.0 || ^7.0.0" } }, - "node_modules/@tauri-apps/api": { - "version": "2.11.1", - "resolved": "https://registry.npmjs.org/@tauri-apps/api/-/api-2.11.1.tgz", - "integrity": "sha512-M2FPuYND2m+wh5hfW9ZpSdxMPdEJovPBWwoHJmwUpysTYNHaOkVFN419m/K0LIgjb/7KU2vBgsUepJWugQCvAA==", - "license": "Apache-2.0 OR MIT", - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/tauri" - } - }, "node_modules/@tsconfig/svelte": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/@tsconfig/svelte/-/svelte-5.0.8.tgz", diff --git a/builder/web/package.json b/builder/web/package.json index d8673dd761..338d10b7ed 100644 --- a/builder/web/package.json +++ b/builder/web/package.json @@ -10,8 +10,7 @@ "build:data": "vite build --mode data", "build:trailview": "vite build --mode trailview", "build:web": "vite build --mode web", - "build:desktop": "vite build --mode desktop", - "build:all": "npm run build && npm run build:web && npm run build:desktop", + "build:all": "npm run build && npm run build:web", "build:wasm": "bash ../build-wasm-bridges.sh", "preview": "vite preview", "check": "svelte-check --tsconfig ./tsconfig.json --fail-on-warnings", @@ -23,7 +22,6 @@ "@mapbox/vector-tile": "^3.0.0", "@maplibre/maplibre-gl-leaflet": "^0.1.4", "@protomaps/basemaps": "^5.7.2", - "@tauri-apps/api": "^2.11.1", "earcut": "^3.2.4", "leaflet": "^1.9.4", "maplibre-contour": "^0.1.1", diff --git a/builder/web/src/App.svelte b/builder/web/src/App.svelte index a18729aeee..253f9f5a22 100644 --- a/builder/web/src/App.svelte +++ b/builder/web/src/App.svelte @@ -2,13 +2,10 @@ import ConfirmDialog from "./components/ConfirmDialog.svelte"; import Header from "./components/Header.svelte"; import UpdatePrompt from "./components/UpdatePrompt.svelte"; - import Desktop from "./routes/Desktop.svelte"; import Home from "./routes/Home.svelte"; import { LINKS } from "./lib/constants"; import { platform, type StyleEditorModule } from "./lib/platform"; - import { DESKTOP_ADDS } from "./lib/platform/gating"; import { router } from "./lib/router.svelte"; - import { DESKTOP_ROUTE } from "./lib/routes"; // The advanced editor is maintainer tooling, reached through an `import()` // only the dev host declares — product hosts have no reference to the route @@ -20,28 +17,8 @@ let editor: Promise | undefined; const openEditor = load ? () => (editor ??= load()) : null; - // The device and rides pages reach the protocol codecs and the library — - // exactly the modules the entry chunk must not contain (platform/bundle.test.ts) - // — so both live behind memoized dynamic imports, the same shape the device - // surfaces already use. Gated on caps, not on a host name: a tier without - // the page treats its hash as home. - let devicePage: Promise | undefined; - const openDevice = platform.caps.deviceDashboard - ? () => (devicePage ??= import("./routes/Device.svelte")) - : null; - let ridesPage: Promise | undefined; - const openRides = platform.caps.rideLibrary - ? () => (ridesPage ??= import("./routes/Rides.svelte")) - : null; - const showEditor = $derived(router.route === "advanced" && openEditor !== null); - // Same shape as the editor's gate: a host that is missing nothing has - // nothing to read there, so #/desktop falls back to home rather than - // rendering a page that pitches the app you are already running. - const showDesktop = $derived(router.route === "desktop" && DESKTOP_ADDS.length > 0); - const showDevice = $derived(router.route === "device" && openDevice !== null); - const showRides = $derived(router.route === "rides" && openRides !== null); - const showHome = $derived(!showEditor && !showDesktop && !showDevice && !showRides); + const showHome = $derived(!showEditor); @@ -64,35 +41,18 @@ {/await} {/if} - {#if showDesktop} - - {/if} - {#if showDevice && openDevice} - {#await openDevice() then { default: Device }} - - {/await} - {/if} - {#if showRides && openRides} - {#await openRides() then { default: Rides }} - - {/await} - {/if} - + - -
- {#if active} - - sending {active.label}{#if active.total > 0} - · {active.pct}%{/if} - - {/if} - - {#if session?.status === "ready"} - - - - OBC - {#if session.info}{session.info.hardwareRevision}{/if} - - - - {:else if session?.status === "connecting"} - - - Connecting… - - {:else if session?.status === "unsupported"} - - - USB unavailable - - {:else} - - - No device - - - {/if} -
- - diff --git a/builder/web/src/components/Gated.svelte b/builder/web/src/components/Gated.svelte deleted file mode 100644 index 6e90efc05c..0000000000 --- a/builder/web/src/components/Gated.svelte +++ /dev/null @@ -1,98 +0,0 @@ - - - -{#if blocked} - {#if unavailable} -
{@render unavailable(reasonId)}
- {/if} -

- - {GATES[blocked].reason} - {DESKTOP_LINK.label} -

-{:else if children} - {@render children(value as T)} -{/if} - - diff --git a/builder/web/src/components/Header.svelte b/builder/web/src/components/Header.svelte index 107eef600b..9ad73dc041 100644 --- a/builder/web/src/components/Header.svelte +++ b/builder/web/src/components/Header.svelte @@ -4,11 +4,9 @@ import { setupSiteNavigation } from "../../../../docs/assets/site-navigation.js"; import { appearance, startTheme, toggleTheme } from "../lib/theme.svelte"; - import DeviceChip from "./DeviceChip.svelte"; import { platform } from "../lib/platform"; - import { available } from "../lib/platform/gating"; import { router, type Route } from "../lib/router.svelte"; - import { ADVANCED_ROUTE, DEVICE_ROUTE, RIDES_ROUTE } from "../lib/routes"; + import { ADVANCED_ROUTE } from "../lib/routes"; let header: HTMLElement; onMount(startTheme); @@ -23,18 +21,11 @@ ...(platform.styleEditor ? [{ route: "advanced" as const, href: ADVANCED_ROUTE, label: "Style editor" }] : []), - ...(available("deviceDashboard") - ? [{ route: "device" as const, href: DEVICE_ROUTE, label: "Device" }] - : []), - ...(available("rideLibrary") - ? [{ route: "rides" as const, href: RIDES_ROUTE, label: "Ride library" }] - : []), ]; const tabbed = tabs.length > 1; - // Links out of the app, present only where there is a site around it (the - // desktop app has none — `platform.siteNav` is absent there, and so are - // these). Orthogonal to the tabs: the dev server shows both. + // Links out of the app, present only where there is a site around it. + // Orthogonal to the tabs: the dev server shows both. const siteNav = platform.siteNav; @@ -83,9 +74,6 @@ {/if} - {#if available("deviceDashboard")} - - {/if} {#if siteNav && tabbed}
diff --git a/builder/web/src/components/UpdatePrompt.svelte b/builder/web/src/components/UpdatePrompt.svelte index d7299492c9..b783348da6 100644 --- a/builder/web/src/components/UpdatePrompt.svelte +++ b/builder/web/src/components/UpdatePrompt.svelte @@ -17,9 +17,7 @@ import { jobRegistry } from "../lib/device/job.svelte"; import { deviceHolder } from "../lib/device/session.svelte"; import { firmwareCheck } from "../lib/firmware/check.svelte"; - import { platform } from "../lib/platform"; - import { router } from "../lib/router.svelte"; - import { DEVICE_ROUTE, FIRMWARE_ANCHOR } from "../lib/routes"; + import { FIRMWARE_ANCHOR } from "../lib/routes"; const session = $derived(deviceHolder.session); /** Non-null exactly while a device is connected and has said what it is. */ @@ -42,15 +40,11 @@ } /** - * Take the rider to the card. - * - * On a tier with a Device page that is a navigation, and the page arrives through a dynamic - * import — so the element does not exist yet at the moment of the click. Hence the short poll - * rather than one `scrollIntoView` into nothing; it gives up quietly after a second. + * Take the rider to the card. The device surfaces arrive through a dynamic import, so the card + * can be missing at the moment of the click: a short poll, which gives up quietly after a second. */ function show(release: { version: string }) { answer(release); - if (platform.caps.deviceDashboard && router.route !== "device") router.go("device"); let tries = 0; const settle = () => { const card = document.getElementById(FIRMWARE_ANCHOR); @@ -73,13 +67,7 @@ {/if}
- - {#if platform.caps.deviceDashboard} - show(release)}>View update - {:else} - - {/if} +
{/if} @@ -115,11 +103,4 @@ gap: 8px; margin-top: 6px; } - - /* The link-shaped primary: `.btn` is written for buttons, so undo the anchor's own colour rule - and keep the label from picking up an underline on hover. */ - a.btn.primary { - color: var(--parchment); - text-decoration: none; - } diff --git a/builder/web/src/components/coverage/CorridorPanel.svelte b/builder/web/src/components/coverage/CorridorPanel.svelte index 7be7e55b58..32754420db 100644 --- a/builder/web/src/components/coverage/CorridorPanel.svelte +++ b/builder/web/src/components/coverage/CorridorPanel.svelte @@ -272,9 +272,6 @@ >

Add corridor

- {deviceHolder.session?.status === "ready" ? "device connected" : "device optional"} diff --git a/builder/web/src/components/coverage/CoverageHome.svelte b/builder/web/src/components/coverage/CoverageHome.svelte index aa6e98dff3..e41f18ddae 100644 --- a/builder/web/src/components/coverage/CoverageHome.svelte +++ b/builder/web/src/components/coverage/CoverageHome.svelte @@ -2,9 +2,7 @@ import { tick } from "svelte"; import type { CatalogClient } from "../../lib/catalog/client"; import { CoverageStore } from "../../lib/coverage/store.svelte"; - import { available } from "../../lib/platform/gating"; import DeviceStep from "../device/DeviceStep.svelte"; - import MapSendStep from "../device/MapSendStep.svelte"; import CoverageMap from "./CoverageMap.svelte"; import DownloadStep from "./DownloadStep.svelte"; import MapSummary from "./MapSummary.svelte"; @@ -115,11 +113,7 @@

Or send directly to device

- {#if available("deviceDashboard")} - - {:else} - - {/if} +
diff --git a/builder/web/src/components/coverage/CoverageHome.svelte.test.ts b/builder/web/src/components/coverage/CoverageHome.svelte.test.ts index e122fa2a3f..6d74947135 100644 --- a/builder/web/src/components/coverage/CoverageHome.svelte.test.ts +++ b/builder/web/src/components/coverage/CoverageHome.svelte.test.ts @@ -14,8 +14,7 @@ vi.mock("./CoverageMap.svelte", async () => ({ default: (await import("../../../ vi.mock("./SkinStep.svelte", async () => ({ default: (await import("./ToolIcon.svelte")).default })); vi.mock("../device/DeviceStep.svelte", async () => ({ default: (await import("./ToolIcon.svelte")).default })); const host = vi.hoisted(() => ({ catalog: vi.fn(), catalogFetch: vi.fn(async () => new Response("gone", { status: 404 })) })); -vi.mock("../../lib/platform", () => ({ platform: { ...host, name: "web", caps: { deviceDashboard: false }, openMapOutput: null } })); -vi.mock("../../lib/platform/gating", () => ({ available: () => false })); +vi.mock("../../lib/platform", () => ({ platform: { ...host, name: "web" } })); const client = (body: string, url: string) => CatalogClient.fromBody(body, url, { fetchImpl: host.catalogFetch, attempts: 1 }); async function settle() { for (let n = 0; n < 20; n++) { await Promise.resolve(); await tick(); } } diff --git a/builder/web/src/components/coverage/DownloadStep.svelte b/builder/web/src/components/coverage/DownloadStep.svelte index 0eb7132821..e1bc1265da 100644 --- a/builder/web/src/components/coverage/DownloadStep.svelte +++ b/builder/web/src/components/coverage/DownloadStep.svelte @@ -38,8 +38,6 @@ import { projectedRunDiskBytes } from "../../lib/cells/quota"; import { acquireMapWorkStorage } from "../../lib/cells/workBarrier"; import { saveBlob } from "../../lib/download"; - import { platform } from "../../lib/platform"; - import type { MapOutputSession } from "../../lib/platform/types"; import { downloadCells, planCells, @@ -130,7 +128,7 @@ // owner's outstanding put or a newly mounted component. if (phase !== "finalizing") { // Direct delivery is cancelled through the DeviceJob so the same signal reaches the - // in-flight PUT; its one abort listener enters failRun. Browser/desktop delivery has + // in-flight PUT; its one abort listener enters failRun. Browser delivery has // no outer controller, so it enters that owner path directly. if (output?.kind === "device" && !output.settled) output.ctx.cancel(cause); else void failRun(cause); @@ -164,9 +162,8 @@ let asmFraction = $state(0); /** When each assembly phase began, for the run's debug ledger. */ let asmPhaseStart: Partial> = {}; - /** The map, once there is one: what it is called, how big it is, and where it - * went if the host had somewhere to put it. */ - let savedFile = $state<{ name: string; byteLength: number; path?: string } | null>(null); + /** The map, once there is one: what it is called and how big it is. */ + let savedFile = $state<{ name: string; byteLength: number } | null>(null); /** Whether the file actually reached the disk. Not `savedFile !== null`: it is * set the moment the map is delivered, and a cancel that raced the delivery * must not tell someone to go and discard a file nobody has. */ @@ -192,12 +189,9 @@ // mount maintenance has joined the origin-global map-work barrier. let clearingCells = $state(true); let cellStorageNotice = $state(null); - let outputPath = $state(null); let runWarnings = $state([]); let errorMessage = $state(null); let abortCtl: AbortController | null = null; - let downloadOutput: MapOutputSession | null = null; - let outputCleanupFailed = $state(false); /** The name this run's file will be saved under, fixed when the run starts, so editing the * selection mid-download cannot rename the map that is already being built from the old one. * @@ -299,7 +293,7 @@ phase = "saving"; delivery = output?.kind === "device" ? deliverResidentMap(msg.bytes, msg.byteLength) - : deliverMap(new Blob([msg.bytes as unknown as BlobPart]), msg.byteLength, msg.bytes); + : deliverMap(new Blob([msg.bytes as unknown as BlobPart]), msg.byteLength); void delivery.catch(() => {}); break; case "done": @@ -324,7 +318,6 @@ output.ctx.phase("finalizing"); phase = "finalizing"; } - await closeDownloadOutput(false); } catch (cause) { await failRun(cause); break; @@ -380,9 +373,6 @@ * The map the assembly wrote into OPFS: its bytes were never in wasm memory and never crossed * the worker port, and on the browser host they never enter the tab's heap either — a `Blob` on * an OPFS file is a handle, and that is what the save is given. - * - * The desktop host does read it back, because its output session takes bytes to write into a - * real folder. That is one map resident, which is the residency that host always had. */ async function deliverStoredMap(byteLength: number) { const blob = await readMapOutput(); @@ -392,7 +382,7 @@ `assembler wrote. Free some disk space and try again.`, ); } - await deliverMap(blob, byteLength, null); + await deliverMap(blob, byteLength); } /** Deliver the explicitly memory-priced fallback without creating a second full-map Blob. */ @@ -411,7 +401,7 @@ /** Deliver the verified one-file result without ever materialising an OPFS * map in the tab heap. Device PUT reads the Blob twice in bounded slices * (CRC then transfer); browser download hands the same Blob to the browser. */ - async function deliverMap(blob: Blob, byteLength: number, bytes: Uint8Array | null) { + async function deliverMap(blob: Blob, byteLength: number) { if (sinkClosed) return; if (blob.size !== byteLength) { throw new Error( @@ -422,13 +412,6 @@ if (output?.kind === "device") { const { sendMapBlob } = await import("../../lib/device/write"); output.result = await sendMapBlob(output.client, blob, name, output.ctx); - } else if (downloadOutput) { - // A picked directory (or the desktop's native folder) takes the map - // where the rider wants it, to be sent on to the device later — the card - // itself carries a flat store, not a filesystem a host can write. The - // session streams a Blob without buffering it. - const path = await downloadOutput.write(name, bytes ?? blob); - savedFile = { name, byteLength, path }; } else { // No picker here: one file, one ordinary download, one prompt. saveBlob(blob, name); @@ -446,12 +429,6 @@ else current.resolve(result as PutResponse); } - async function closeDownloadOutput(discard: boolean) { - const current = downloadOutput; - downloadOutput = null; - if (current) await (discard ? current.discard() : current.finish()); - } - async function cleanupTransientCells(owner: Output | null = output) { const revision = owner?.transientCellRevision ?? null; if (owner) owner.transientCellRevision = null; @@ -551,8 +528,7 @@ // returned; only then may cleanup run and the next map action become available. await waitForRunOperations(owner); // A delivery that has not begun is now a no-op, but one may already be in - // flight — let it land before the output is discarded, or the discard races - // the write into the folder it removes. It is bounded by one file's write. + // flight — let it land before cleanup. It is bounded by one file's write. const deliveryCause = await delivery.then( () => null, (error: unknown) => error, @@ -561,7 +537,6 @@ // unwinding. Preserve that stable cause so the DeviceJob can surface interruption. if ((deliveryCause as { code?: unknown } | null)?.code === "link") cause = deliveryCause; const cancelled = cause instanceof DOMException && cause.name === "AbortError"; - await closeDownloadOutput(true).catch(() => (outputCleanupFailed = true)); await cleanupTransientCells(owner); if (direct) await cleanupDirectOutput(); owner.releaseWork?.(); @@ -695,21 +670,8 @@ const admittedEstimate = estimate; const admissionId = estimateGeneration; const requireDisk = estimateOnDisk; - // Native desktop saving still opens its output session under the click - // that started a download. Direct device delivery never opens a save - // destination, and the web host uses an ordinary browser download. - let picked: MapOutputSession | null = null; - if (out.kind === "download" && platform.openMapOutput) { - try { - picked = await platform.openMapOutput(mapName()); - } catch (cause) { - if (cause instanceof DOMException && cause.name === "AbortError") return; - throw cause; - } - } if (destroyed) throw new DOMException("the map builder was closed", "AbortError"); if (estimateGeneration !== admissionId || estimate !== admittedEstimate || !ready) { - await picked?.discard(); throw new Error("The map selection changed. Wait for its memory check before trying again."); } const runId = ++nextRunId; @@ -723,9 +685,6 @@ persisted = false; delivery = Promise.resolve(); sinkClosed = false; - outputPath = picked?.path ?? null; - downloadOutput = picked; - outputCleanupFailed = false; runWarnings = []; dlProgress = null; asmFraction = 0; @@ -1094,8 +1053,6 @@ if (estimate.headroomBytes >= estimate.budgetBytes * 0.15) return null; return ( `Close to the browser's memory budget: about ${formatBytes(estimate.peakBytes)} projected of ` + - // No "use the desktop app" here: the desktop host runs this very worker in - // its webview, so it carries the identical wasm32 ceiling. `${formatBytes(estimate.budgetBytes)}. It will probably assemble; a smaller area is the sure thing.` ); }); @@ -1218,12 +1175,6 @@ ); }); $effect(() => onSendReadyChange?.(ready)); - /** Whether a failed run left a file behind that someone has to delete. Counted from what - * actually reached the disk, and only where nothing cleaned it up: a picked directory's - * session removes what it wrote. */ - const incompleteFileRemains = $derived( - persisted && (!platform.openMapOutput || outputCleanupFailed), - ); const dlPct = $derived( dlProgress && dlProgress.totalBytes > 0 @@ -1355,14 +1306,7 @@ {#if lastRunKind === "device"}

Assembled and sent {runFileName}.

{:else} -

- {#if outputPath} - Saved {savedFile?.name} in - {outputPath}. - {:else} - Downloaded {savedFile?.name}. - {/if} -

+

Downloaded {savedFile?.name}.

{/if} {#if savedFile}

{formatBytes(savedFile.byteLength)}

@@ -1381,7 +1325,7 @@ {:else if phase === "error"}

- {#if incompleteFileRemains} + {#if persisted} The map was not completed. Discard the file it left behind: {errorMessage} {:else} Nothing was saved: {errorMessage} @@ -1389,7 +1333,7 @@

{:else if phase === "cancelled"}

- {#if incompleteFileRemains} + {#if persisted} Cancelled — discard the incomplete file it left behind. {:else} Cancelled — nothing was saved. diff --git a/builder/web/src/components/device/DeviceStep.svelte b/builder/web/src/components/device/DeviceStep.svelte index 5506bbccfe..7ba51bf6f2 100644 --- a/builder/web/src/components/device/DeviceStep.svelte +++ b/builder/web/src/components/device/DeviceStep.svelte @@ -1,8 +1,6 @@ - - {#snippet children()} - {#if deviceHolder.error} -

- {:else if !session} -

Looking for a device…

- {:else if session.status === "unsupported"} -

{session.error}

- {:else if session.status === "ready" && session.client} -
-

- - Connected - {#if session.info}{session.info.hardwareRevision}{/if} -

- -
- - {#await loadSurfaces()} -

Loading…

- {:then { default: Surfaces }} - - {:catch} - - {/await} - {:else if session.status === "connecting"} -

Connecting…

- {:else} - {#if deviceHolder.interrupted} - - {/if} -
- -

Connect by USB, then choose your device.

-
- {#if session.status === "error" && session.error} - - {/if} - {/if} - {/snippet} - - {#snippet unavailable(reason)} - - {/snippet} - +{#if deviceHolder.error} + +{:else if !session} +

Looking for a device…

+{:else if session.status === "unsupported"} +

{session.error}

+{:else if session.status === "ready" && session.client} +
+

+ + Connected + {#if session.info}{session.info.hardwareRevision}{/if} +

+ +
+ + {#await loadSurfaces()} +

Loading…

+ {:then { default: Surfaces }} + + {:catch} + + {/await} +{:else if session.status === "connecting"} +

Connecting…

+{:else} + {#if deviceHolder.interrupted} + + {/if} +
+ +

Connect by USB, then choose your device.

+
+ {#if session.status === "error" && session.error} + + {/if} +{/if} diff --git a/builder/web/src/components/device/PopMenu.svelte b/builder/web/src/components/device/PopMenu.svelte deleted file mode 100644 index 68e00e3156..0000000000 --- a/builder/web/src/components/device/PopMenu.svelte +++ /dev/null @@ -1,148 +0,0 @@ - - - - - - - - diff --git a/builder/web/src/components/device/PreviewModal.svelte b/builder/web/src/components/device/PreviewModal.svelte deleted file mode 100644 index f29f99b7d2..0000000000 --- a/builder/web/src/components/device/PreviewModal.svelte +++ /dev/null @@ -1,932 +0,0 @@ - - - - - - - - diff --git a/builder/web/src/components/device/RideExport.svelte b/builder/web/src/components/device/RideExport.svelte index 0c4ba692b5..bca13b876a 100644 --- a/builder/web/src/components/device/RideExport.svelte +++ b/builder/web/src/components/device/RideExport.svelte @@ -23,7 +23,6 @@ --> - -
-
-

Ride library

- - {listed.length} ride{listed.length === 1 ? "" : "s"}{#if totalKm > 0} · {totalKm.toLocaleString()} km - total{/if} - - - - - {#if rides && scope} - - {:else} - Plug the device in to pull new rides. - {/if} - -
- -
-
- {#if error} - - {/if} - - {#if report && report.failed.length > 0} - - {/if} - {#if report && report.recording > 0} -

- {report.recording === 1 ? "One ride is" : `${report.recording} rides are`} still being - recorded on the device and could not be copied. Finish - {report.recording === 1 ? "it" : "them"} there, then pull again. -

- {/if} - - {#if listed.length === 0} -

- No rides here yet. Plug the device in and pull — each ride lands as a GPX file in the - folder above, where you can back it up or drag it into anything that reads GPX. -

- {:else} -
    - {#each listed as ride (ride.key)} - {@const path = trackPath(ride.track, PREVIEW.width, PREVIEW.height)} -
  • (hovered = { key: ride.key, from: "list" })} - onmouseleave={() => (hovered = null)} - > - - - -
  • - {/each} -
- - {#if missingArchive > 0} -

- {missingArchive} ride{missingArchive === 1 ? "" : "s"} listed here - {missingArchive === 1 ? "is" : "are"} no longer on this computer — pull from the - device to restore {missingArchive === 1 ? "it" : "them"}. -

- {/if} - {/if} - - -

- Copying a ride here does not tell the device anything — over the cable a ride is read and - nothing more, so the device still counts every ride as un-copied and keeps it under its own - rules. Check Settings → Rides on the device for how long it keeps one; the - app cannot read that setting. The copies in this folder are yours and are never deleted by - this app. -

- - -
- -
- (hovered = key ? { key, from: "map" } : null)} - onopen={openByKey} - /> -
-
-
- - diff --git a/builder/web/src/components/device/RideMap.svelte b/builder/web/src/components/device/RideMap.svelte deleted file mode 100644 index 4c755dcc2c..0000000000 --- a/builder/web/src/components/device/RideMap.svelte +++ /dev/null @@ -1,209 +0,0 @@ - - - -
- - diff --git a/builder/web/src/components/device/RideTiles.svelte b/builder/web/src/components/device/RideTiles.svelte deleted file mode 100644 index 794575b205..0000000000 --- a/builder/web/src/components/device/RideTiles.svelte +++ /dev/null @@ -1,160 +0,0 @@ - - - -
- {#each rides as ride (ride.objectId)} - {@const recording = isRecording(ride)} - {@const held = heldHere?.has(ride.objectId) ?? false} - onopen(ride)} - > - {#snippet thumb()} - {@const track = trackFor(ride.objectId)} - - - {#snippet tag()} - {#if recording} - recording - {:else if heldHere} - {#if held} - in library - {:else} - not backed up - {/if} - {/if} - {/snippet} - - {/snippet} - -

{nameOf(ride)}

- -

- {recording ? "still on the device" : formatBytes(Number(ride.payloadLength))} -

-
- {#if onpull} - - {/if} -
- {/each} -
- - diff --git a/builder/web/src/components/device/RouteTiles.svelte b/builder/web/src/components/device/RouteTiles.svelte deleted file mode 100644 index 46a243a8e0..0000000000 --- a/builder/web/src/components/device/RouteTiles.svelte +++ /dev/null @@ -1,152 +0,0 @@ - - - -
- {#each routes as route (route.objectId)} - onopen(route)}> - {#snippet thumb()} - {@const track = trackFor(route.objectId)} - - - {/snippet} - - {#if editing && editing.id === route.objectId} - - commitEdit(route)} - onkeydown={(e) => onEditKey(e, route)} - /> - {:else} -

{nameOf(route)}

- {/if} -

{formatBytes(Number(route.payloadLength))}

-
- - - {#each trips as trip (trip.objectId)} - - {/each} - - - -
- {/each} - {@render children?.()} -
- - diff --git a/builder/web/src/components/device/Tile.svelte b/builder/web/src/components/device/Tile.svelte deleted file mode 100644 index e585030211..0000000000 --- a/builder/web/src/components/device/Tile.svelte +++ /dev/null @@ -1,118 +0,0 @@ - - - -
- {@render thumb?.()} -
- {@render children?.()} -
-
- - diff --git a/builder/web/src/components/device/TrackThumb.svelte b/builder/web/src/components/device/TrackThumb.svelte deleted file mode 100644 index 6eeecc39cc..0000000000 --- a/builder/web/src/components/device/TrackThumb.svelte +++ /dev/null @@ -1,127 +0,0 @@ - - - -
- {#if drawn.length > 0} - - {/if} - {#if tag} - {@render tag()} - {/if} -
- - diff --git a/builder/web/src/components/device/TripBand.svelte b/builder/web/src/components/device/TripBand.svelte deleted file mode 100644 index c80edca10d..0000000000 --- a/builder/web/src/components/device/TripBand.svelte +++ /dev/null @@ -1,356 +0,0 @@ - - - -
- -
-
- {#if editing !== null} - - - {:else} -

{name}

- {/if} -

- {#if stageCount !== null}{stageCount} stage{stageCount === 1 ? "" : "s"}{/if} -

- - - - -
- {#if trip.detail === null} -

The trip's stage list could not be read.

- {:else} - {#each stages as stage, index (`${stage.id}-${index}`)} -
- - {#if stage.route} - {@const route = stage.route} - - {:else} - - Route {stage.id} - no longer on the device - - {/if} - - - - - -
- {/each} - {/if} -
-
- - diff --git a/builder/web/src/components/device/TripDropDialog.svelte b/builder/web/src/components/device/TripDropDialog.svelte deleted file mode 100644 index 353f5d7a30..0000000000 --- a/builder/web/src/components/device/TripDropDialog.svelte +++ /dev/null @@ -1,302 +0,0 @@ - - - - - - - - diff --git a/builder/web/src/lib/catalog/client.test.ts b/builder/web/src/lib/catalog/client.test.ts index a93b4218c7..ac94e209cf 100644 --- a/builder/web/src/lib/catalog/client.test.ts +++ b/builder/web/src/lib/catalog/client.test.ts @@ -62,9 +62,9 @@ describe("CatalogClient.load", () => { }); it("refuses a relative URL rather than guessing a base", async () => { - // Resolving one is a host's job: the web host has a `document.baseURI`, - // the desktop host does not, and a client that guessed would resolve a - // CDN path against a Tauri asset scheme. + // Resolving one is a host's job: the web host resolves it against its + // `document.baseURI`, and a client that guessed could resolve a CDN path + // against the wrong base. await expect(CatalogClient.load("./data/catalog.json", { fetchImpl: serving({}).impl })).rejects.toThrow( CatalogFormatError, ); diff --git a/builder/web/src/lib/catalog/client.ts b/builder/web/src/lib/catalog/client.ts index a020c40e49..4d7646ad81 100644 --- a/builder/web/src/lib/catalog/client.ts +++ b/builder/web/src/lib/catalog/client.ts @@ -86,8 +86,8 @@ export class CatalogClient { * Fetch and parse the root. * * `url` must be absolute: resolving a relative one is a host's job — the web host - * has a `document.baseURI`, the desktop host does not — and a client that guessed - * would resolve a CDN path against a Tauri asset scheme. + * resolves it against its `document.baseURI` — and a client that guessed could + * resolve a CDN path against the wrong base. * * The root is fetched on trust, since there is no document above it to pin it, * which is why it is short-cached and everything else is content-addressed. diff --git a/builder/web/src/lib/constants.ts b/builder/web/src/lib/constants.ts index 68d40e60a6..1207ff0874 100644 --- a/builder/web/src/lib/constants.ts +++ b/builder/web/src/lib/constants.ts @@ -6,8 +6,8 @@ * deployed. `VITE_SITE_BASE` is that fact: * * * unset — the default — means the site is somewhere else, so name it - * absolutely. That is the dev server and the desktop app: neither is served - * from the site, and a relative link there would point at nothing. + * absolutely. That is the dev server: it is not served from the site, and a + * relative link there would point at nothing. * * set to a relative prefix (the deploy passes `../`, because the builder is * published at `/builder/` beside `/docs/`) means the site is right here. * Nothing absolute is baked in, so the whole artifact survives the move to a @@ -35,12 +35,9 @@ export const LINKS = { github: "https://github.com/timohueser/OpenBikeComputer", /** * The bundle's own third-party notices, emitted beside it at build time by - * `vite/third-party-licenses.ts` — so it stays relative in every tier, including the - * desktop app, where the file sits next to `index.html` inside the Tauri bundle. + * `vite/third-party-licenses.ts` — so it stays relative in every tier. * `vite dev` has no bundle and therefore no file; the link 404s there by design, * because a stale checked-in copy would be worse than an absent one. */ licenses: "./third-party-licenses.txt", - /** Where the desktop installers are published. */ - releases: "https://github.com/timohueser/OpenBikeComputer/releases", }; diff --git a/builder/web/src/lib/desktop/invoke.ts b/builder/web/src/lib/desktop/invoke.ts deleted file mode 100644 index f9eda97fd9..0000000000 --- a/builder/web/src/lib/desktop/invoke.ts +++ /dev/null @@ -1,176 +0,0 @@ -// The desktop host's transport: Tauri commands. Only the desktop platform and -// native device/library adapters import it, so it never reaches the other two -// bundles. -// -// Every function here is one `invoke()`. The names are the Rust command names in -// builder/desktop/src/main.rs, and the argument shapes are what serde deserializes -// there; that is the whole contract, and it is worth keeping in one file so a rename -// is one place on each side. - -import { invoke, type Channel } from "@tauri-apps/api/core"; - -/** The catalog manifest, plus the URL relative references resolve against. */ -export interface FetchedCatalog { - url: string; - body: string; -} - -export interface OpenedMapOutput { - id: number; - path: string; -} - -// The Rust side moves bytes and nothing else; the protocol is the TS client, the same -// one the hosted site runs. See builder/desktop/src/usb/ for the plane split and why -// the two binary calls below do not go through JSON. - -/** Which endpoint pair a call means — `DeviceLink`'s two members, by name. */ -export type UsbPlane = "control" | "bulk"; -/** Which half of a pair to cancel. Omitted means both. */ -export type UsbDir = "in" | "out"; - -/** A device the backend is willing to open. `id` is opaque: never parse it. */ -export interface UsbDeviceSummary { - id: string; - vendorId: number; - productId: number; - product: string | null; - serialNumber: string | null; -} - -/** Hot-plug, as the backend reports it. `watchFailed` is not a device problem — it - * means the OS notification stream itself is gone, and a watch that died quietly is - * indistinguishable from "nothing is ever plugged in". */ -export type UsbEvent = - | { type: "connected"; device: UsbDeviceSummary } - | { type: "disconnected"; id: string } - | { type: "watchFailed"; message: string }; - -/** What `usb_open` hands back: the handle every later call carries, plus the two - * planes' packet sizes. */ -export interface UsbLinkInfo { - handle: number; - deviceId: string; - interfaceNumber: number; - controlPacketSize: number; - bulkPacketSize: number; - product: string | null; - serialNumber: string | null; -} - -/** A transport failure in `PipeError`'s own vocabulary. Tauri rejects with the - * serialized `Err` value, so this arrives as a plain object rather than an `Error`. */ -export interface UsbFault { - code: string; - message: string; -} - -export const desktop = { - catalog: () => invoke("catalog"), - /** Raw response path: catalog cells can be hundreds of MB, so a JSON byte array is - * not an acceptable transport. Rust restricts this to the configured catalog - * origin. */ - catalogGet: (url: string) => invoke("catalog_get", { url }), - mapOutputBegin: (name: string) => invoke("map_output_begin", { name }), - mapOutputWrite: (id: number, name: string, bytes: Uint8Array) => - invoke("map_output_write", bytes, { - headers: { "output-id": String(id), filename: name }, - }), - mapOutputFinish: (id: number) => invoke("map_output_finish", { id }), - mapOutputDiscard: (id: number) => invoke("map_output_discard", { id }), - - revealFile: (path: string) => invoke("reveal_file", { path }), - - usbWatch: (onEvent: Channel) => invoke("usb_watch", { onEvent }), - usbList: () => invoke("usb_list"), - usbOpen: (deviceId: string) => invoke("usb_open", { deviceId }), - usbClose: (handle: number) => invoke("usb_close", { handle }), - - /** One transfer off a plane's IN endpoint. Resolves to an `ArrayBuffer`: the - * command returns `tauri::ipc::Response`, which is Tauri's raw path. */ - usbRead: (handle: number, plane: UsbPlane) => invoke("usb_read", { handle, plane }), - - /** - * One transfer onto a plane's OUT endpoint. - * - * The bytes are the *whole* invoke body — that is what makes them raw rather than a - * JSON array of numbers, roughly 4 bytes of text per byte — so the handle and the - * plane have nowhere to go but headers. - */ - usbWrite: (handle: number, plane: UsbPlane, bytes: Uint8Array) => - invoke("usb_write", bytes, { headers: { handle: String(handle), plane } }), - - usbCancel: (handle: number, plane: UsbPlane, dir?: UsbDir) => - invoke("usb_cancel", { handle, plane, dir: dir ?? null }), - usbReset: (handle: number, plane: UsbPlane) => invoke("usb_reset", { handle, plane }), - - // `ridesImport` is the one command in this file whose *timing* is part of a - // contract: it resolves after the ride object, the GPX and the index have each been - // fsynced, which is what makes `PullReport` true. See builder/desktop/src/rides.rs. - - ridesIndex: () => invoke("rides_index"), - ridesImport: (request: RideImportRequest) => invoke("rides_import", { request }), - /** The stored ride object. Raw, like `usbRead` — a JSON number array would be 4× the bytes. */ - ridesRead: (key: string) => invoke("rides_read", { key }), - ridesWriteGpx: (key: string, gpx: string) => invoke("rides_write_gpx", { key, gpx }), - /** Opens the OS folder chooser and moves the library. `null` when it was dismissed. */ - ridesChooseFolder: () => invoke("rides_choose_folder"), -}; - -// Field for field what `serde` reads and writes in builder/desktop/src/rides.rs. -// `lib/device/library.ts` owns the app-facing shapes; these are the wire ones. -// StoreId is full lowercase hex; ObjectId is a decimal u64 string, to keep JSON -// precision. - -export interface RideIndexEntry { - key: string; - serial: string; - storeId: string; - objectId: string; - name: string; - startTime: number; - distanceM: number; - movingTimeS: number; - climbM: number; - points: number; - bytes: number; - crc32: number; - importedAt: number; - /** Basenames — what the index stores, because the folder can move. */ - rideFile: string; - gpxFile: string; - track: Array<[number, number]>; - /** The basenames joined to the current folder, by the side that owns a path separator. */ - ridePath: string; - gpxPath: string; - /** Recomputed against the filesystem on every read, never trusted from the index. */ - present: boolean; - gpxPresent: boolean; -} - -export interface RideIndexView { - folder: string; - isDefault: boolean; - rides: RideIndexEntry[]; -} - -export interface RideImportRequest { - serial: string; - storeId: string; - objectId: string; - name: string; - startTime: number; - distanceM: number; - movingTimeS: number; - climbM: number; - points: number; - crc32: number; - track: Array<[number, number]>; - object: number[]; - gpx: string; -} - -export interface RideImported { - ride: RideIndexEntry; - imported: boolean; -} diff --git a/builder/web/src/lib/desktop/library.test.ts b/builder/web/src/lib/desktop/library.test.ts deleted file mode 100644 index b1dc655edb..0000000000 --- a/builder/web/src/lib/desktop/library.test.ts +++ /dev/null @@ -1,43 +0,0 @@ -import { describe, expect, it, vi } from "vitest"; -import { openRideLibrary } from "./library"; -import { desktop, type RideIndexEntry } from "./invoke"; - -vi.mock("./invoke", () => ({ - desktop: { ridesIndex: vi.fn(), ridesImport: vi.fn() }, -})); - -describe("desktop ride identity at the JSON boundary", () => { - it("uses decimal strings in both directions and bigint in the library", async () => { - const library = openRideLibrary(); - for (const storeId of ["a1b2c3d4000000000000000000000000", "a1b2c3d4000000000000000000000001"]) { - for (const objectId of [65536n, 9007199254740993n, 18446744073709551615n]) { - const key = `OBC-24-000317:${storeId}:${objectId}`; - const entry: RideIndexEntry = { - key, serial: "OBC-24-000317", storeId, objectId: objectId.toString(), - name: "Ride", startTime: 0, distanceM: 0, movingTimeS: 0, climbM: 0, - points: 1, bytes: 3, crc32: 0, importedAt: 1, - rideFile: "ride.obcride", gpxFile: "ride.gpx", - ridePath: "/archive/ride.obcride", gpxPath: "/rides/ride.gpx", - track: [], present: true, gpxPresent: true, - }; - vi.mocked(desktop.ridesImport).mockImplementation(async (request) => { - const json = JSON.parse(JSON.stringify(request)); - expect(json.storeId).toBe(storeId); - expect(json.objectId).toBe(objectId.toString()); - return JSON.parse(JSON.stringify({ ride: entry, imported: true })); - }); - const imported = await library.import({ - ...entry, objectId, object: new Uint8Array([1, 2, 3]), gpx: "", - }); - expect(imported.ride.key).toBe(key); - expect(imported.ride.storeId).toBe(storeId); - expect(imported.ride.objectId).toBe(objectId); - - vi.mocked(desktop.ridesIndex).mockResolvedValue( - JSON.parse(JSON.stringify({ folder: "/rides", isDefault: true, rides: [entry] })), - ); - expect((await library.view()).rides[0]).toEqual(imported.ride); - } - } - }); -}); diff --git a/builder/web/src/lib/desktop/library.ts b/builder/web/src/lib/desktop/library.ts deleted file mode 100644 index 82657202e3..0000000000 --- a/builder/web/src/lib/desktop/library.ts +++ /dev/null @@ -1,95 +0,0 @@ -/** - * The desktop host's ride library: `lib/device/library.ts`'s {@link RideLibrary} over six Tauri - * commands. - * - * Deliberately thin. Everything that decides whether this feature is correct is in - * `lib/device/library.ts`, over this interface, where it is tested against a fake that is not a mock - * of these calls. What lives here is the translation between the app's shapes and `serde`'s, and one - * decision worth stating: - * - * **`import()` is awaited for its timing, not just its value.** The Rust side writes the ride - * object, the GPX and the index, fsyncing each and the directory entry, and only then resolves. - * Nothing here may be made "fire and forget" for responsiveness — that would turn a durability - * predicate into an optimistic one, which is the single way this feature can lose a rider's ride. - */ - -import { desktop, type RideIndexEntry } from "./invoke"; -import type { LibraryRide, LibraryView, RideImport, RideLibrary } from "../device/library"; - -/** - * `RideIndexEntry` → `LibraryRide`. - * - * Convert the JSON decimal ObjectId to bigint. The wire carries `rideFile`/`gpxFile` as *basenames* - * plus the joined absolute paths, because a basename is what the index stores — the GPX folder can - * move — and a path is what `reveal()` needs, and joining them in JavaScript would have to guess a - * path separator. The two paths point at different roots: `ridePath` into the internal archive under - * app data, `gpxPath` into the visible folder. - */ -function toRide(entry: RideIndexEntry): LibraryRide { - return { - key: entry.key, - serial: entry.serial, - storeId: entry.storeId, - objectId: BigInt(entry.objectId), - name: entry.name, - startTime: entry.startTime, - distanceM: entry.distanceM, - movingTimeS: entry.movingTimeS, - climbM: entry.climbM, - points: entry.points, - bytes: entry.bytes, - crc32: entry.crc32, - importedAt: entry.importedAt, - ridePath: entry.ridePath, - gpxPath: entry.gpxPath, - track: entry.track, - present: entry.present, - gpxPresent: entry.gpxPresent, - }; -} - -export function openRideLibrary(): RideLibrary { - return { - async view(): Promise { - const view = await desktop.ridesIndex(); - return { - folder: view.folder, - isDefault: view.isDefault, - rides: view.rides.map(toRide), - }; - }, - - async import(ride: RideImport) { - const landed = await desktop.ridesImport({ - serial: ride.serial, - storeId: ride.storeId, - objectId: ride.objectId.toString(), - name: ride.name, - startTime: ride.startTime, - distanceM: ride.distanceM, - movingTimeS: ride.movingTimeS, - climbM: ride.climbM, - points: ride.points, - crc32: ride.crc32, - track: ride.track.map((p) => [p[0], p[1]] as [number, number]), - // The one place this host pays the JSON tax on binary. A ride object is hundreds of - // kilobytes, written exactly once per ride, behind a transfer that already took - // longer than the encode will. - object: Array.from(ride.object), - gpx: ride.gpx, - }); - return { ride: toRide(landed.ride), imported: landed.imported }; - }, - - // USB carries no possession acknowledgement: it changes no object, so it keeps the BLE - // surface it had. - - async readObject(key: string): Promise { - return new Uint8Array(await desktop.ridesRead(key)); - }, - - writeGpx: (key: string, gpx: string) => desktop.ridesWriteGpx(key, gpx), - reveal: (path: string) => desktop.revealFile(path), - chooseFolder: () => desktop.ridesChooseFolder(), - }; -} diff --git a/builder/web/src/lib/desktop/release.test.ts b/builder/web/src/lib/desktop/release.test.ts deleted file mode 100644 index b679ed8f0f..0000000000 --- a/builder/web/src/lib/desktop/release.test.ts +++ /dev/null @@ -1,38 +0,0 @@ -// A ratchet, not a test of today: `RELEASE` is null until the first installers are -// published, so the body below runs zero assertions right now — on -// purpose. The moment there is a build, these are the things that have to be -// true of it, and a missing checksum or a placeholder URL fails here instead of -// on someone's machine. The one assertion that always runs pins that the page -// has an honest empty state to fall back on. - -import { describe, expect, it } from "vitest"; -import { RELEASE } from "./release"; - -describe("the desktop release", () => { - it("either exists or is null — never a half-filled record", () => { - expect(RELEASE === null || typeof RELEASE === "object").toBe(true); - }); - - it("offers a real, checksummed file per platform", () => { - if (!RELEASE) return; - expect(RELEASE.version).toMatch(/\S/); - expect(RELEASE.date).toMatch(/^\d{4}-\d{2}-\d{2}$/); - expect(RELEASE.downloads.length).toBeGreaterThan(0); - - const seen = new Set(); - for (const file of RELEASE.downloads) { - expect(file.url).toMatch(/^https:\/\//); - expect(file.filename).toMatch(/\S/); - expect(file.size).toBeGreaterThan(0); - expect(file.sha256).toMatch(/^[0-9a-f]{64}$/); - const key = `${file.os} ${file.arch ?? ""}`; - expect(seen.has(key)).toBe(false); - seen.add(key); - } - }); - - it("writes the install note as instructions, not an apology", () => { - if (!RELEASE?.installNote) return; - expect(RELEASE.installNote).not.toMatch(/!|sorry|unfortunately|afraid|apolog/i); - }); -}); diff --git a/builder/web/src/lib/desktop/release.ts b/builder/web/src/lib/desktop/release.ts deleted file mode 100644 index fafef277f2..0000000000 --- a/builder/web/src/lib/desktop/release.ts +++ /dev/null @@ -1,36 +0,0 @@ -// What the desktop page offers to download. Until the installers are built, -// signed and published, `RELEASE` is null and the page says there are no builds -// yet rather than linking at files that do not exist. Inventing a URL now would -// cost a visitor a 404 and cost us the one thing the page is for. - -export interface DesktopDownload { - readonly os: "macOS" | "Windows" | "Linux"; - /** Only where one OS ships more than one build (`Apple silicon`, `x86-64`). */ - readonly arch?: string; - readonly filename: string; - readonly url: string; - /** Bytes, for the size shown next to the button. */ - readonly size: number; - /** Lowercase hex, 64 chars. Shown in full: a checksum you have to expand to - * read is a checksum nobody checks. */ - readonly sha256: string; -} - -export interface DesktopRelease { - readonly version: string; - /** ISO date, `YYYY-MM-DD`. */ - readonly date: string; - readonly downloads: readonly DesktopDownload[]; - /** - * Set only if D3 ships unsigned builds, and written as **instructions**: - * what to click, in what order, in the imperative. "Right-click the app and - * choose Open, then confirm" — not "unfortunately macOS will warn you that - * …". The page renders it under a *First run* heading, so it needs no - * preamble explaining that something is about to be awkward. - */ - readonly installNote?: string; -} - -/** Filled in once the installers are published. `src/lib/desktop/release.test.ts` holds it to - * its shape from then on. */ -export const RELEASE: DesktopRelease | null = null; diff --git a/builder/web/src/lib/desktop/usb.svelte.ts b/builder/web/src/lib/desktop/usb.svelte.ts deleted file mode 100644 index b08b46acd8..0000000000 --- a/builder/web/src/lib/desktop/usb.svelte.ts +++ /dev/null @@ -1,29 +0,0 @@ -/** - * The desktop host's device session — the reactive shell C3 already wrote, over a native watcher. - * - * This file is three lines of substance on purpose. `WatchedDeviceSession` mirrors any - * `DeviceWatcher`'s snapshots into runes, and `NativeWatcher` has the same three methods - * `WebUsbWatcher` does, so the entire desktop USB session is "the same session, different - * transport". If this file ever needs to grow a branch, the seam has stopped holding. - */ - -import { WatchedDeviceSession } from "../usb/session.svelte"; -import type { DeviceSession } from "../usb/session"; -import { NativeWatcher, type NativeWatcherOptions } from "./usb"; - -/** - * Open a native USB session and adopt an attached device if there is one. - * - * Returns as soon as the adopt attempt has settled — with a live client when a device was found and - * `idle` when none was. Neither is a failure: the session's job is to be something the UI can - * render in every state, including "nothing is plugged in yet". - * - * There is no `unsupported` state to reach here. That one means "this browser has no WebUSB", and - * not having to say it is the reason this tier exists. - */ -export async function openNativeSession(options: NativeWatcherOptions = {}): Promise { - const watcher = new NativeWatcher(options); - const session = new WatchedDeviceSession(watcher, "native"); - await watcher.start(); - return session; -} diff --git a/builder/web/src/lib/desktop/usb.test.ts b/builder/web/src/lib/desktop/usb.test.ts deleted file mode 100644 index d676d4a23a..0000000000 --- a/builder/web/src/lib/desktop/usb.test.ts +++ /dev/null @@ -1,683 +0,0 @@ -/** - * The native transport, driven end to end. - * - * There is no device in CI, so the substitution is made at exactly one place: the **Tauri command - * boundary**. Everything above it — `NativePipe`, `NativeWatcher`, `FlatStoreClient`, the record - * framing, the codecs, the CRC — is the shipping code, and the fake backend below stands in for - * `builder/desktop/src/usb/`, forwarding to the simulated device. - * - * That leaves two things a fake can prove: that a real fixture object round-trips through the real - * client over the native pipes byte for byte, with the device verifying the whole-object CRC, and - * that the transport properties hold — a read is not a record, a zero-length packet is a marker and - * not data, concurrent writes keep submission order, cancellation reaches the transport, and an - * unplug settles pending calls. - * - * A third is an absence: this host has no EP0 vendor request, which is asserted rather than worked - * around, because a connection that invented a firmware revision would feed "an update is - * available" a lie. - * - * Nothing here proves anything about `nusb`, the OS or the descriptors. - */ - -import { beforeAll, beforeEach, describe, expect, it, vi } from "vitest"; -import { existsSync, readFileSync } from "node:fs"; -import { dirname, join } from "node:path"; -import { fileURLToPath } from "node:url"; - -import { FlatStoreClient } from "../usb/client"; -import { Crc32 } from "../usb/crc32"; -import { loadFlatDevice } from "../../../test-support/flat-device/load"; -import { FlatDevice, type FlatDeviceOptions } from "../usb/flat-device"; -import { loopbackLink, type LoopbackLink, type LoopbackOptions } from "../usb/loopback"; -import { PipeError, type BytePipe } from "../usb/pipe"; -import { MAX_HOST_STREAM_RECORD } from "../usb/records"; -import { HEAD_REVISION, ObjectKind } from "../usb/protocol"; - -/** One `invoke()` the fake backend saw, for the wire assertions. */ -interface Call { - cmd: string; - args: unknown; - options?: { headers?: Record }; -} - -class FakeChannel { - onmessage: ((message: T) => void) | null = null; -} - -const calls: Call[] = []; -/** Set per test: what `usb_watch` / `usb_list` report is attached. */ -let attached: Array<{ - id: string; - vendorId: number; - productId: number; - product: string | null; - serialNumber: string | null; -}> = []; -/** The hot-plug channel the watcher handed `usb_watch` — a test pushes plug events through it. */ -let watchChannel: FakeChannel | null = null; -let wire: LoopbackLink | null = null; -let device: FlatDevice | null = null; -/** Whether `usb_open` should refuse, and with what. `onlyId` scopes the fault to one device. */ -let openFault: { code: string; message: string; onlyId?: string } | null = null; -/** Gates shifted per `usb_open` call — an entry parks that open until its promise resolves, - * which is how a test freezes one connect flow mid-open while another overtakes it. */ -let openGates: Array<(() => Promise) | undefined> = []; -/** Per-call gates for `usb_write` on the stream plane, modelling the backend's free ordering of - * concurrent invokes. */ -let writeGates: Array<(() => Promise) | undefined> = []; -/** In-flight reads/writes, so `usb_cancel` can settle them the way a cancelled URB does. */ -const inFlight = new Map(); - -/** - * The backend's plane name → the channel the protocol gives it. `"bulk"` is `DeviceLink.stream` - * under the Rust side's older name for the endpoint pair; renaming it is a Rust change. - */ -function planeOf(name: string): BytePipe { - const link = wire?.host; - if (!link) throw { code: "closed", message: "no link" }; - return name === "control" ? link.control : link.stream; -} - -async function backend(cmd: string, args: unknown, options?: { headers?: Record }): Promise { - const a = (args ?? {}) as Record; - switch (cmd) { - case "usb_watch": - watchChannel = a.onEvent as FakeChannel; - return attached; - case "usb_list": - return attached; - case "usb_open": { - const gate = openGates.shift(); - if (gate) await gate(); - if (openFault && (!openFault.onlyId || openFault.onlyId === a.deviceId)) throw openFault; - const found = attached.find((d) => d.id === a.deviceId); - if (!found) throw { code: "closed", message: "That device is no longer attached." }; - return { - handle: 1, - deviceId: found.id, - interfaceNumber: 0, - controlPacketSize: 512, - bulkPacketSize: 512, - product: found.product, - serialNumber: found.serialNumber, - }; - } - case "usb_close": - await wire?.host.close(); - return null; - case "usb_read": { - const key = `${a.plane}:in`; - const controller = new AbortController(); - inFlight.set(key, controller); - try { - const bytes = await planeOf(a.plane as string).read(controller.signal); - return bytes.buffer.slice(bytes.byteOffset, bytes.byteOffset + bytes.byteLength); - } catch (cause) { - throw asFault(cause); - } finally { - inFlight.delete(key); - } - } - case "usb_write": { - // The real command takes the bytes as the whole invoke body, with the handle and plane - // in headers — which is exactly what is asserted here rather than assumed. - const plane = options?.headers?.plane ?? ""; - if (plane === "bulk") { - const gate = writeGates.shift(); - if (gate) await gate(); - } - const key = `${plane}:out`; - const controller = new AbortController(); - inFlight.set(key, controller); - try { - await planeOf(plane).write(new Uint8Array(args as ArrayBufferLike), controller.signal); - return null; - } catch (cause) { - throw asFault(cause); - } finally { - inFlight.delete(key); - } - } - case "usb_cancel": { - const dirs = a.dir ? [a.dir as string] : ["in", "out"]; - for (const dir of dirs) inFlight.get(`${a.plane}:${dir}`)?.abort(); - return null; - } - case "usb_reset": - await planeOf(a.plane as string).reset(); - return null; - default: - throw new Error(`the fake backend has no command ${cmd}`); - } -} - -/** Translate the loopback's `PipeError` into the `{code, message}` the Rust side rejects with. */ -function asFault(cause: unknown): { code: string; message: string } { - if (cause instanceof PipeError) return { code: cause.code, message: cause.message }; - return { code: "device-error", message: String(cause) }; -} - -vi.mock("@tauri-apps/api/core", () => ({ - invoke: (cmd: string, args?: unknown, options?: { headers?: Record }) => { - calls.push({ cmd, args, options }); - return backend(cmd, args, options); - }, - Channel: FakeChannel, -})); - -const { NativeWatcher, openNativeLink } = await import("./usb"); - -function repoRoot(): string { - let dir = dirname(fileURLToPath(import.meta.url)); - for (let up = 0; up < 12; up++) { - if (existsSync(join(dir, "specs", "vectors", "manifest.json"))) return dir; - dir = dirname(dir); - } - throw new Error("could not locate the repo root"); -} -const ROOT = repoRoot(); -const vector = (name: string): Uint8Array => new Uint8Array(readFileSync(join(ROOT, "specs/vectors", name))); - -const DEVICE = { - id: "usb#1", - vendorId: 0x1209, - productId: 0x0001, - product: "OpenBikeComputer", - serialNumber: "0011223344556677", -}; -const DEVICE_B = { - id: "usb#2", - vendorId: 0x1209, - productId: 0x0001, - product: "OpenBikeComputer", - serialNumber: "8877665544332211", -}; - -/** A live simulated device behind the fake backend, and a watcher already connected to it. */ -async function connected(options: LoopbackOptions & FlatDeviceOptions = {}) { - wire = loopbackLink(options); - device = new FlatDevice(wire.device, options); - void device.run(); - attached = [DEVICE]; - const watcher = new NativeWatcher(); - const ok = await watcher.start(); - return { watcher, ok }; -} - -beforeAll(loadFlatDevice); - -beforeEach(() => { - calls.length = 0; - attached = []; - watchChannel = null; - openFault = null; - openGates = []; - writeGates = []; - inFlight.clear(); - wire = null; - device = null; -}); - -// Each test moves an object through the wasm flat device, which a machine that runs other suites slows past 5 s. -describe("the native pipes under the flat-store client", { timeout: 30_000 }, () => { - it("round-trips a specs/vectors object, byte for byte", async () => { - // 64-byte packets, so every record of any size spans several transfers in both directions. A - // client that treated one `usb_read` as one record would pass against a device that wrote - // whole records and fail here, which is the whole reason the loopback re-slices. - const { watcher, ok } = await connected({ packetSize: 64 }); - expect(ok).toBe(true); - const client = watcher.current.client!; - expect(watcher.current.status).toBe("ready"); - // The `LIST` every connection issues first is where the card's identity comes from. - expect(watcher.current.store).toEqual({ storeId: device!.storeId, commitSequence: device!.sequence }); - - // A `PUT` of a real OBCR fixture: the request over the control channel, the payload as - // stream records, and the device verifying the whole-object CRC at commit. The device is the - // one checking, so a mis-framed record fails here rather than being "uploaded". - const obcr = vector("route-waypoints.obcr"); - const put = await client.put({ kind: ObjectKind.Route, displayName: "waypoints" }, obcr); - expect(put.payloadLength).toBe(BigInt(obcr.length)); - expect(put.payloadCrc32).toBe(Crc32.of(obcr)); - expect(device!.payloadOf(put.objectId)).toEqual(obcr); - - // …and a `GET` in the other direction, whose length and CRC this side verifies. - const got = await client.get({ objectId: put.objectId, revision: HEAD_REVISION }); - expect(got.bytes).toEqual(obcr); - expect(got.revisionServed).toBe(put.revision); - - // The catalog, paged over the same channel, now names it. - const catalog = await client.list(); - expect(catalog.entries.map((e) => e.objectId)).toContain(put.objectId); - expect(catalog.entries.find((e) => e.objectId === put.objectId)?.displayName).toBe("waypoints"); - - await watcher.close(); - }); - - it("keeps concurrent stream writes in submission order across the bridge", async () => { - // The backend gives concurrent invokes no ordering guarantee — each lands in its own task - // racing for the endpoint lock. Delaying the first stream invoke a few ticks models the race: - // without the pipe's submission chain the second batch reaches the wire first and the object - // arrives with its middle swapped — right total length, wrong whole-object CRC. - const { watcher, ok } = await connected(); - expect(ok).toBe(true); - const client = watcher.current.client!; - // Big enough that the upload keeps several batches in its window, plus an odd tail. - const bytes = new Uint8Array(200_003); - for (let i = 0; i < bytes.length; i++) bytes[i] = (i * 31 + (i >> 9)) & 0xff; - writeGates.push(() => new Promise((resolve) => setTimeout(resolve, 10))); - const put = await client.put({ kind: ObjectKind.MapShard, displayName: "black forest" }, bytes); - expect(put.payloadCrc32).toBe(Crc32.of(bytes)); - expect(device!.payloadOf(put.objectId)).toEqual(bytes); - await watcher.close(); - }); -}); - -describe("the native pipe's transport contract", () => { - it("puts the bytes in a raw body and the routing in headers", async () => { - const { watcher } = await connected(); - const write = calls.find((c) => c.cmd === "usb_write"); - // A `Vec` argument would have been JSON — about four bytes of text per byte of payload, - // which is fine for a 32-byte `LIST` and absurd for a 300 MB map. - expect(write?.args).toBeInstanceOf(Uint8Array); - expect(write?.options?.headers).toEqual({ handle: "1", plane: "control" }); - const read = calls.find((c) => c.cmd === "usb_read"); - expect(read?.args).toEqual({ handle: 1, plane: "control" }); - await watcher.close(); - }); - - it("sends a record that spans packets instead of refusing it", async () => { - // A record is self-delimiting — a `record_length u32`, frame bytes and alignment padding, - // across as many packets as it takes — so the ordinary 8,208-byte stream frame has to go out, - // and so does a control record that lands on the 512-byte boundary. - wire = loopbackLink(); - attached = [DEVICE]; - const link = await openNativeLink(DEVICE.id); - const stream = Uint8Array.from({ length: MAX_HOST_STREAM_RECORD }, (_, i) => (i * 13) & 0xff); - await link.stream.write(stream); - expect(await drain(wire.device.stream, stream.length)).toEqual(stream); - - const control = new Uint8Array(512).fill(0xa5); - await link.control.write(control); - expect(await drain(wire.device.control, control.length)).toEqual(control); - await link.close(); - }); - - it("cancels at the transport rather than merely releasing the caller", async () => { - const { watcher } = await connected(); - const link = await openNativeLink(DEVICE.id); - const abort = new AbortController(); - const read = link.stream.read(abort.signal); - // Nothing is queued on the stream plane, so this read is genuinely parked — the case that - // wedges if a cancel only settles the promise: the backend would still hold the endpoint and - // the next read would queue behind an orphan that never completes. - await Promise.resolve(); - abort.abort(); - await expect(read).rejects.toMatchObject({ name: "PipeError", code: "aborted" }); - expect(calls.some((c) => c.cmd === "usb_cancel")).toBe(true); - await watcher.close(); - }); - - it("settles everything parked on it the moment the device is unplugged", async () => { - const { watcher } = await connected(); - const link = await openNativeLink(DEVICE.id); - const read = link.stream.read(); - link.disconnected(); - await expect(read).rejects.toMatchObject({ code: "closed" }); - // …and stays closed: a later call fails immediately instead of making another doomed round - // trip, which is the difference between one error message and a stuck spinner. - await expect(link.stream.read()).rejects.toMatchObject({ code: "closed" }); - - // The abandoned command settles *after* the caller was failed by the unplug, so its - // rejection lands on nobody. It must stay harmless: no second error, no resurrected pipe, and - // a `close()` afterwards that still works on a link whose device is already gone. - await wire!.host.close(); - await new Promise((resolve) => setTimeout(resolve, 10)); - expect(link.stream.open).toBe(false); - await watcher.close(); - }); -}); - -/** Read `total` bytes off a loopback end, which delivers them one packet at a time. */ -async function drain(pipe: BytePipe, total: number): Promise { - const out = new Uint8Array(total); - let at = 0; - while (at < total) { - const slice = await pipe.read(); - out.set(slice, at); - at += slice.length; - } - return out; -} - -// --- the device info this host cannot ask for ---------------------------------- - -describe("the device info this host cannot read", () => { - it("says so rather than answering with a version nobody read off the device", async () => { - // `GET_DEVICE_INFO` is an EP0 vendor request and the Rust bridge exposes no - // control-transfer command, so the link omits `vendorIn` entirely. The client turns that - // absence into one specific code, which is what the connect flow catches. - wire = loopbackLink(); - attached = [DEVICE]; - const link = await openNativeLink(DEVICE.id); - expect(link.vendorIn, "a link that cannot issue EP0 must not pretend to").toBeUndefined(); - const client = new FlatStoreClient(link); - await expect(client.deviceInfo()).rejects.toMatchObject({ name: "DeviceError", code: "unavailable" }); - await client.close(); - }); - - it("connects anyway, publishing no firmware version at all", async () => { - // The alternative — failing the connection, or filling the field with a plausible number — - // would either strand the desktop tier or hand "an update is available" a lie. `null` is the - // honest third answer, and the UI renders the absence. - const { watcher, ok } = await connected(); - expect(ok).toBe(true); - expect(watcher.current.status).toBe("ready"); - expect(watcher.current.info).toBeNull(); - expect(watcher.current.store).not.toBeNull(); - await watcher.close(); - }); -}); - -// --- discovery ----------------------------------------------------------------- - -describe("native discovery", () => { - it("adopts an attached device with no prompt and no gesture", async () => { - const { ok, watcher } = await connected(); - expect(ok).toBe(true); - // The watch is started before the listing, which is the ordering that cannot miss a device - // plugged in during the call. - expect(calls[0].cmd).toBe("usb_watch"); - await watcher.close(); - }); - - it("reports nothing attached as idle, which is not an error", async () => { - attached = []; - const watcher = new NativeWatcher(); - expect(await watcher.start()).toBe(false); - expect(watcher.current).toMatchObject({ status: "idle", error: null, client: null, store: null }); - await watcher.close(); - }); - - it("releases the interface when a connection fails partway", async () => { - // A device claimed but never listed still holds its interface, and an interface can be - // claimed once — so a failed connect that kept it would lock out every retry. - wire = loopbackLink(); - attached = [DEVICE]; - const watcher = new NativeWatcher({ timeoutMs: 20, hotplugRetryDelayMs: 1 }); - // No device running, so the `LIST` times out. - expect(await watcher.start()).toBe(false); - expect(watcher.current.status).toBe("error"); - expect(calls.some((c) => c.cmd === "usb_close")).toBe(true); - await watcher.close(); - }); - - it("surfaces a refused open as the sentence the backend wrote", async () => { - attached = [DEVICE]; - openFault = { - code: "device-error", - message: "Interface 0 could not be claimed: busy — something else has it open.", - }; - const watcher = new NativeWatcher({ hotplugRetryDelayMs: 1 }); - expect(await watcher.start()).toBe(false); - expect(watcher.current.error).toContain("something else has it open"); - await watcher.close(); - }); - - it("connects by itself when the device is plugged in after start", async () => { - // The hot-plug contract on hardware: app open, nothing attached, cable in — the window - // lights up with no click. The event rides the channel `usb_watch` was given. - attached = []; - const watcher = new NativeWatcher(); - await watcher.start(); - expect(watcher.current.status).toBe("idle"); - - wire = loopbackLink(); - device = new FlatDevice(wire.device); - void device.run(); - attached = [DEVICE]; - watchChannel!.onmessage!({ type: "connected", device: DEVICE }); - - await vi.waitFor(() => expect(watcher.current.status).toBe("ready")); - await watcher.close(); - }); - - it("retries when the OS announces the device before it is claimable", async () => { - // nusb's own hot-plug docs: a `Connected` event can precede the device being openable, so - // retry after a short delay. The failure that motivated this: one transient claim failure - // parked the session in `error` — which the chip renders as "No device" — forever. - attached = []; - const watcher = new NativeWatcher({ hotplugRetryDelayMs: 1 }); - await watcher.start(); - - wire = loopbackLink(); - device = new FlatDevice(wire.device); - void device.run(); - attached = [DEVICE]; - openFault = { code: "device-error", message: "Interface 0 could not be claimed: busy." }; - watchChannel!.onmessage!({ type: "connected", device: DEVICE }); - - // The first attempt has failed; between attempts the state stays `connecting`, not `error`. - await vi.waitFor(() => expect(calls.filter((c) => c.cmd === "usb_open").length).toBeGreaterThanOrEqual(1)); - expect(watcher.current.status).toBe("connecting"); - - openFault = null; // the OS finished setting the device up - await vi.waitFor(() => expect(watcher.current.status).toBe("ready")); - await watcher.close(); - }); - - it("settles back to idle when the device vanishes during the retries", async () => { - attached = []; - const watcher = new NativeWatcher({ hotplugRetryDelayMs: 1 }); - await watcher.start(); - - attached = [DEVICE]; - openFault = { code: "device-error", message: "busy" }; - watchChannel!.onmessage!({ type: "connected", device: DEVICE }); - await vi.waitFor(() => expect(calls.some((c) => c.cmd === "usb_open")).toBe(true)); - - // Unplugged again before any attempt succeeded: the truthful end state is idle, not an - // error about a device that is no longer there. - attached = []; - await vi.waitFor(() => expect(watcher.current.status).toBe("idle")); - expect(watcher.current.error).toBeNull(); - await watcher.close(); - }); - - it("gives up with the device's own error once the retries run out", async () => { - attached = []; - const watcher = new NativeWatcher({ hotplugRetryDelayMs: 1 }); - await watcher.start(); - - attached = [DEVICE]; - openFault = { - code: "device-error", - message: "Interface 0 could not be claimed: busy — something else has it open.", - }; - watchChannel!.onmessage!({ type: "connected", device: DEVICE }); - - await vi.waitFor(() => expect(watcher.current.status).toBe("error")); - expect(watcher.current.error).toContain("something else has it open"); - // Bounded: it tried its attempts and stopped, rather than polling forever. - expect(calls.filter((c) => c.cmd === "usb_open")).toHaveLength(5); - await watcher.close(); - }); - - it("retries start()'s own initial adopt through the same window", async () => { - // App launched moments after the cable went in: the initial probe hits the exact same - // not-yet-claimable window a hot-plug event does, where a single failed attempt would - // park in `error` with no event ever coming to rescue it. - wire = loopbackLink(); - device = new FlatDevice(wire.device); - void device.run(); - attached = [DEVICE]; - openFault = { code: "device-error", message: "not ready yet" }; - const watcher = new NativeWatcher({ hotplugRetryDelayMs: 1 }); - - let release1!: () => void; - let release2!: () => void; - openGates.push(() => new Promise((resolve) => (release1 = resolve))); - const started = watcher.start(); - await vi.waitFor(() => expect(calls.filter((c) => c.cmd === "usb_open")).toHaveLength(1)); - openGates.push(() => new Promise((resolve) => (release2 = resolve))); - release1(); // attempt 1 fails against the not-yet-claimable device - await vi.waitFor(() => expect(calls.filter((c) => c.cmd === "usb_open")).toHaveLength(2)); - openFault = null; // the OS finished setting the device up - release2(); - - expect(await started).toBe(true); - expect(watcher.current.status).toBe("ready"); - await watcher.close(); - }); - - it("lets a Connect click win over an adopt loop parked between attempts", async () => { - // The wedge this guards against: the click and the loop both open the same device, the - // loop's late failure publishes `error` over the click's `ready`, and whichever link - // loses is dropped still holding the interface claim. The click claims the flow, so the - // loop must notice and stand down without another attempt. - attached = []; - const watcher = new NativeWatcher({ hotplugRetryDelayMs: 120 }); - await watcher.start(); - - wire = loopbackLink(); - device = new FlatDevice(wire.device); - void device.run(); - attached = [DEVICE]; - openFault = { code: "device-error", message: "busy" }; - watchChannel!.onmessage!({ type: "connected", device: DEVICE }); - await vi.waitFor(() => expect(calls.filter((c) => c.cmd === "usb_open")).toHaveLength(1)); - - // The rider clicks Connect while the loop sleeps out its retry delay. - openFault = null; - expect(await watcher.requestDevice()).toBe(true); - expect(watcher.current.status).toBe("ready"); - - // The loop wakes, sees it lost the flow, and goes quietly: no third open, no late error, - // and the winner's client still works. - await new Promise((resolve) => setTimeout(resolve, 200)); - expect(watcher.current.status).toBe("ready"); - expect(calls.filter((c) => c.cmd === "usb_open")).toHaveLength(2); - const page = await watcher.current.client!.listPage({}); - expect(page.storeId).toBe(device!.storeId); - await watcher.close(); - }); - - it("closes, not orphans, a link whose flow lost while the handshake ran", async () => { - // The expensive half of the same race: a flow that already *opened* the device loses - // while its handshake runs. The Rust side holds the interface claim until the link is - // closed, so dropping the client on the floor would make every later open fail "busy" - // until a physical replug. The loser must close what it opened and publish nothing. - attached = []; - const watcher = new NativeWatcher({ hotplugRetryDelayMs: 1 }); - await watcher.start(); - - wire = loopbackLink(); - device = new FlatDevice(wire.device); - void device.run(); - attached = [DEVICE]; - let release!: () => void; - openGates.push(() => new Promise((resolve) => (release = resolve))); - watchChannel!.onmessage!({ type: "connected", device: DEVICE }); - await vi.waitFor(() => expect(calls.some((c) => c.cmd === "usb_open")).toBe(true)); - - // Overtaken while parked inside the open: a deliberate disconnect claims the flow. - await watcher.disconnect(); - const seen: string[] = []; - const unsubscribe = watcher.subscribe((s) => seen.push(s.status)); - release(); - - // The open and the handshake complete against the live device — and then the loser - // notices it lost: the link is closed at the backend, nothing is published. - await vi.waitFor(() => expect(calls.some((c) => c.cmd === "usb_close")).toBe(true)); - await new Promise((resolve) => setTimeout(resolve, 50)); - expect(watcher.current.status).toBe("idle"); - expect(seen).not.toContain("ready"); - expect(seen).not.toContain("error"); - expect(calls.filter((c) => c.cmd === "usb_open")).toHaveLength(1); - unsubscribe(); - await watcher.close(); - }); - - it("keeps a successor alive when a superseded loop's final attempt fails late", async () => { - // A replugged device gets a new id and a new `Connected` event while the old id's loop is - // still failing its last attempt. That final failure must not publish `error` over the - // fresh loop's `connecting` — before the flow token, it did, and the fresh loop then saw - // the wrong status and stood down: the freshly plugged device never connected. - attached = []; - const watcher = new NativeWatcher({ hotplugRetryDelayMs: 1 }); - await watcher.start(); - - wire = loopbackLink(); - device = new FlatDevice(wire.device); - void device.run(); - attached = [DEVICE, DEVICE_B]; - openFault = { code: "device-error", message: "gone", onlyId: DEVICE.id }; - // Attempts 1–4 fail fast; the 5th parks in its open so the successor can overtake it. - let release!: () => void; - openGates = [ - undefined, - undefined, - undefined, - undefined, - () => new Promise((resolve) => (release = resolve)), - ]; - watchChannel!.onmessage!({ type: "connected", device: DEVICE }); - await vi.waitFor(() => expect(calls.filter((c) => c.cmd === "usb_open")).toHaveLength(5)); - - watchChannel!.onmessage!({ type: "connected", device: DEVICE_B }); - await vi.waitFor(() => expect(watcher.current.status).toBe("ready")); - release(); // the old loop's final attempt now fails, late and superseded - - await new Promise((resolve) => setTimeout(resolve, 50)); - expect(watcher.current.status).toBe("ready"); - expect(watcher.current.error).toBeNull(); - // …and the connection that stands is the successor's, not a resurrected old one. - const opens = calls.filter((c) => c.cmd === "usb_open"); - expect((opens.at(-1)?.args as { deviceId: string }).deviceId).toBe(DEVICE_B.id); - await watcher.close(); - }); - - it("ends in idle when the unplug event lands mid-flow", async () => { - // The Disconnected event arrives while the flow has no link yet (so the link-based - // handler ignores it) and the device is even still *listed* by a stale probe. The flow - // chasing exactly this id is ended in the honest state, and its in-flight attempt's - // failure stays silent. - attached = []; - const watcher = new NativeWatcher({ hotplugRetryDelayMs: 1 }); - await watcher.start(); - - attached = [DEVICE]; - openFault = { code: "device-error", message: "busy" }; - // Park the attempt inside its open, so the unplug event demonstrably lands mid-flight. - let release!: () => void; - openGates.push(() => new Promise((resolve) => (release = resolve))); - watchChannel!.onmessage!({ type: "connected", device: DEVICE }); - await vi.waitFor(() => expect(calls.some((c) => c.cmd === "usb_open")).toBe(true)); - - watchChannel!.onmessage!({ type: "disconnected", id: DEVICE.id }); - await vi.waitFor(() => expect(watcher.current.status).toBe("idle")); - release(); // the parked attempt now fails, sees a stale token, and says nothing - await new Promise((resolve) => setTimeout(resolve, 60)); - expect(watcher.current.status).toBe("idle"); - expect(watcher.current.error).toBeNull(); - await watcher.close(); - }); - - it("re-scans instead of opening a chooser", async () => { - // The native host has no permission prompt, so `requestDevice()` is "look again now" — the - // Connect button keeps working and no UI branches on which transport it got. - attached = []; - const watcher = new NativeWatcher(); - await watcher.start(); - wire = loopbackLink(); - device = new FlatDevice(wire.device); - void device.run(); - attached = [DEVICE]; - expect(await watcher.requestDevice()).toBe(true); - expect(watcher.current.status).toBe("ready"); - await watcher.close(); - }); -}); - -// A map sent disk to endpoint inside Rust cannot exist until the Rust side frames records: every -// stream record carries a `RequestId`, an absolute offset and a length. The heap claim that path made belongs to the shared upload loop and is -// tested where that loop lives; the CRC constant it pinned is `usb/crc32.test.ts`'s. diff --git a/builder/web/src/lib/desktop/usb.ts b/builder/web/src/lib/desktop/usb.ts deleted file mode 100644 index 9c502a31b4..0000000000 --- a/builder/web/src/lib/desktop/usb.ts +++ /dev/null @@ -1,551 +0,0 @@ -/** - * The native USB transport: `nusb` behind the {@link BytePipe} seam. - * - * Tauri's webview has no WebUSB — WKWebView, WebView2 and WebKitGTK all lack it — so this tier - * drives USB from Rust. It is also the only universal USB path, and the answer for every Safari and - * Firefox user the hosted site cannot reach. - * - * Nothing about the protocol lives here. `lib/usb/` is the codec, the record framing and the client; - * this file supplies the two byte pipes underneath them and a watcher with the same three methods - * `WebUsbWatcher` has. It lives in `lib/desktop/` because it imports `@tauri-apps/api`, and - * `platform/bundle.test.ts` asserts nothing in that folder reaches the hosted bundle. - * - * What differs from the browser: - * - * - Cancellation reaches the transport. WebUSB cannot cancel a submitted `transferIn`; nusb can, and - * here it must, because after an abort the device stops sending and an orphaned read would hold - * the endpoint forever. - * - There is no chooser and no permission prompt. `requestDevice()` is "look again now". - * - There is no EP0 read: the Rust side exposes no control-transfer command, so the link omits - * `DeviceLink.vendorIn` and the connect flow publishes `info: null` rather than a fabricated - * firmware revision. - * - * A map is not sent from disk. Every stream record must be framed by the protocol client, which is - * TypeScript, so the desktop app sends a map exactly the way the browser does: a picked `File` - * through the webview. - */ - -import { PipeError, withAbort, type BytePipe, type DeviceLink } from "../usb/pipe"; -import { DeviceError, FlatStoreClient, isFormatRecoveryState, type ClientOptions } from "../usb/client"; -import type { DeviceInfo } from "../usb/records"; -import type { DeviceState, DeviceWatcher } from "../usb/session"; -import { Channel } from "@tauri-apps/api/core"; -import { desktop, type UsbDeviceSummary, type UsbEvent, type UsbLinkInfo, type UsbPlane } from "./invoke"; - -/** One endpoint pair, as a byte pipe over the Tauri commands in `builder/desktop/src/usb/`. */ -class NativePipe implements BytePipe { - readonly transport = "native"; - - private failure: PipeError | null = null; - private closedByUs = false; - /** Rejectors for {@link dead}, released when the pipe closes or fails. */ - private readonly mourners: Array<(error: PipeError) => void> = []; - /** - * The previous {@link write}'s settlement — each write chains on it, so submission order is wire - * order. Without the chain, concurrent writes each travel as an independent IPC invoke and the - * backend gives them no ordering: two in-flight chunks can swap on the wire, giving the right - * total length and the wrong whole-object CRC. The chain costs one IPC round trip of idle bridge - * per chunk, not wire idle. WebUSB needs none of this: the browser queues per-endpoint transfers - * in call order. - */ - private writeTail: Promise = Promise.resolve(); - - constructor( - /** - * The backend's name for this endpoint pair. `"bulk"` is what `DeviceLink.stream` is called - * on the Rust side; renaming it is a Rust change, so the wire word stays and the seam is here. - */ - readonly plane: UsbPlane, - private readonly handle: number, - /** - * The endpoint's max packet size, as `usb_open` reported it. Diagnostics only, never a - * branch target: packet boundaries carry no protocol meaning. - */ - readonly packetSize: number, - ) {} - - get open(): boolean { - return !this.failure && !this.closedByUs; - } - - async read(signal?: AbortSignal): Promise { - this.check(); - // The backend cancels the URB, so the abort is not merely the caller walking away: the - // transfer is really gone, and the endpoint is free for the reset that always follows. - const release = this.cancelOnAbort(signal, "in"); - try { - const body = await Promise.race([ - withAbort(desktop.usbRead(this.handle, this.plane), signal, "the read"), - this.dead(), - ]); - // Never empty: the backend absorbs zero-length packets, which are USB-level markers - // rather than data, and an empty read is indistinguishable from a spurious wakeup. - return new Uint8Array(body); - } catch (cause) { - throw this.asPipeError(cause, "read"); - } finally { - release(); - } - } - - /** - * One OUT transfer of whatever the caller handed over. There is deliberately no "a control frame - * must fit one packet" rule: records span packets by design, and the only thing that says where a - * record ends is its own four-byte prefix. - */ - async write(bytes: Uint8Array, signal?: AbortSignal): Promise { - this.check(); - const run = async () => { - const release = this.cancelOnAbort(signal, "out"); - try { - await Promise.race([ - withAbort(desktop.usbWrite(this.handle, this.plane, bytes), signal, "the write"), - this.dead(), - ]); - } catch (cause) { - throw this.asPipeError(cause, "write"); - } finally { - release(); - } - }; - // Chain on the predecessor whether it settled well or badly — its caller owns its error; - // this write only needs it to be off the bridge. See `writeTail` for why order is load-bearing. - const chained = this.writeTail.then(run, run); - this.writeTail = chained.then( - () => {}, - () => {}, - ); - return chained; - } - - /** - * Cancel everything in flight and clear both halves of the pair. - * - * An exchange that does not reach its correlated close leaves the channel at an unknown offset. - * Here that is a real cancel plus `CLEAR_FEATURE(ENDPOINT_HALT)`, not the best-effort `clearHalt` - * the browser can manage, so a cancelled download's tail is genuinely discarded. - */ - async reset(): Promise { - this.check(); - try { - await desktop.usbReset(this.handle, this.plane); - } catch (cause) { - // A pipe whose device has already gone has nothing left to reset, and the caller's - // original error is the interesting one. - if (this.failure) return; - throw this.asPipeError(cause, "reset"); - } - } - - async close(): Promise { - this.closedByUs = true; - this.bury(new PipeError("closed", "The device link is closed.")); - } - - /** Mark the pipe dead and fail everything waiting on it — what an unplug calls. */ - fail(error: PipeError): void { - this.failure ??= error; - this.bury(error); - } - - /** Tell the backend to cancel this direction when `signal` fires. Returns the unsubscriber. */ - private cancelOnAbort(signal: AbortSignal | undefined, dir: "in" | "out"): () => void { - if (!signal) return () => undefined; - const onAbort = () => void desktop.usbCancel(this.handle, this.plane, dir).catch(() => undefined); - signal.addEventListener("abort", onAbort, { once: true }); - return () => signal.removeEventListener("abort", onAbort); - } - - /** - * A promise that rejects when this pipe closes or fails. Raced against every call so an unplug - * settles the caller from the *event*, deterministically, rather than from whichever of the OS - * transfer error and the hot-plug notification wins. - */ - private dead(): Promise { - return new Promise((_, reject) => { - if (this.failure) reject(this.failure); - else if (this.closedByUs) reject(new PipeError("closed", "The device link is closed.")); - else this.mourners.push(reject); - }); - } - - private bury(error: PipeError): void { - while (this.mourners.length) this.mourners.shift()?.(error); - } - - private check(): void { - if (this.failure) throw this.failure; - if (this.closedByUs) throw new PipeError("closed", "The device link is closed."); - } - - private asPipeError(cause: unknown, what: string): PipeError { - if (this.failure) return this.failure; - const error = asPipeError(cause, what); - // A transport-level `closed` is terminal for this pipe, exactly as an unplug is: recording - // it means the next call fails immediately instead of making another doomed round trip. - if (error.code === "closed") this.fail(error); - return error; - } -} - -/** - * Translate a rejected Tauri command into a {@link PipeError}. - * - * The backend rejects with its own `{ code, message }`, deliberately in `PipeError`'s vocabulary, so - * the mapping is a lookup rather than string-matching an OS error. Anything else is a `device-error`. - */ -function asPipeError(cause: unknown, what: string): PipeError { - if (cause instanceof PipeError) return cause; - const fault = cause as { code?: unknown; message?: unknown } | null; - const code = fault?.code; - const message = typeof fault?.message === "string" ? fault.message : String(cause); - if (code === "closed" || code === "aborted" || code === "device-error") { - return new PipeError(code, message, { cause }); - } - return new PipeError("device-error", `The ${what} failed: ${message}`, { cause }); -} - -/** A claimed device, as a {@link DeviceLink}. */ -export interface NativeLink extends DeviceLink { - readonly info: UsbLinkInfo; - /** Fail both pipes at once — what a `disconnected` event calls. */ - disconnected(): void; -} - -/** - * Open and claim a device by the backend's opaque id, returning its two channels. - * - * `DeviceLink.vendorIn` is deliberately absent: the Rust side has no control-transfer command, and - * omitting the method is what lets {@link FlatStoreClient.deviceInfo} say "this host cannot ask". - */ -export async function openNativeLink(deviceId: string): Promise { - let info: UsbLinkInfo; - try { - info = await desktop.usbOpen(deviceId); - } catch (cause) { - throw asPipeError(cause, "connection"); - } - const control = new NativePipe("control", info.handle, info.controlPacketSize); - // The stream channel, under the backend's own name for the pair — see {@link NativePipe.plane}. - const stream = new NativePipe("bulk", info.handle, info.bulkPacketSize); - return { - info, - control, - stream, - disconnected() { - const error = new PipeError("closed", "The device was unplugged."); - control.fail(error); - stream.fail(error); - }, - async close() { - await control.close(); - await stream.close(); - try { - await desktop.usbClose(info.handle); - } catch { - // Closing a link whose device is already gone is the normal unplug path. - } - }, - }; -} - -export interface NativeWatcherOptions extends ClientOptions { - /** Injected by tests; defaults to the real Tauri bridge. */ - bridge?: Bridge; - /** Pause between hot-plug connect attempts; tests shrink it. */ - hotplugRetryDelayMs?: number; -} - -/** - * How a hot-plug connect is allowed to fail before it is a real error. - * - * The OS announces a device the moment it enumerates, which can be *before* it is claimable: nusb's - * own hot-plug docs say to retry after a short delay, and macOS has the same window while IOKit is - * still matching drivers. One failed attempt at that instant must not park the session in a dead - * `error` state, because the error chip reads as "No device". - */ -const HOTPLUG_CONNECT_ATTEMPTS = 5; -const HOTPLUG_RETRY_DELAY_MS = 400; - -const delay = (ms: number) => new Promise((resolve) => setTimeout(resolve, ms)); - -/** The slice of the Tauri bridge discovery uses, named so a test can drive the real code paths. */ -export interface Bridge { - usbWatch(onEvent: Channel): Promise; - usbList(): Promise; -} - -/** - * Finds the device, keeps up with plugging and unplugging, and owns the {@link FlatStoreClient}. - * - * The same three-method shape as `WebUsbWatcher`, so `WatchedDeviceSession` wraps either one and the - * UI above never learns which. - */ -export class NativeWatcher implements DeviceWatcher { - private readonly options: NativeWatcherOptions; - private readonly bridge: Bridge; - private readonly listeners = new Set<(state: DeviceState) => void>(); - - private link: NativeLink | null = null; - private state: DeviceState = { status: "idle", client: null, store: null, info: null, error: null }; - - constructor(options: NativeWatcherOptions = {}) { - this.options = options; - this.bridge = options.bridge ?? desktop; - } - - get current(): DeviceState { - return this.state; - } - - subscribe(listener: (state: DeviceState) => void): () => void { - this.listeners.add(listener); - listener(this.state); - return () => this.listeners.delete(listener); - } - - /** - * Start watching for hot-plug and adopt a device that is already attached. - * - * No gesture and no prompt, ever — that restriction is WebUSB's. Returns whether a device - * connected. The initial adopt runs through the same retrying flow the hot-plug path uses: an app - * launched moments after the cable went in hits the same not-yet-claimable window. - */ - async start(): Promise { - const channel = new Channel(); - channel.onmessage = (event) => this.onEvent(event); - let devices: UsbDeviceSummary[]; - try { - devices = await this.bridge.usbWatch(channel); - } catch (cause) { - this.publish({ ...this.state, status: "error", error: describe(cause) }); - return false; - } - return devices.length > 0 ? this.adopt(devices[0]) : false; - } - - /** - * Look for a device now. The native counterpart of the browser's chooser, and deliberately not a - * dialog: this host can see the device without asking anyone. It stays because the UI's Connect - * button calls it, and a button that re-scans is reasonable. - */ - async requestDevice(): Promise { - if (this.state.status === "ready") return true; - // Claim the flow before anything async: from here the click owns the published state, and a - // sleeping adopt loop stands down instead of racing it for the one interface claim. - const token = this.claimFlow(); - this.publish({ ...this.state, status: "connecting", error: null }); - let devices: UsbDeviceSummary[]; - try { - devices = await this.bridge.usbList(); - } catch (cause) { - if (this.owns(token)) { - this.publish({ status: "error", client: null, store: null, info: null, error: describe(cause) }); - } - return false; - } - if (!this.owns(token)) return false; - if (devices.length === 0) { - this.publish({ - status: "idle", - client: null, - store: null, - info: null, - error: null, - }); - return false; - } - return this.adopt(devices[0], token); - } - - /** Drop the link but keep watching, so re-plugging reconnects. */ - async disconnect(): Promise { - // A deliberate disconnect outranks any connect flow still in flight: claim the flow so a - // sleeping adopt loop stands down and an in-flight attempt finishes into silence. - this.claimFlow(); - this.chasing = null; - const client = this.state.client; - this.publish({ status: "idle", client: null, store: null, info: null, error: null }); - this.link = null; - await client?.close(); - } - - /** Stop following this session. The backend's watch outlives it and is re-pointed on the next - * `start()`, which is what makes a window reload cheap. */ - async close(): Promise { - await this.disconnect(); - this.listeners.clear(); - } - - // At most one connect flow may drive the published state and `this.link` at a time, but three - // things can start one — the hot-plug adopt loop, the Connect click, `start()`'s initial probe — - // and a running flow parks on awaits where any of the others can overtake it. So every flow - // claims a monotonically increasing token, claiming invalidates every older flow, and each older - // flow notices at its next step and stands down *silently*: it must not publish over the winner, - // must not null a link it no longer owns, and must close any link it did open, because the Rust - // side holds the interface claim until it is closed and an orphaned claim makes every later open - // fail "busy" until a physical replug. - - /** The current flow's token. Bump-to-claim. */ - private flow = 0; - /** The device id the current flow is chasing while it has no link yet — how a `disconnected` - * event can end a flow whose device vanished mid-attempt. */ - private chasing: string | null = null; - - private claimFlow(): number { - return ++this.flow; - } - - private owns(token: number): boolean { - return this.flow === token; - } - - /** - * One connect attempt: publish `connecting`, open, handshake, publish `ready` — with every - * publish and every `this.link` write gated on still owning `token`. A failure publishes nothing - * terminal and returns the failure's sentence; the *caller* owns the verdict. - */ - private async connectOnce(device: UsbDeviceSummary, token: number): Promise<{ ok: boolean; error?: string }> { - if (!this.owns(token)) return { ok: false }; - this.publish({ ...this.state, status: "connecting", error: null }); - let link: NativeLink | null = null; - try { - link = await openNativeLink(device.id); - const client = new FlatStoreClient(link, { timeoutMs: this.options.timeoutMs }); - // The EP0 read first, mirroring `WebUsbWatcher.connect`, except that this host cannot - // issue one. Only `unavailable` is caught: a device that answered a request badly is a - // real failure and must not be rounded down to "no info". - let info: DeviceInfo | null; - try { - info = await client.deviceInfo(); - } catch (cause) { - if (!(cause instanceof DeviceError) || cause.code !== "unavailable") throw cause; - info = null; - } - // Then `LIST`, which every client issues before anything else and which carries the - // store's identity. The wire major is settled by descriptor matching, not read here. - let store: DeviceState["store"]; - try { - const page = await client.listPage({}); - store = { storeId: page.storeId, commitSequence: page.commitSequence }; - } catch (cause) { - if (!isFormatRecoveryState(cause)) throw cause; - store = null; - } - if (!this.owns(token)) { - // A newer flow (or a disconnect) took the state while this handshake ran. The - // connection itself is real, so it must be closed, not dropped. - await client.close().catch(() => undefined); - return { ok: false }; - } - this.link = link; - this.publish({ - status: "ready", - client, - store, - info, - error: null, - }); - return { ok: true }; - } catch (cause) { - // A device claimed but never handshaken still holds its interface, and an interface can - // be claimed once, so releasing it lets a retry get at the device instead of finding it - // busy. `this.link` is deliberately not touched: a newer flow's may already be in there. - await link?.close().catch(() => undefined); - return { ok: false, error: describe(cause) }; - } - } - - /** - * Connect to a device, retrying over the window in which the OS has announced it but not - * finished setting it up — the shared flow behind the hot-plug event, `start()`'s initial probe - * and the Connect click. Between attempts the loop re-checks that the device is still attached, - * so a re-unplug ends in `idle` rather than an error about a device that is not there. - */ - private async adopt(device: UsbDeviceSummary, token: number = this.claimFlow()): Promise { - if (this.owns(token)) this.chasing = device.id; - try { - let lastError = "The device could not be opened."; - for (let attempt = 1; attempt <= HOTPLUG_CONNECT_ATTEMPTS; attempt++) { - const result = await this.connectOnce(device, token); - if (result.ok) return true; - // Superseded by a newer event, a Connect click or a disconnect — stand down silently - // rather than fight over the published state. This covers the final attempt too. - if (!this.owns(token)) return false; - if (result.error !== undefined) lastError = result.error; - if (attempt < HOTPLUG_CONNECT_ATTEMPTS) { - await delay(this.options.hotplugRetryDelayMs ?? HOTPLUG_RETRY_DELAY_MS); - if (!this.owns(token)) return false; - } - // Still attached? Between attempts this decides whether to keep trying; after the - // final one it decides between the honest `idle` and the device's own error. - const present = await this.stillAttached(device.id); - if (!this.owns(token)) return false; - if (present === false) { - this.publish({ status: "idle", client: null, store: null, info: null, error: null }); - return false; - } - } - this.publish({ status: "error", client: null, store: null, info: null, error: lastError }); - return false; - } finally { - if (this.owns(token)) this.chasing = null; - } - } - - /** Whether `deviceId` is still listed; null when the probe itself failed (unknown). */ - private async stillAttached(deviceId: string): Promise { - try { - return (await this.bridge.usbList()).some((d) => d.id === deviceId); - } catch { - return null; - } - } - - private onEvent(event: UsbEvent): void { - switch (event.type) { - case "connected": - if (this.state.status === "ready") return; - void this.adopt(event.device); - return; - case "disconnected": { - if (this.link && this.link.info.deviceId === event.id) { - // Fail the pipes *before* awaiting anything: every pending read and write - // settles now, so an in-flight transfer's UI reports "unplugged". - this.link.disconnected(); - const client = this.state.client; - this.link = null; - this.publish({ status: "idle", client: null, store: null, info: null, error: null }); - void client?.close(); - return; - } - // No link yet, but a connect flow is chasing exactly this device: end it in the - // honest state now. The in-flight attempt sees a stale token and says nothing. - if (this.chasing === event.id) { - this.claimFlow(); - this.chasing = null; - this.publish({ status: "idle", client: null, store: null, info: null, error: null }); - } - return; - } - case "watchFailed": - // Only meaningful when there is nothing connected: a live link keeps working without - // hot-plug, and replacing it with an error would be a lie about what is wrong. - if (this.state.status === "idle") { - this.publish({ ...this.state, status: "error", error: event.message }); - } - return; - } - } - - private publish(state: DeviceState): void { - this.state = state; - for (const listener of this.listeners) listener(state); - } -} - -function describe(cause: unknown): string { - if (cause instanceof Error) return cause.message; - const message = (cause as { message?: unknown } | null)?.message; - return typeof message === "string" ? message : String(cause); -} diff --git a/builder/web/src/lib/device/dashboard.svelte.test.ts b/builder/web/src/lib/device/dashboard.svelte.test.ts deleted file mode 100644 index 7a3215f111..0000000000 --- a/builder/web/src/lib/device/dashboard.svelte.test.ts +++ /dev/null @@ -1,194 +0,0 @@ -/** - * The device page's store, against the loopback device: loading and grouping, the serialization - * chain, busy-conflict accounting, and scope invalidation. - * - * A `LIST` is an ordinary control exchange, served beside a live transfer — but a trip's stage list - * is a `GET`, and one transfer at a time is a device-wide rule, so two of those fired together - * still collide. That is what these - * tests drive the chain with. - */ - -import { beforeAll, describe, expect, it } from "vitest"; - -import { DeviceDashboard } from "./dashboard.svelte"; -import type { RideScope } from "./rides"; -import { Crc32 } from "../usb/crc32"; -import { encodeTripObject, wholeDay } from "../usb/objects"; -import { FlatDevice, flatDevice } from "../usb/flat-device"; -import { loadFlatDevice } from "../../../test-support/flat-device/load"; -import { EntryFlags, ObjectKind } from "../usb/protocol"; - -beforeAll(loadFlatDevice); - -const SCOPE: RideScope = { serial: "0011223344556677", storeId: "a1b2c3d4000000000000000000000000" }; - -/** An OBCR-sized payload with a distinct byte at every offset — the page never looks inside one. */ -function routeBytes(seed: number): Uint8Array { - const out = new Uint8Array(128); - for (let i = 0; i < out.length; i++) out[i] = (i * 31 + seed) & 0xff; - return out; -} - -/** The store assigns the id; `seed` is the payload's own, so a test can name the bytes it expects. */ -function seedRoute(device: FlatDevice, name: string, seed = 0) { - return device.seed({ kind: ObjectKind.Route, displayName: name, bytes: routeBytes(seed) }); -} - -function seedTrip(device: FlatDevice, name: string, stages: bigint[]) { - const bytes = encodeTripObject({ key: 1n, name, startDate: 0, days: stages.map(wholeDay) }); - return device.seed({ kind: ObjectKind.Trip, displayName: name, bytes }); -} - -async function withDevice( - body: (rig: ReturnType, dash: DeviceDashboard) => Promise, -): Promise { - const rig = flatDevice({}); - try { - await body(rig, new DeviceDashboard()); - expect(rig.device.faults, "the device adapter saw a reaction it did not expect").toEqual([]); - } finally { - await rig.close(); - } -} - -describe("DeviceDashboard", () => { - it("loads and groups: trips resolve their stages, top-level excludes them", async () => { - await withDevice(async ({ client, device }, dash) => { - const first = seedRoute(device, "Day 1"); - const second = seedRoute(device, "Day 2"); - const loop = seedRoute(device, "Home loop"); - seedTrip(device, "Jura Crest Trail", [first.objectId, second.objectId]); - - await dash.ensureLoaded(client, SCOPE); - expect(dash.error).toBeNull(); - expect(dash.routes.map((r) => r.objectId)).toEqual([first.objectId, second.objectId, loop.objectId]); - expect(dash.topLevelRoutes.map((r) => r.objectId)).toEqual([loop.objectId]); - expect(dash.trips).toHaveLength(1); - expect(dash.stagesOf(dash.trips[0]).map((s) => s.route?.displayName)).toEqual(["Day 1", "Day 2"]); - }); - }); - - it("lists a ride the device is still recording, and marks it rather than offering it", async () => { - // A `GET` of a `RECORDING` entry is refused — its length and CRC are zero until the commit - // that ends it — so the page's job is to show it as in progress, not to hide it. - await withDevice(async ({ client, device }, dash) => { - const finished = device.seed({ kind: ObjectKind.Ride, displayName: "Tuesday", bytes: routeBytes(9) }); - const live = device.seed({ kind: ObjectKind.Ride, displayName: "Now", flags: EntryFlags.Recording }); - - await dash.ensureLoaded(client, SCOPE); - expect(dash.rides.map((r) => r.objectId)).toEqual([finished.objectId, live.objectId]); - expect(dash.rides.map((r) => dash.isRecording(r))).toEqual([false, true]); - }); - }); - - it("marks a dangling stage instead of dropping it", async () => { - await withDevice(async ({ client, device }, dash) => { - const kept = seedRoute(device, "Still here"); - // Stage 9 is a reference the trip's payload carries to an object that is not on the card. - seedTrip(device, "Half gone", [9n, kept.objectId]); - - await dash.ensureLoaded(client, SCOPE); - const stages = dash.stagesOf(dash.trips[0]); - expect(stages[0]).toEqual({ id: 9n, route: null }); - expect(stages[1].route?.displayName).toBe("Still here"); - }); - }); - - it("does not re-list for the same scope, and reloads for a new one", async () => { - await withDevice(async ({ client, device }, dash) => { - seedRoute(device, "First"); - await dash.ensureLoaded(client, SCOPE); - seedRoute(device, "Second"); - await dash.ensureLoaded(client, SCOPE); - expect(dash.routes, "same scope: the cached lists stand").toHaveLength(1); - await dash.ensureLoaded(client, { ...SCOPE, storeId: "00000000000000000000000000000007" }); - expect(dash.routes, "new scope: reloaded").toHaveLength(2); - }); - }); - - it("serializes enqueued transfers instead of tripping §1's one-at-a-time rule", async () => { - await withDevice(async ({ client, device }, dash) => { - const first = seedRoute(device, "One", 1); - const second = seedRoute(device, "Two", 2); - // Fired together; without the chain the second `GET` would throw `busy` before it left. - const [a, b] = await Promise.all([ - dash.enqueue(() => client.get({ objectId: first.objectId, revision: first.revision })), - dash.enqueue(() => client.get({ objectId: second.objectId, revision: second.revision })), - ]); - expect(a.bytes).toEqual(routeBytes(1)); - expect(b.bytes).toEqual(routeBytes(2)); - expect(dash.busy).toBe(false); - }); - }); - - it("keeps the chain alive after a failed operation", async () => { - await withDevice(async ({ client, device }, dash) => { - seedRoute(device, "Survivor"); - await expect(dash.enqueue(() => client.get({ objectId: 99n, revision: 0n }))).rejects.toMatchObject({ - code: "not-found", - }); - const catalog = await dash.enqueue(() => client.list({ kind: ObjectKind.Route })); - expect(catalog.entries).toHaveLength(1); - }); - }); - - it("flags busy when a foreign transfer holds the slot, and recovers after clearBusy", async () => { - await withDevice(async ({ client, device }, dash) => { - const route = seedRoute(device, "One"); - // A transfer the page does not own: started directly on the client, outside the chain — - // the builder tab's map send, in miniature. The rule is device-wide, so the page cannot - // serialize its way out of this one; it renders it. - let releaseForeign!: () => void; - const gate = new Promise((resolve) => (releaseForeign = resolve)); - const payload = new Uint8Array([1, 2, 3, 4]); - const foreign = client.put({ kind: ObjectKind.Route, displayName: "Foreign" }, { - totalLen: payload.length, - crc32: Crc32.of(payload), - chunks: async function* () { - await gate; - yield payload; - }, - }); - - await expect( - dash.enqueue(() => client.get({ objectId: route.objectId, revision: route.revision })), - ).rejects.toMatchObject({ code: "busy" }); - expect(dash.busy).toBe(true); - - releaseForeign(); - await foreign; - dash.clearBusy(); - const catalog = await dash.enqueue(() => client.list({ kind: ObjectKind.Route })); - expect(catalog.entries.map((entry) => entry.objectId)).toContain(route.objectId); - expect(dash.busy).toBe(false); - }); - }); - - it("refresh after a remove drops the row", async () => { - await withDevice(async ({ client, device }, dash) => { - const doomed = seedRoute(device, "Doomed"); - const stays = seedRoute(device, "Stays"); - await dash.ensureLoaded(client, SCOPE); - expect(dash.routes).toHaveLength(2); - await dash.enqueue(() => client.remove({ objectId: doomed.objectId, revision: doomed.revision })); - await dash.refresh(client); - expect(dash.routes.map((r) => r.objectId)).toEqual([stays.objectId]); - }); - }); - - it("invalidate drops everything, so the next connect decides what to load", async () => { - await withDevice(async ({ client, device }, dash) => { - seedRoute(device, "Loaded"); - await dash.ensureLoaded(client, SCOPE); - expect(dash.routes).toHaveLength(1); - - dash.invalidate(); - expect(dash.routes).toEqual([]); - expect(dash.trips).toEqual([]); - expect(dash.rides).toEqual([]); - // The same scope loads again, because nothing is remembered about it. - await dash.ensureLoaded(client, SCOPE); - expect(dash.routes).toHaveLength(1); - }); - }); -}); diff --git a/builder/web/src/lib/device/dashboard.svelte.ts b/builder/web/src/lib/device/dashboard.svelte.ts deleted file mode 100644 index 99fca8ba3a..0000000000 --- a/builder/web/src/lib/device/dashboard.svelte.ts +++ /dev/null @@ -1,166 +0,0 @@ -/** - * The device page's model of what is on the card: routes, trips (with their stage lists), rides. - * - * Three rules shape everything here, all inherited from the protocol: - * - * 1. **One transfer at a time, enforced by throwing.** A `LIST` is an ordinary control exchange, - * served beside a live upload, but a trip's stage list is a `GET`. `enqueue` keeps every cable - * operation this page makes on one promise chain, so the page can never collide with *itself*. - * It can still collide with a transfer another surface started, since the rule is device-wide, - * and that is not an error to retry into but a state to render. - * - * 2. **Ids are only meaningful inside `(serial, era)`.** A card swap or a different device makes - * every cached entry a claim about different objects, so the store reloads when the scope - * changes. - * - * 3. **The catalog is what a client can know without downloading.** A route's distance, a ride's - * start time and a trip's stage list live in the payload. Only the last is fetched here, - * because a trip object is 56 bytes plus eight per stage and the page cannot draw a trip - * without it. - * - * A module singleton, deliberately: the lists survive a tab switch, so returning to the Device tab - * does not re-list the card. - */ - -import type { FlatStoreClient } from "../usb/client"; -import { DeviceError } from "../usb/client"; -import { EntryFlags, ObjectKind, type CatalogEntry } from "../usb/protocol"; -import { decodeTripObject, type TripObject } from "../usb/objects"; -import { scopeKey, type RideScope } from "./rides"; - -/** A trip as the page renders it: the catalog row plus the stage list behind it. `detail` is null - * only when the trip object itself could not be read — rendered as a group with no rows. */ -export interface TripView extends CatalogEntry { - readonly detail: TripObject | null; -} - -export class DeviceDashboard { - routes = $state([]); - trips = $state([]); - rides = $state([]); - loading = $state(false); - /** A failure loading or mutating, rendered once at the top of the page. */ - error = $state(null); - /** A transfer owned by another surface holds the link's one slot. */ - busy = $state(false); - - private chain: Promise = Promise.resolve(); - private loadedFor: string | null = null; - - /** - * Run one cable operation, strictly after every previously enqueued one. - * - * The chain never rejects — each link settles — but the caller's promise still carries the - * failure, so call sites decide what a failure means. - */ - enqueue(op: () => Promise): Promise { - const run = this.chain.then(op, op); - this.chain = run.then( - () => undefined, - () => undefined, - ); - return run.catch((cause: unknown) => { - if (cause instanceof DeviceError && cause.code === "busy") this.busy = true; - throw cause; - }); - } - - /** Forget the slot conflict — called when the rider retries, or when the header's readout - * shows the foreign transfer finished. */ - clearBusy(): void { - this.busy = false; - } - - /** - * Load the three lists, once per `(serial, StoreId)`. A remount of the page on the same device - * renders what is already here; a card swap or another device reloads. - */ - async ensureLoaded(client: FlatStoreClient, scope: RideScope): Promise { - const key = scopeKey(scope); - if (this.loadedFor === key) return; - this.loadedFor = key; - await this.refresh(client); - } - - /** Re-read everything. Called after every mutation — a catalog page is metadata and the card is - * the authority, so re-listing beats mirroring each edit locally and drifting. */ - async refresh(client: FlatStoreClient): Promise { - this.loading = true; - this.error = null; - try { - // One listing, filtered here rather than three filtered by the device. A kind filter - // exists, but three round trips buy nothing when the whole catalog fits in a couple of - // pages and the page wants all three kinds every time. - const catalog = await this.enqueue(() => client.list()); - const routes = catalog.entries.filter((entry) => entry.kind === ObjectKind.Route); - const trips = catalog.entries.filter((entry) => entry.kind === ObjectKind.Trip); - const details: TripView[] = []; - for (const entry of trips) { - // Sequential on purpose — each is a `GET`, and the chain is the page's - // serialization guarantee. - const detail = await this.enqueue(() => - client.get({ objectId: entry.objectId, revision: entry.revision }), - ) - .then((result) => decodeTripObject(result.bytes)) - .catch(() => null); - details.push({ ...entry, detail }); - } - this.routes = routes; - this.trips = details; - // A ride the device is still recording has a zero length and CRC until the commit that - // ends it, so it is listed and not offered: the page shows it as recording. - this.rides = catalog.entries.filter((entry) => entry.kind === ObjectKind.Ride); - } catch (cause) { - this.error = cause instanceof Error ? cause.message : String(cause); - // Nothing loaded is a fact worth retrying, not a scope worth remembering. - this.loadedFor = null; - } finally { - this.loading = false; - } - } - - /** - * Every route id that is a stage of some trip — the rows the top-level list leaves out. Full-width - * flat-store ObjectIds, exactly as the trip payload carries them. - */ - get stagedIds(): Set { - const staged = new Set(); - for (const trip of this.trips) for (const day of trip.detail?.days ?? []) staged.add(day.route); - return staged; - } - - /** Routes that are not inside any trip, in list order. */ - get topLevelRoutes(): CatalogEntry[] { - const staged = this.stagedIds; - return this.routes.filter((route) => !staged.has(route.objectId)); - } - - /** - * A trip's stages resolved against the route list. Null marks a dangling id — a member route - * deleted on its own, which the device tolerates and serves verbatim. - * - * A trip stores the catalog's complete `u64` ObjectId, so resolution stays exact even after the - * allocation cursor has moved beyond JavaScript's safe integer range. - */ - stagesOf(trip: TripView): Array<{ id: bigint; route: CatalogEntry | null }> { - const byId = new Map(this.routes.map((route) => [route.objectId, route])); - return (trip.detail?.days ?? []).map(({ route: id }) => ({ id, route: byId.get(id) ?? null })); - } - - /** True where this entry is a ride the device is still recording, which cannot be served. */ - isRecording(entry: CatalogEntry): boolean { - return (entry.flags & EntryFlags.Recording) !== 0; - } - - /** Drop everything, for a disconnect: the next connect decides what to load. */ - invalidate(): void { - this.loadedFor = null; - this.routes = []; - this.trips = []; - this.rides = []; - this.error = null; - this.busy = false; - } -} - -export const dashboard = new DeviceDashboard(); diff --git a/builder/web/src/lib/device/elevation.test.ts b/builder/web/src/lib/device/elevation.test.ts deleted file mode 100644 index 10101e2554..0000000000 --- a/builder/web/src/lib/device/elevation.test.ts +++ /dev/null @@ -1,287 +0,0 @@ -import { describe, expect, it } from "vitest"; - -import { - FULL_WINDOW, - MIN_WINDOW_SPAN, - clampWindow, - cumulativeDistances, - elevationAtDistance, - elevationProfile, - isFullWindow, - nearestPointIndex, - panWindow, - pointAtDistance, - windowIndexRange, - zoomWindow, -} from "./elevation"; - -const climb = [ - { lat: 48.0, lon: 7.82, ele: 236 }, - { lat: 48.01, lon: 7.83, ele: 400 }, - { lat: 48.02, lon: 7.84, ele: 320 }, -]; - -/** Four points spaced ~1.11 km apart along a meridian — a near-uniform distance axis. */ -const ladder = [ - { lat: 48.0, lon: 7.82, ele: 100 }, - { lat: 48.01, lon: 7.82, ele: 200 }, - { lat: 48.02, lon: 7.82, ele: 300 }, - { lat: 48.03, lon: 7.82, ele: 400 }, -]; - -describe("elevationProfile", () => { - it("draws a climb: paths inside the box, extremes reported, distance positive", () => { - const profile = elevationProfile(climb, 600, 64); - expect(profile).not.toBeNull(); - expect(profile!.minEle).toBe(236); - expect(profile!.maxEle).toBe(400); - expect(profile!.totalM).toBeGreaterThan(1000); - expect(profile!.startM).toBe(0); - expect(profile!.endM).toBe(profile!.totalM); - expect(profile!.linePath.startsWith("M")).toBe(true); - expect(profile!.areaPath.endsWith("Z")).toBe(true); - // The peak maps to the top of the box (pad), the lowest point to the bottom. - const ys = profile!.linePath.match(/ (\d+\.\d)/g)!.map(Number); - expect(Math.min(...ys)).toBeCloseTo(2, 0); - expect(Math.max(...ys)).toBeCloseTo(62, 0); - }); - - it("draws a flat track mid-box rather than refusing it", () => { - const flat = climb.map((p) => ({ ...p, ele: 100 })); - const profile = elevationProfile(flat, 600, 64); - expect(profile).not.toBeNull(); - expect(profile!.minEle).toBe(100); - expect(profile!.maxEle).toBe(100); - }); - - it("returns null where nothing honest can be drawn", () => { - expect(elevationProfile([], 600, 64)).toBeNull(); - expect(elevationProfile([climb[0]], 600, 64)).toBeNull(); - expect(elevationProfile(climb.map((p) => ({ ...p, ele: null })), 600, 64)).toBeNull(); - // Two points at the same place: no distance axis. - expect(elevationProfile([climb[0], climb[0]], 600, 64)).toBeNull(); - }); - - it("keeps elevation-less points on the distance axis but out of the drawn series", () => { - const gappy = [climb[0], { lat: 48.005, lon: 7.825, ele: null }, climb[1], climb[2]]; - const profile = elevationProfile(gappy, 600, 64); - expect(profile).not.toBeNull(); - expect(profile!.maxEle).toBe(400); - // The gap point advances the axis: the total matches the all-points cumulative distance, - // not a collapsed one. - const cum = cumulativeDistances(gappy); - expect(profile!.totalM).toBeCloseTo(cum[cum.length - 1], 6); - }); - - describe("windowed", () => { - it("redraws only the window, with its own extremes and metre bounds", () => { - const full = elevationProfile(ladder, 600, 64)!; - const half = elevationProfile(ladder, 600, 64, [0.5, 1])!; - expect(half.startM).toBeCloseTo(full.totalM / 2, 6); - expect(half.endM).toBeCloseTo(full.totalM, 6); - expect(half.totalM).toBeCloseTo(full.totalM, 6); - // Only the back half's elevations: min is the interpolated 250 m at the cut. - expect(half.minEle).toBeCloseTo(250, 0); - expect(half.maxEle).toBe(400); - // The redrawn path spans the whole box, not a squeezed half of it. - const xs = half.linePath.match(/[ML](\d+\.\d)/g)!.map((m) => Number(m.slice(1))); - expect(Math.min(...xs)).toBeCloseTo(2, 0); - expect(Math.max(...xs)).toBeCloseTo(598, 0); - }); - - it("interpolates the elevation where the window cuts between samples", () => { - // A window strictly inside the middle segment: both edges are interpolants. - const profile = elevationProfile(ladder, 600, 64, [0.4, 0.6])!; - expect(profile.minEle).toBeCloseTo(220, 0); - expect(profile.maxEle).toBeCloseTo(280, 0); - }); - - it("returns null when the window holds no drawable elevation", () => { - const headOnly = [ - { lat: 48.0, lon: 7.82, ele: 100 }, - { lat: 48.01, lon: 7.82, ele: 200 }, - { lat: 48.02, lon: 7.82, ele: null }, - { lat: 48.03, lon: 7.82, ele: null }, - ]; - expect(elevationProfile(headOnly, 600, 64, [0.75, 1])).toBeNull(); - }); - }); -}); - -describe("cumulativeDistances", () => { - it("starts at zero, one entry per point, monotonic", () => { - const cum = cumulativeDistances(ladder); - expect(cum.length).toBe(4); - expect(cum[0]).toBe(0); - for (let i = 1; i < cum.length; i++) expect(cum[i]).toBeGreaterThan(cum[i - 1]); - // ~1.11 km per 0.01° of latitude. - expect(cum[3]).toBeGreaterThan(3200); - expect(cum[3]).toBeLessThan(3500); - }); - - it("is empty for no points and [0] for one", () => { - expect(cumulativeDistances([])).toEqual([]); - expect(cumulativeDistances([ladder[0]])).toEqual([0]); - }); -}); - -describe("clampWindow", () => { - it("orders and clamps a dragged pair", () => { - expect(clampWindow(0.8, 0.2)).toEqual([0.2, 0.8]); - expect(clampWindow(-0.5, 1.5)).toEqual([0, 1]); - }); - - it("grows a degenerate drag to the minimum span, kept inside the track", () => { - const [t0, t1] = clampWindow(0.5, 0.5); - expect(t1 - t0).toBeCloseTo(MIN_WINDOW_SPAN, 9); - expect(t0).toBeCloseTo(0.5 - MIN_WINDOW_SPAN / 2, 9); - expect(clampWindow(0, 0)).toEqual([0, MIN_WINDOW_SPAN]); - expect(clampWindow(1, 1)).toEqual([1 - MIN_WINDOW_SPAN, 1]); - }); -}); - -describe("zoomWindow", () => { - it("zooms in about the anchor, keeping the ground under it still", () => { - const [t0, t1] = zoomWindow([0, 1], 0.5, 0.5); - expect(t1 - t0).toBeCloseTo(0.5, 9); - expect((0.5 - t0) / (t1 - t0)).toBeCloseTo(0.5, 9); - // An off-centre anchor keeps its relative position. - const [u0, u1] = zoomWindow([0, 1], 0.5, 0.2); - expect((0.2 - u0) / (u1 - u0)).toBeCloseTo(0.2, 9); - }); - - it("never inverts, undershoots the minimum span, or leaves the track", () => { - const tiny = zoomWindow([0.4, 0.4 + MIN_WINDOW_SPAN], 0.1, 0.405); - expect(tiny[1] - tiny[0]).toBeCloseTo(MIN_WINDOW_SPAN, 9); - const out = zoomWindow([0.9, 1], 4, 0.99); - expect(out[0]).toBeGreaterThanOrEqual(0); - expect(out[1]).toBeLessThanOrEqual(1); - expect(zoomWindow([0, 1], 3, 0.5)).toEqual([0, 1]); - }); -}); - -describe("windowIndexRange", () => { - // Four points, three equal segments: cum = [0, 1, 2, 3]. - const cum = [0, 1, 2, 3]; - - it("covers the whole track at the full window", () => { - expect(windowIndexRange(cum, FULL_WINDOW)).toEqual([0, 3]); - }); - - it("rounds outward so the highlight covers the window", () => { - // [0.5, 0.83] in distance = [1.5 m, 2.5 m]: needs points 1..3 to cover. - expect(windowIndexRange(cum, [0.5, 5 / 6])).toEqual([1, 3]); - // Exactly on vertices: no widening. - expect(windowIndexRange(cum, [1 / 3, 2 / 3])).toEqual([1, 2]); - }); - - it("degenerates safely", () => { - expect(windowIndexRange([], FULL_WINDOW)).toEqual([0, 0]); - expect(windowIndexRange([0], FULL_WINDOW)).toEqual([0, 0]); - }); -}); - -describe("panWindow", () => { - it("slides without resizing", () => { - const [t0, t1] = panWindow([0.2, 0.4], 0.3); - expect(t0).toBeCloseTo(0.5, 9); - expect(t1).toBeCloseTo(0.7, 9); - }); - - it("clamps at both ends, span preserved", () => { - expect(panWindow([0.2, 0.4], -1)).toEqual([0, 0.2]); - const [t0, t1] = panWindow([0.2, 0.4], 1); - expect(t0).toBeCloseTo(0.8, 9); - expect(t1).toBeCloseTo(1, 9); - // The full window has nowhere to go. - expect(panWindow([0, 1], 0.5)).toEqual([0, 1]); - }); -}); - -describe("pointAtDistance", () => { - const cum = cumulativeDistances(ladder); - - it("lands on vertices at their exact distances", () => { - expect(pointAtDistance(ladder, cum, 0)).toEqual({ lat: 48.0, lon: 7.82 }); - expect(pointAtDistance(ladder, cum, cum[2])).toEqual({ lat: 48.02, lon: 7.82 }); - expect(pointAtDistance(ladder, cum, cum[3])).toEqual({ lat: 48.03, lon: 7.82 }); - }); - - it("interpolates within a segment", () => { - const mid = pointAtDistance(ladder, cum, (cum[1] + cum[2]) / 2)!; - expect(mid.lat).toBeCloseTo(48.015, 6); - expect(mid.lon).toBeCloseTo(7.82, 9); - }); - - it("clamps past the ends and degenerates safely", () => { - expect(pointAtDistance(ladder, cum, -5)).toEqual({ lat: 48.0, lon: 7.82 }); - expect(pointAtDistance(ladder, cum, cum[3] + 500)).toEqual({ lat: 48.03, lon: 7.82 }); - expect(pointAtDistance([], [], 0)).toBeNull(); - expect(pointAtDistance([ladder[0]], [0], 10)).toEqual({ lat: 48.0, lon: 7.82 }); - // A mismatched axis is a caller bug, answered with null rather than a wrong point. - expect(pointAtDistance(ladder, [0, 1], 0.5)).toBeNull(); - }); -}); - -describe("elevationAtDistance", () => { - const cum = cumulativeDistances(ladder); - - it("reads vertices exactly and interpolates within a segment", () => { - expect(elevationAtDistance(ladder, cum, 0)).toBe(100); - expect(elevationAtDistance(ladder, cum, cum[2])).toBe(300); - expect(elevationAtDistance(ladder, cum, (cum[1] + cum[2]) / 2)).toBeCloseTo(250, 6); - }); - - it("clamps past the ends", () => { - expect(elevationAtDistance(ladder, cum, -5)).toBe(100); - expect(elevationAtDistance(ladder, cum, cum[3] + 500)).toBe(400); - }); - - it("goes quiet inside a null gap instead of printing the profile's interpolated ramp", () => { - // The middle two points recorded no elevation: the drawn line spans them (samples at the - // outer two), but any hover between points 0→1, 1→2 or 2→3 has a null neighbour. - const gappy = [ - { ...ladder[0], ele: 100 }, - { ...ladder[1], ele: null }, - { ...ladder[2], ele: null }, - { ...ladder[3], ele: 400 }, - ]; - const gcum = cumulativeDistances(gappy); - expect(elevationAtDistance(gappy, gcum, gcum[1] / 2)).toBeNull(); - expect(elevationAtDistance(gappy, gcum, (gcum[1] + gcum[2]) / 2)).toBeNull(); - expect(elevationAtDistance(gappy, gcum, (gcum[2] + gcum[3]) / 2)).toBeNull(); - // The real samples at the ends still read. - expect(elevationAtDistance(gappy, gcum, 0)).toBe(100); - expect(elevationAtDistance(gappy, gcum, gcum[3])).toBe(400); - // On a null vertex itself the answer is the vertex's: nothing. - expect(elevationAtDistance(gappy, gcum, gcum[3] + 1), "clamp lands on a real end").toBe(400); - }); - - it("degenerates safely", () => { - expect(elevationAtDistance([], [], 0)).toBeNull(); - expect(elevationAtDistance([ladder[0]], [0], 10)).toBe(100); - expect(elevationAtDistance([{ ...ladder[0], ele: null }], [0], 0)).toBeNull(); - // A mismatched axis is a caller bug, answered with null rather than a wrong number. - expect(elevationAtDistance(ladder, [0, 1], 0.5)).toBeNull(); - }); -}); - -describe("nearestPointIndex", () => { - it("finds the closest vertex, ends included", () => { - expect(nearestPointIndex(ladder, 48.001, 7.82)).toBe(0); - expect(nearestPointIndex(ladder, 48.014, 7.821)).toBe(1); - expect(nearestPointIndex(ladder, 48.9, 7.82)).toBe(3); - }); - - it("is -1 for an empty track", () => { - expect(nearestPointIndex([], 48, 7.82)).toBe(-1); - }); -}); - -describe("isFullWindow", () => { - it("tells the reset state from a zoom", () => { - expect(isFullWindow(FULL_WINDOW)).toBe(true); - expect(isFullWindow([0, 0.999])).toBe(false); - expect(isFullWindow([0.001, 1])).toBe(false); - }); -}); diff --git a/builder/web/src/lib/device/elevation.ts b/builder/web/src/lib/device/elevation.ts deleted file mode 100644 index 59f54cdca9..0000000000 --- a/builder/web/src/lib/device/elevation.ts +++ /dev/null @@ -1,303 +0,0 @@ -/** - * The preview's elevation profile: distance-along-track on x, elevation on y, as one SVG path, plus - * the windowing math behind the preview's zoom. - * - * Pure geometry, shared by the route preview and the ride preview. Distance is equirectangular with - * a `cos(lat)` correction, which is metres-accurate at track scale. - * - * One distance axis for everything: {@link cumulativeDistances} runs over **all** points, including - * elevation-less ones, since they exist on the map polyline. A zoom window is a `[t0, t1]` pair of - * fractions of the total distance. - */ - -/** The minimum a profile is drawn from: with one point there is no distance axis at all. */ -const MIN_POINTS = 2; - -export interface ProfilePoint { - readonly lat: number; - readonly lon: number; - /** Metres; null where the source recorded none. */ - readonly ele: number | null; -} - -/** A zoom window over the track: fractions of the total distance, `0 <= t0 < t1 <= 1`. */ -export type ProfileWindow = readonly [number, number]; - -/** The whole track — the reset state, and the only window a profile-less preview ever has. */ -export const FULL_WINDOW: ProfileWindow = [0, 1]; - -/** The narrowest a window may get — 1% of the track, so a zoom can never collapse or invert. */ -export const MIN_WINDOW_SPAN = 0.01; - -export interface ElevationProfile { - /** `M … L …` path in a `width` × `height` viewBox, baseline-closed for an area fill. */ - readonly areaPath: string; - /** The same polyline without the baseline, for the stroke on top. */ - readonly linePath: string; - /** Extremes of the elevation *within the window*. */ - readonly minEle: number; - readonly maxEle: number; - /** The window's bounds and the whole track's length, metres — the axis captions' numbers. */ - readonly startM: number; - readonly endM: number; - readonly totalM: number; -} - -/** - * Cumulative ground distance at every point, metres — `result[0] === 0`, one entry per point, - * elevation-less points included. The shared axis: the profile's x, the map split's cut, and a - * waypoint tick's position are all fractions of `result[result.length - 1]`. - */ -export function cumulativeDistances(points: readonly ProfilePoint[]): number[] { - const cum: number[] = points.length ? [0] : []; - for (let i = 1; i < points.length; i++) { - cum.push(cum[i - 1] + groundDistanceM(points[i - 1], points[i])); - } - return cum; -} - -/** Is `window` (effectively) the whole track — the state with no gray on the map, no reset. */ -export function isFullWindow([t0, t1]: ProfileWindow): boolean { - return t0 <= 0 && t1 >= 1; -} - -/** - * Order and clamp a dragged pair of fractions into a valid window: inside `[0, 1]`, at least - * {@link MIN_WINDOW_SPAN} wide (grown symmetrically around the pair's centre, pushed back inside - * the track when the centre sits near an end). - */ -export function clampWindow(a: number, b: number): ProfileWindow { - let t0 = Math.max(0, Math.min(a, b)); - let t1 = Math.min(1, Math.max(a, b)); - if (t1 - t0 < MIN_WINDOW_SPAN) { - const centre = (t0 + t1) / 2; - t0 = centre - MIN_WINDOW_SPAN / 2; - t1 = centre + MIN_WINDOW_SPAN / 2; - if (t0 < 0) [t0, t1] = [0, MIN_WINDOW_SPAN]; - if (t1 > 1) [t0, t1] = [1 - MIN_WINDOW_SPAN, 1]; - } - return [t0, t1]; -} - -/** - * Scale a window by `factor` (>1 zooms out, <1 zooms in) about `centreT` — an absolute fraction - * of the track, normally the cursor's position — keeping the centre's relative position in the - * window so the ground under the cursor stays put. Clamped to `[0, 1]` and the minimum span. - */ -export function zoomWindow(window: ProfileWindow, factor: number, centreT: number): ProfileWindow { - const [t0, t1] = window; - const span = t1 - t0; - const next = Math.min(1, Math.max(MIN_WINDOW_SPAN, span * factor)); - // Where the anchor sits within the window (0 = left edge, 1 = right), kept across the scale. - const r = span > 0 ? (centreT - t0) / span : 0.5; - let n0 = centreT - r * next; - n0 = Math.max(0, Math.min(1 - next, n0)); - return [n0, n0 + next]; -} - -/** - * The point indices the map highlights for `window`: `[first, last]` such that the polyline - * `points[first..=last]` covers the window's distance span (the boundary segments are included - * whole — a cut mid-segment rounds outward, so the coral never falls short of the window). - * `[0, points.length - 1]` at the full window. - */ -export function windowIndexRange(cum: readonly number[], window: ProfileWindow): [number, number] { - const last = cum.length - 1; - if (last < 1) return [0, Math.max(0, last)]; - const total = cum[last]; - const d0 = window[0] * total; - const d1 = window[1] * total; - let first = 0; - while (first < last && cum[first + 1] <= d0) first++; - let end = last; - while (end > 0 && cum[end - 1] >= d1) end--; - return first <= end ? [first, end] : [end, first]; -} - -/** - * Slide the window along the track by `deltaT` (a fraction of the total distance), preserving its - * span — the Ctrl/⌘-drag pan. Clamped so the window never leaves `[0, 1]` and never resizes. - */ -export function panWindow(window: ProfileWindow, deltaT: number): ProfileWindow { - const [t0, t1] = window; - const span = t1 - t0; - const n0 = Math.max(0, Math.min(1 - span, t0 + deltaT)); - return [n0, n0 + span]; -} - -/** - * The `[lat, lon]` at distance `d` metres along the track — interpolated within the segment that - * contains it, clamped to the ends. The hover cursor's map position: one distance axis - * ({@link cumulativeDistances}) in, one point on the drawn polyline out. Null on an empty track. - */ -export function pointAtDistance( - points: readonly ProfilePoint[], - cum: readonly number[], - d: number, -): { lat: number; lon: number } | null { - if (points.length === 0 || cum.length !== points.length) return null; - if (points.length === 1) return { lat: points[0].lat, lon: points[0].lon }; - const target = Math.max(0, Math.min(d, cum[cum.length - 1])); - // Binary search for the segment holding `target` — hover runs per animation frame. - let lo = 0; - let hi = cum.length - 1; - while (lo + 1 < hi) { - const mid = (lo + hi) >> 1; - if (cum[mid] <= target) lo = mid; - else hi = mid; - } - const span = cum[hi] - cum[lo]; - const t = span > 0 ? (target - cum[lo]) / span : 0; - return { - lat: points[lo].lat + (points[hi].lat - points[lo].lat) * t, - lon: points[lo].lon + (points[hi].lon - points[lo].lon) * t, - }; -} - -/** - * The elevation at distance `d` metres along the track, or null where there is no honest number. - * Interpolated between the two track points bracketing `d`, and **only** when both carry real - * elevation. A null-elevation neighbour means `d` falls in a gap the source recorded nothing for: - * the profile's line spans such a gap, but a readout that printed that ramp would be inventing a - * number, so the label goes quiet instead. - */ -export function elevationAtDistance( - points: readonly ProfilePoint[], - cum: readonly number[], - d: number, -): number | null { - if (points.length === 0 || cum.length !== points.length) return null; - if (points.length === 1) return points[0].ele; - const target = Math.max(0, Math.min(d, cum[cum.length - 1])); - // The same binary search the map dot uses — hover runs per animation frame. - let lo = 0; - let hi = cum.length - 1; - while (lo + 1 < hi) { - const mid = (lo + hi) >> 1; - if (cum[mid] <= target) lo = mid; - else hi = mid; - } - const span = cum[hi] - cum[lo]; - const t = span > 0 ? (target - cum[lo]) / span : 0; - // Exactly on a point (the clamped ends, mostly): that point's own value is the honest - // answer, whatever its neighbour recorded. - if (t <= 0) return points[lo].ele; - if (t >= 1) return points[hi].ele; - const a = points[lo].ele; - const b = points[hi].ele; - if (a === null || b === null) return null; - return a + (b - a) * t; -} - -/** - * The index of the track point nearest `(lat, lon)`, by the same equirectangular metric the distance - * axis uses. A plain scan: preview tracks are thousands of points, and one pass per animation frame - * is nothing. `-1` on an empty track. - */ -export function nearestPointIndex(points: readonly ProfilePoint[], lat: number, lon: number): number { - const probe: ProfilePoint = { lat, lon, ele: null }; - let best = -1; - let bestM = Infinity; - for (let i = 0; i < points.length; i++) { - const m = groundDistanceM(points[i], probe); - if (m < bestM) { - bestM = m; - best = i; - } - } - return best; -} - -/** - * Build the profile for the window, or null where there is nothing honest to draw — fewer than two - * usable points in the window, or no elevation anywhere in it. A *flat* track still draws, because a - * flat line is a true statement; a track with no elevation data does not. - * - * The x axis is true distance along the whole track: points without elevation still advance it, they - * just contribute no sample. Where the window's edge cuts between two samples, the elevation at the - * cut is interpolated so the drawn span is exactly the window. - */ -export function elevationProfile( - points: readonly ProfilePoint[], - width: number, - height: number, - window: ProfileWindow = FULL_WINDOW, - pad = 2, -): ElevationProfile | null { - const cum = cumulativeDistances(points); - const totalM = cum.length ? cum[cum.length - 1] : 0; - if (totalM <= 0) return null; - - // The usable series: (distance, elevation) samples over the whole track. - const samples: Array<{ d: number; ele: number }> = []; - for (let i = 0; i < points.length; i++) { - const ele = points[i].ele; - if (ele !== null) samples.push({ d: cum[i], ele }); - } - if (samples.length < MIN_POINTS) return null; - - const startM = window[0] * totalM; - const endM = window[1] * totalM; - const drawn = windowSamples(samples, startM, endM); - if (drawn.length < MIN_POINTS) return null; - - let minEle = Infinity; - let maxEle = -Infinity; - for (const s of drawn) { - if (s.ele < minEle) minEle = s.ele; - if (s.ele > maxEle) maxEle = s.ele; - } - // A dead-flat profile gets a nominal band so the line sits mid-box instead of on an edge. - const span = Math.max(maxEle - minEle, 1); - - const w = width - 2 * pad; - const h = height - 2 * pad; - const x = (d: number) => pad + ((d - startM) / (endM - startM)) * w; - const y = (ele: number) => pad + (1 - (ele - minEle) / span) * h; - - const parts = drawn.map((s, i) => `${i === 0 ? "M" : "L"}${x(s.d).toFixed(1)} ${y(s.ele).toFixed(1)}`); - const linePath = parts.join(" "); - const baselineY = (height - pad).toFixed(1); - const first = drawn[0]; - const last = drawn[drawn.length - 1]; - const areaPath = `${linePath} L${x(last.d).toFixed(1)} ${baselineY} L${x(first.d).toFixed(1)} ${baselineY} Z`; - - return { areaPath, linePath, minEle, maxEle, startM, endM, totalM }; -} - -/** The samples inside `[d0, d1]`, with interpolated samples at any edge that cuts the series. */ -function windowSamples( - samples: ReadonlyArray<{ d: number; ele: number }>, - d0: number, - d1: number, -): Array<{ d: number; ele: number }> { - const out: Array<{ d: number; ele: number }> = []; - for (let i = 0; i < samples.length; i++) { - const s = samples[i]; - if (s.d < d0) { - const next = samples[i + 1]; - if (next && next.d > d0) out.push({ d: d0, ele: lerp(s, next, d0) }); - } else if (s.d > d1) { - const prev = samples[i - 1]; - if (prev && prev.d < d1) out.push({ d: d1, ele: lerp(prev, s, d1) }); - break; - } else { - out.push(s); - } - } - return out; -} - -function lerp(a: { d: number; ele: number }, b: { d: number; ele: number }, d: number): number { - const t = b.d === a.d ? 0 : (d - a.d) / (b.d - a.d); - return a.ele + (b.ele - a.ele) * t; -} - -/** Equirectangular ground distance in metres — fine at the scale of one track. */ -function groundDistanceM(a: ProfilePoint, b: ProfilePoint): number { - const R = 6_371_000; - const toRad = Math.PI / 180; - const dLat = (b.lat - a.lat) * toRad; - const dLon = (b.lon - a.lon) * toRad * Math.cos(((a.lat + b.lat) / 2) * toRad); - return Math.sqrt(dLat * dLat + dLon * dLon) * R; -} diff --git a/builder/web/src/lib/device/library.test.ts b/builder/web/src/lib/device/library.test.ts deleted file mode 100644 index 480be8b844..0000000000 --- a/builder/web/src/lib/device/library.test.ts +++ /dev/null @@ -1,523 +0,0 @@ -/** - * The managed ride library's pull, end to end against the simulated device. - * - * Each test here is a *library* assertion rather than a call-count assertion: what the library holds - * afterwards, and whether the files behind those rows exist. The failure modes this feature has are - * not "the wrong function was called" — they are "the app believes it has a rider's only copy of a - * ride and it does not". - * - * The real durable write is Rust (`builder/desktop/src/rides.rs`) and is tested there, against the - * real filesystem, with the power cut between `write()` and `fsync()`. What *this* file owns is the - * other half of the same claim: a ride only counts as held once the library's `import()` has - * resolved. {@link RecordingLibrary} is a fake, not a mock of the Tauri boundary: it holds real - * state, it can fail, and the tests read its state rather than its call log. - * - * A possession acknowledgement is deliberately absent from this cable surface: it changes no object, - * so it has no store meaning and USB does not carry it. The ordering discipline it needed — an - * import resolves only after fsync — is kept regardless, because it is what makes - * {@link PullReport} true. - */ - -import { existsSync, readFileSync } from "node:fs"; -import { dirname, join } from "node:path"; -import { fileURLToPath } from "node:url"; -import { beforeAll, describe, expect, it } from "vitest"; - -import { initConvert } from "../convert/bridge"; -import type { FlatStoreClient } from "../usb/client"; -import { flatDevice } from "../usb/flat-device"; -import { loadFlatDevice } from "../../../test-support/flat-device/load"; -import { encodeRideObject, type RideObject, type RidePoint } from "../usb/objects"; -import { EntryFlags, ObjectKind } from "../usb/protocol"; -import { - PREVIEW_POINTS, - previewTrack, - pullRide, - pullRides, - trackPath, - type LibraryRide, - type LibraryView, - type RideImport, - type RideLibrary, -} from "./library"; -import { rideAccess, rideKey, rideScope, type RideScope } from "./rides"; -import type { JobContext, JobPhase } from "./progress"; - -beforeAll(async () => { - const wasm = join(dirname(fileURLToPath(import.meta.url)), "..", "core", "pkg", "obc_builder_bridge_bg.wasm"); - if (!existsSync(wasm)) { - throw new Error(`the wasm bridge is not built (${wasm} missing). Run \`npm run build:wasm\`.`); - } - await initConvert(readFileSync(wasm)); - await loadFlatDevice(); -}); - -/** The loopback link's default serial, and the two cards these tests swap between. */ -const SERIAL = "0011223344556677"; -const CARD_A = "8f2c41d96b074ea3b1559c207de83466"; -const CARD_B = CARD_A.slice(0, 8) + "00000000000000000000abcd"; - -function ctx(): JobContext { - const phases: JobPhase[] = []; - return { - signal: new AbortController().signal, - cancel() {}, - phase: (phase) => phases.push(phase), - progress: () => undefined, - }; -} - -/** A ride the device would have recorded: a short, real-looking track through the Black Forest. */ -function rideObject(name: string, startTime: number, points = 24): RideObject { - const track: RidePoint[] = []; - for (let i = 0; i < points; i++) { - track.push({ - tMs: i * 5_000, - latMicrodegrees: Math.round((47.9 + i * 0.0012) * 1e6), - lonMicrodegrees: Math.round((7.85 + i * 0.0009) * 1e6), - elevationM: 300 + i * 4, - segmentStart: i === 0, - hrBpm: 140 + (i % 7), - cadenceRpm: 80, - powerW: null, - }); - } - return { - version: 6, - isDemo: false, - effortLimits: { maxHrBpm: null, ftpW: null }, - name, - startTime, - distanceM: 12_340, - movingTimeS: 2_700, - avgSpeedCms: 457, - climbM: 96, - descentM: 96, - avgHr: 143, - maxHr: 171, - avgCadence: 80, - avgPower: null, - maxPower: null, - energyKj: null, - bikeType: 0, - trip: null, - points: track, - }; -} - -/** - * A ride library that keeps real state and can be made to fail. - * - * Not a mock of the `invoke()` calls — the tests below never look at what was called. It models the - * one property the whole feature hangs off: **`import()` resolving is what makes a ride held**. A - * rejected import leaves nothing behind, exactly as a power cut before fsync does on the real thing. - */ -class RecordingLibrary implements RideLibrary { - readonly rides = new Map(); - /** Every library call, in order — read by the ordering assertions and nothing else. */ - readonly events: string[] = []; - /** Keys whose import must fail, as a crash between write and fsync would. */ - failFor = new Set(); - folder = "/library"; - - async view(): Promise { - return { folder: this.folder, isDefault: true, rides: [...this.rides.values()] }; - } - - async import(ride: RideImport): Promise<{ ride: LibraryRide; imported: boolean }> { - const key = `${ride.serial}:${ride.storeId}:${ride.objectId}`; - if (this.failFor.has(key)) { - this.events.push(`import-failed:${ride.objectId}`); - throw new Error("simulated power loss between write() and fsync()"); - } - const held = this.rides.get(key); - if (held) { - // The real thing rewrites the files it is missing, keeps the names and keeps - // `importedAt`, and reports `imported: false` — this is the same ride arriving again, - // not a new one. Mirrored here so the pull's repair path is exercised rather than - // stubbed. - const repaired = { ...held, present: true, gpxPresent: true }; - this.rides.set(key, repaired); - this.gpx.set(key, ride.gpx); - this.objects.set(key, ride.object); - this.events.push(held.present ? `import-noop:${ride.objectId}` : `repaired:${ride.objectId}`); - return { ride: repaired, imported: false }; - } - const landed: LibraryRide = { - key, - serial: ride.serial, - storeId: ride.storeId, - objectId: ride.objectId, - name: ride.name, - startTime: ride.startTime, - distanceM: ride.distanceM, - movingTimeS: ride.movingTimeS, - climbM: ride.climbM, - points: ride.points, - bytes: ride.object.length, - crc32: ride.crc32, - importedAt: 1_700_000_000 + this.rides.size, - // The split layout: the archive lives in app data, only the GPX in the visible folder. - ridePath: `/app-data/ride-archive/${ride.objectId}.obcride`, - gpxPath: `${this.folder}/${ride.objectId}.gpx`, - track: ride.track, - present: true, - gpxPresent: true, - }; - this.rides.set(key, landed); - this.gpx.set(key, ride.gpx); - this.objects.set(key, ride.object); - this.events.push(`imported:${ride.objectId}`); - return { ride: landed, imported: true }; - } - - readonly gpx = new Map(); - readonly objects = new Map(); - - async readObject(key: string): Promise { - const bytes = this.objects.get(key); - if (!bytes) throw new Error(`no ride ${key}`); - return bytes; - } - - async writeGpx(key: string, gpx: string): Promise { - this.gpx.set(key, gpx); - return `${this.folder}/${key}.gpx`; - } - - async reveal(): Promise {} - async chooseFolder(): Promise { - return null; - } - - /** A ride the rider deleted in the file manager: the record stays, the bytes are gone. */ - loseFile(key: string): void { - const held = this.rides.get(key); - if (held) this.rides.set(key, { ...held, present: false }); - } - - /** Keys whose file is really there — "what is on the disk", which is what a pull asks. */ - held(): string[] { - return [...this.rides.values()].filter((ride) => ride.present).map((ride) => ride.key).sort(); - } -} - -/** A live client + device pair over the loopback pipe, plus the narrowed source the pull is given. */ -function connect(options: { storeId?: string } = {}) { - const rig = flatDevice({ storeId: options.storeId ?? CARD_A }); - return { ...rig, source: rideAccess(rig.client) }; -} - -/** - * The connected device's `(serial, era)`, derived exactly as the UI derives it — over the two reads - * every connection already does. Re-read rather than remembered, because that is the point of the - * era: a card swap changes it under a running app. - */ -async function scopeNow(client: FlatStoreClient): Promise { - const page = await client.listPage({}); - return rideScope(await client.deviceInfo(), { storeId: page.storeId, commitSequence: page.commitSequence }); -} - -/** - * Put a ride on the device's card, catalog entry and all. - * - * The store assigns the id, so a caller that needs one reads it off the entry that comes back. - * Seeding in order gives 1, 2, 3 — which is what the keys below are written against. - */ -function seedRide(device: ReturnType["device"], name: string, startTime: number) { - const bytes = encodeRideObject(rideObject(name, startTime)); - const entry = device.seed({ kind: ObjectKind.Ride, displayName: name, bytes }); - return { entry, bytes }; -} - -// --- acceptance ---------------------------------------------------------------- - -describe("pulling rides into the library", () => { - it("pulls every ride the card holds and deduplicates them by the id the card assigned", async () => { - // The ids are the store's, not this test's. That a key survives an id above 2^53 is pinned - // where the key is built (`rides.test.ts`, "keys the complete card identity and decimal u64 - // object id"); what is pinned here is that a pull uses that key and repeats nothing. - const { device, client, source, close } = connect(); - try { - const scope = await scopeNow(client); - const seeded = ["Dawn", "Noon", "Dusk"].map((name) => seedRide(device, name, 1_700_000_000).entry); - const ids = seeded.map((entry) => entry.objectId); - const library = new RecordingLibrary(); - const first = await pullRides(source, library, scope, ctx()); - expect(first.failed).toEqual([]); - expect(first.imported.map((ride) => ride.objectId)).toEqual(ids); - expect(library.held()).toEqual(ids.map((id) => `${SERIAL}:${CARD_A}:${id}`).sort()); - const second = await pullRides(source, library, scope, ctx()); - expect(second.imported).toEqual([]); - expect(second.alreadyHeld).toBe(3); - } finally { - await close(); - } - }); - - it("is idempotent: a second pull downloads nothing, duplicates nothing and re-stamps nothing", async () => { - const { device, client, source, close } = connect(); - try { - const scope = await scopeNow(client); - seedRide(device, "Dawn Patrol", 1_700_000_000); - seedRide(device, "Gravel Hour", 1_700_100_000); - const library = new RecordingLibrary(); - - const first = await pullRides(source, library, scope, ctx()); - expect(first.listed).toBe(2); - expect(first.imported.map((ride) => ride.objectId)).toEqual([1n, 2n]); - const stamps = [...library.rides.values()].map((r) => [r.key, r.importedAt] as const); - - const second = await pullRides(source, library, scope, ctx()); - expect(second.imported).toEqual([]); - expect(second.alreadyHeld).toBe(2); - expect(library.rides.size).toBe(2); - // The ride files were never touched a second time. - expect(library.events.filter((e) => e.startsWith("imported:"))).toEqual(["imported:1", "imported:2"]); - expect([...library.rides.values()].map((r) => [r.key, r.importedAt] as const)).toEqual(stamps); - } finally { - await close(); - } - }); - - it("skips a ride the device is still recording, and names it in the report", async () => { - // A `GET` of a `RECORDING` entry is refused — its length and CRC are zero until the commit - // that ends it — so there is nothing to copy yet. Counting it is what lets the page say "one - // ride is still being recorded" rather than silently listing fewer rides than the device has. - const { device, client, source, close } = connect(); - try { - const scope = await scopeNow(client); - seedRide(device, "Finished", 1_700_000_000); - device.seed({ kind: ObjectKind.Ride, displayName: "Still going", flags: EntryFlags.Recording }); - const library = new RecordingLibrary(); - - const report = await pullRides(source, library, scope, ctx()); - - expect(report.recording).toBe(1); - expect(report.listed, "the recording ride is not something the pull could act on").toBe(1); - expect(report.imported.map((ride) => ride.objectId)).toEqual([1n]); - expect(report.failed).toEqual([]); - expect(library.held()).toEqual([rideKey(scope, 1n)]); - } finally { - await close(); - } - }); - - it("leaves a ride out of the library when its durable write fails, and fetches it again next time", async () => { - const { device, client, source, close } = connect(); - try { - const scope = await scopeNow(client); - seedRide(device, "Landed", 1_700_000_000); - seedRide(device, "Interrupted", 1_700_100_000); - seedRide(device, "Also landed", 1_700_200_000); - const library = new RecordingLibrary(); - library.failFor.add(rideKey(scope, 2n)); - - const report = await pullRides(source, library, scope, ctx()); - - expect(report.failed.map((f) => f.objectId)).toEqual([2n]); - expect(report.imported.map((r) => r.objectId)).toEqual([1n, 3n]); - expect(library.held()).toEqual([rideKey(scope, 1n), rideKey(scope, 3n)].sort()); - - // …and the next pull, with the write working, fetches ride 2 and only then holds it. - library.failFor.clear(); - const retry = await pullRides(source, library, scope, ctx()); - expect(retry.imported.map((r) => r.objectId)).toEqual([2n]); - expect(library.held()).toHaveLength(3); - } finally { - await close(); - } - }); - - it("imports both rides when a card swap recycles an object id", async () => { - // A re-initialized card mints a new `StoreId` and starts its ids at 1 again, so a *different* - // ride lands on id 1. A bare-id library would hold one row and answer "up to date" forever. - const library = new RecordingLibrary(); - - const first = connect({ storeId: CARD_A }); - const oldEra = await scopeNow(first.client); - expect(oldEra.storeId).toBe(CARD_A); - seedRide(first.device, "Old era ride", 1_700_000_000); - await pullRides(first.source, library, oldEra, ctx()); - expect(library.rides.size).toBe(1); - await first.close(); - - const second = connect({ storeId: CARD_B }); - try { - const newEra = await scopeNow(second.client); - expect(newEra.storeId).toBe(CARD_B); - expect(newEra.serial).toBe(oldEra.serial); - seedRide(second.device, "New era ride", 1_800_000_000); - - const after = await pullRides(second.source, library, newEra, ctx()); - expect(after.imported.map((r) => r.name)).toEqual(["New era ride"]); - // Two rows, two keys, one object id. - expect([...library.rides.keys()].sort()).toEqual( - [`${SERIAL}:${CARD_A}:1`, `${SERIAL}:${CARD_B}:1`].sort(), - ); - expect(new Set([...library.rides.values()].map((r) => r.objectId))).toEqual(new Set([1n])); - } finally { - await second.close(); - } - }); - - it("re-downloads a ride whose file the rider deleted, keeping its original importedAt", async () => { - // "Do I already have it" is a question about the disk, not about the index: a record whose - // file is gone is not a durable copy, so the ride is fetched again — and it is a repair - // rather than an import, because the rider first got it long ago. - const { device, client, source, close } = connect(); - try { - const scope = await scopeNow(client); - for (const [at, name] of ["One", "Two", "Three"].entries()) { - seedRide(device, name, 1_700_000_000 + at * 1000); - } - const library = new RecordingLibrary(); - await pullRides(source, library, scope, ctx()); - const firstStamp = library.rides.get(rideKey(scope, 2n))!.importedAt; - - library.loseFile(rideKey(scope, 2n)); - const again = await pullRides(source, library, scope, ctx()); - - expect(again.imported).toEqual([]); - expect(again.repaired.map((r) => r.objectId)).toEqual([2n]); - expect(again.repaired[0].importedAt).toBe(firstStamp); - expect(again.alreadyHeld).toBe(2); - expect(library.held()).toHaveLength(3); - } finally { - await close(); - } - }); - - it("refuses to import anything from a device whose card identity it could not read", async () => { - // The fail-closed posture: without both halves of the era, an id from this device cannot be - // told apart from another device's, so nothing is keyed and nothing is copied. A missing - // StoreId never shares an identity with a readable card. - const { device, source, close } = connect(); - try { - seedRide(device, "Unkeyable", 1_700_000_000); - const library = new RecordingLibrary(); - await expect(pullRides(source, library, { serial: SERIAL, storeId: null }, ctx())).rejects.toMatchObject({ - name: "RideLibraryError", - code: "no-scope", - }); - await expect(pullRides(source, library, { serial: "", storeId: CARD_A }, ctx())).rejects.toThrow( - /card identity/, - ); - expect(library.rides.size).toBe(0); - } finally { - await close(); - } - }); - - it("stores a GPX the device itself would have written, and the object it sent", async () => { - const { device, client, source, close } = connect(); - try { - const scope = await scopeNow(client); - const { bytes } = seedRide(device, "Schauinsland", 1_700_000_000); - const library = new RecordingLibrary(); - await pullRides(source, library, scope, ctx()); - - const key = rideKey(scope, 1n); - // The archive is the device's bytes, unaltered — which is what makes the library - // lossless while `track_to_gpx` still omits `