Skip to content

chore(release): release candidate 1 on Unity 6000.6.9f1, Quest 3/3S first - #23

Merged
mrhegemon merged 69 commits into
mainfrom
integrate/release-rc1
Nov 13, 2026
Merged

mrhegemon merged 69 commits into
mainfrom
integrate/release-rc1

Conversation

@mrhegemon

Copy link
Copy Markdown
Member

Summary

Release candidate 1 for Companion Scan: the Quest capture app, its CV server and the web client. This branch merges the five release-blocker fix branches into main and moves the Unity project from 6000.3.10f1 to 6000.6.9f1, Quest-first: the app now targets only Quest 3 and Quest 3S, at Android API level 34, on Meta XR SDK 209.0.0. The CV server requires a bearer token on every route, and its image builds and starts again on Python 3.11.

  • 69 commits on top of main @ a011a4b: 41 from the fix branches, 5 --no-ff merges and 23 integration commits (the Unity upgrade, overlaps reconciled by hand, and fixes found in review).
  • 0 commits behind main. git merge-tree reports a clean merge whose tree equals the branch tree.
  • The builds and tests under "Verification" ran on the head commit, 1c594c9.
  • Known issue, not fixed here: the CV server's bounding boxes are wrong on main. GroundingDINO returns (cx, cy, w, h) boxes and the server treats them as (x1, y1, x2, y2). See "Known issues".

Fix branches merged

Branch Commits Merged in
fix/quest-build-blockers 2 c043e75
fix/server-config-and-store 9 1246a5b
fix/cv-server-release 8 1927fed
ci/build-and-docs 8 61571f9
fix/licensing-notices 14 2aba8a3

None of the merges had textual conflicts. Overlaps reconciled by hand:

  • The Meta packages are listed one by one (core, audio, haptics, platform, MR Utility Kit) instead of com.meta.xr.sdk.all, so the Voice and Interaction SDKs stay out.
  • unity-mcp stays pinned to v10.3.0 (aa5fc638), which already compiles on 6000.6.
  • The server branch made the token mandatory while the Quest app sent none; 5e68462 makes the app send it.

The Unity upgrade was redone on top of the merges rather than merged from its own branch.

Release blockers fixed, by theme

Unity 6000.6.9f1 upgrade

  • f3d6f3f: the editor upgrade to 6000.6.9f1 (8c45277fb9c5) with the editor-recommended packages (URP 17.6.0, OpenXR 1.18.0, Meta OpenXR 2.6.1, XR Management 4.7.0).
  • cd21533, 5c24922: the project compiles on 6000.6. Meta XR SDK 85.0.0 to 209.0.0, UnityGLTF 2.18.8 to 2.20.0, and the vendored NaughtyAttributes editor code uses GetEntityId.
  • 92f261a, 926582c: the 6000.6 re-serialization. 95c6b73: README, THIRD_PARTY.md and NOTICE.md record the new versions.
  • 5a7ab74, Burst: an earlier 6000.6 APK had no Burst code. The Meta Voice SDK threw while Unity created the build callbacks, so Unity skipped the Burst AOT postprocessor and OpenXR's library stripping and still reported success. The Voice SDK is gone. Command-line and menu Quest builds now fail if any build callback cannot be created, or if the APK or AAB has no lib_burst_generated.so.
  • edd53cf: drops the android.uniquePackageNames=false Gradle workaround. No duplicate AAR namespaces remain.

Quest 3 and 3S, permissions, store builds

  • 4e86448: supported devices are quest3|quest3s only (manifest, OpenXR Meta Quest feature, OVRProjectConfig). The Passthrough Camera API needs those headsets.
  • a2ed494: every Android build must target exactly API level 34. The Quest workflow passes it to GameCI too.
  • 044c7b1: camera image access is on again under Meta OpenXR 2.6.1. Without it the capture pipeline gets no frames.
  • 442ebce (corrects df2cf11): the AR capture camera starts only after horizonos.permission.HEADSET_CAMERA and android.permission.CAMERA are granted, on the path Quest builds actually use (MobileCameraProvider on AR Foundation). Before, the camera subsystem checked the permission once, before it was granted, so first-launch capture could get no frames until the app restarted. That analysis comes from the code; it has not been checked on a headset. OVRManager's duplicate startup request is off. CAMERA stays, because Meta OpenXR's native camera code opens the cameras through the NDK Camera2 API.
  • 4d73242: USE_SCENE is requested when a feature first needs it. 65e566c: the manifest drops Meta permissions the app does not use (eye tracking, IoT map data, colocation discovery, boundary visibility).
  • f700fcb: the Immersive Debugger is limited to debug builds. e685834: Meta's DevAgentSettings asset, which holds the build machine's LAN address and AgentBridge token, stays out of player builds.
  • bf51861, 82e10bd: the Meta Quest build profile uses the shipped package ID, com.CompanionIntelligence.CompanionCapture.
  • b034aae: a Meta Horizon Store entitlement check behind the COMPANIONSCAN_HORIZON_STORE define. The store app ID ships empty.
  • 2864a2e: release signing from KEYSTORE_PATH, KEYSTORE_PASS, KEY_ALIAS and KEY_PASS. -release fails without all four, no keystore is created, and keystores are gitignored. versionCode is MAJOR*1000000 + MINOR*1000 + PATCH, so 0.1.0 builds as 1000. e315631: -aab builds an Android App Bundle.

Quest app networking

  • e42c740: no default CV server. Builds no longer point at a developer's personal host. The URL is entered in the headset (Settings panel, system keyboard) and stored in PlayerPrefs.
  • 31b4f5d, 34fafbb: HTTPS by default. Plain HTTP only in development builds, and on Android only to listed LAN hosts.
  • 5e68462: the app sends the CV server's token as a Bearer header. The token is entered in the headset with the secure keyboard and stored only in PlayerPrefs. 401, 403, 413 and 503 are not retried, and their errors say what to fix.
  • 31f68b3: the Vite TLS defaults no longer name a personal host.

CV server

  • c4ba4d5, 417f405: a bearer token (CV_SERVER_API_TOKEN) on every route, /v1/health included. The server will not start without a configured token, and protected routes answer 503 if none is set.
  • 7ca5815: with TLS on, HTTPS on :443 only, with no plain-HTTP :8000 listener. One TLS file without the other stops the container.
  • b2b2be5: a 32 MiB cap on request bodies (413) and a 16 MiB cap on WebSocket messages.
  • 8324e4e, 1c594c9: the image builds and starts again. On main it cannot build, because Pillow 13 needs Python 3.11. Python 3.11.18 now comes from the deadsnakes PPA, because Ubuntu 22.04's python3.11 is 3.11.0rc1, which crashed importing timm. transformers is back at 4.40.1, because 5.10.1 needs a newer torch than 2.5.1, the last CUDA 12.1 release. torch, flash-attn, GroundingDINO and SAM 2 are pinned. The CUDA base image is unchanged.
  • ec5fdd6: model files come from pinned URLs with size and SHA-256 checks. 892cb8c: compose takes the TLS paths and the token from configuration. 43dfda4: CUDA kernels for Ampere through Hopper. 8f62614: entrypoint.sh stays LF. 8759f70: plain pytest works. 3044f7b, ad4b827: a manual GHCR publish workflow.

CI and docs

  • 5abf86e: every workflow action is pinned to a commit SHA.
  • a04fd61: Unity Tests runs the unit tests on pull requests to main, on the self-hosted GPU runner; pull requests from forks are skipped. 7ad7b30, 78698e2: the Unity version comes from ProjectVersion.txt, with warnings for docs that drift.
  • d89049e: a Quest APK build and draft-release workflow (GameCI; manual runs and v* tags).
  • 21e6b73, 44e0a49, 4b70179: docs/SIDELOAD.md, README sections on CI, secrets and releases, and docs/qa-ci.md as the jobs run now.

Licensing and provenance

  • 36fe595, e4faa1c: drop the Meta Voice SDK (its Wit.ai licence) and the unused Interaction SDK.
  • 2a8d860, 4e6e097, 8558cb0: generated synthetic fixtures replace unlicensed web photos; the EmojiOne sprites and an unsourced digit atlas are removed, along with orphan metas.
  • e86527d: a generated placeholder launcher icon replaces icons that were unlicensed photos.
  • fa4d7b9, d6d8175: hardware statistics are off in Player Settings and in the Meta Quest build profile.
  • 281c7a9, 511777f, 5f025c4: MCP for Unity and the Performance Testing run files stay out of player builds.
  • 3a33ff8, fa0d5fb, 6691f96, 8b92012: NOTICE.md and THIRD_PARTY.md are rewritten from a full licence inventory and match the 6000.6.9f1 APK's native libraries.

Verification

Everything below ran locally on Windows, on 1c594c9 with Unity 6000.6.9f1 (8c45277fb9c5), except the one item marked as an earlier check. "Baseline" means the same test suites before this branch's changes.

  • Compile: 0 errors in the editor and in the Android player.
  • EditMode: 124/124 passed (baseline 1/1).
  • PlayMode without a CV server: 17 passed, 1 failed, 24 skipped of 42, equivalent to the baseline's 19/42.
    • The failure is the rendered-frame test, XrSceneScreenshotTests.QaXrScene_CapturesControllersAndAnchors: WaitForEndOfFrame never fires in batch mode.
    • 22 tests now skip when no server URL is set. On the baseline, 20 of them failed and 2 passed vacuously. 2 more were skipped on the baseline too.
  • PlayMode against a live CV server built from this branch: all 164 requests from Unity returned 200 (no 401 or 413), so the client token and the size cap work. Tests: 26 passed, 14 failed, 2 skipped. The failures come from bugs already on main (see "Known issues").
  • Quest APK (CommandLineBuild.BuildAndroidQuest): exit 0, 79,637,525 bytes (sha256 e43a609e…).
    • targetSdk 34, minSdk 32, versionCode 1000, supportedDevices quest3|quest3s.
    • Permissions: HAND_TRACKING, USE_ANCHOR_API, USE_SCENE, HEADSET_CAMERA, CAMERA, INTERNET, USE_PASSTHROUGH_CAMERA.
    • The passthrough feature is required and android.hardware.camera* is not. Camera image support is on.
    • Signed with the debug key.
  • Burst: lib_burst_generated.so is a 405,712-byte AArch64 ELF with 449 function symbols, identical in the APK and the AAB. The build log confirms that every build callback was created.
  • AAB (-aab): exit 0, 75,519,071 bytes (sha256 99ef499f…), Burst present.
  • -release without the four signing variables exits 1 with the expected message.
  • Content scan of the 745 APK entries, the 756 AAB entries, the 1,150 blobs of the head tree and the 250 blobs added since main: no host name or IP address of the build machine, and no DevAgentSettings token or address.
  • CV server image: docker build from the branch head exits 0 (16 min).
    • In the image, flash-attn and the GroundingDINO and SAM 2 compiled extensions run on the GPU (RTX 4080 Laptop GPU).
    • pytest: 45 passed, 5 skipped. With the model weights: 49 passed, 1 skipped (test_florence is skipped unconditionally).
    • Through the real entrypoint: /v1/health answers 401 without the token and 200 with it. /v1/detect, /v1/segment and /v1/florence answer 200.
  • Earlier check: entrypoint.sh, which has not changed since b2b2be5, was run during review on an earlier commit with a stub uvicorn: HTTPS only on :443 when both TLS files exist, HTTP only on :8000 when neither does, and exit 1 when only one exists or when TLS is required but missing. --ws-max-size is passed.
  • git merge-tree recomputes all five merges without conflicts, and each result equals the committed tree.
  • Anything on a Quest 3 or 3S. No headset was attached.
  • The GitHub workflows (Unity Tests, Quest APK Build, cv-server publish). None has run on this branch.

Tip for rerunning PlayMode against a live server in batch mode: pass -stackTraceLogType None. Without it the -nographics log reached 2.5 GB.

Known issues (not fixed by this PR)

CV server bounding boxes, already on main

GroundingDINO's predict() returns normalized (cx, cy, w, h) boxes. _to_absolute_boxes in cv-server/app/pipelines/grounding_dino.py (/v1/detect) and in cv-server/app/pipelines/grounded_sam2.py (/v1/segment) scales them as if they were (x1, y1, x2, y2). This PR does not change either file.

  • On the synthetic closet fixture, 24 of the 25 returned boxes have x2 < x1 or y2 < y1 (27 of 29 on the pantry fixture). Read as (cx, cy, w, h), every box lies inside the image.
  • /v1/segment prompts SAM 2 with these wrong boxes. Its per-pixel Python RLE made segment requests on the closet, laundry-room and pantry fixtures take 13.7 to 58.6 s, far past the Unity client's default 6 s timeout, so requests fail in a cascade.
  • A prepared follow-up patch converts the boxes and vectorizes the RLE. With it, those segment requests take 0.6 s or less, cv-server pytest gives 56 passed and 1 skipped, and the live PlayMode run goes from 26 passed / 14 failed to 37 passed / 3 failed (2 skipped). Whether it lands, as a separate PR, is the owner's call.

Besides the rendered-frame test, two live PlayMode failures remain with that patch. Both come from code that is already on main:

  • PipelineIntegrationTests.GroundingDINO_Detect_BboxesAreNormalized expects normalized boxes, but the server returns pixels.
  • QaSceneImageProcessingTests.QaScene_ProcessAllImages_Render2DAnd3D counts child objects in the same frame as BBoxRenderer.Clear(), whose Destroy is deferred.

Open items and owner actions

Not tested on hardware

  • Nothing in this release candidate has run on a Quest 3 or 3S. Check on a headset before release:
    • first-launch capture with the new permission flow (442ebce), including the deny, dismiss and grant-later-in-settings paths;
    • entering the server URL and the token in the headset;
    • whether capture works without android.permission.CAMERA. Removing it would also need tools:node="remove", because Meta OpenXR adds it back while camera image support is on.

Signing and build artifacts

  • The APK and AAB above are signed with the debug key. Create a release keystore (outside the repository) and build with -release and the four KEYSTORE_*/KEY_* variables. For CI, set the ANDROID_KEYSTORE_* secrets.
  • Distribute builds made in CI, or with a Unity editor installed outside a user profile. Local IL2CPP builds embed the editor's install path in libil2cpp.so, and on this build machine that path contains the Windows user name.
  • The Quest APK Build workflow uses GameCI's own build method, so the Burst and build-callback checks from 5a7ab74 do not run there. A CI APK could ship without Burst code while the job reports success. Checking the APK for lib/arm64-v8a/lib_burst_generated.so in the workflow's staging step would close that gap.

CI on this pull request

  • Opening this PR starts Unity Tests on the self-hosted Windows GPU runner. When this was written, the repository had no Actions secrets and no repository-level runner (organization runners were not checked). The check cannot pass until the owner adds UNITY_LICENSE (or UNITY_SERIAL), UNITY_EMAIL and UNITY_PASSWORD and brings a runner online. The README's "Continuous integration and releases" section lists every secret.

CV server

  • transformers 4.40.1 has published advisories (about 22 CVEs, fixed in 4.48 to 5.10), including code execution through a crafted model config or Trainer. Moving to 5.x needs torch 2.7 or later and a new CUDA base image, and Dependabot will propose the bump again. Shipping 4.40.1 needs the owner's sign-off.
  • Florence-2 is loaded with trust_remote_code=True from an unpinned revision, bert-base-uncased is downloaded from an unpinned revision, and the deadsnakes python3.11 package version is not pinned.
  • Publishing a built image redistributes NVIDIA CUDA and cuDNN, and LGPL FFmpeg and Qt (THIRD_PARTY.md, open item 3).
  • cv-server/tests/conftest.py still has a docstring saying /v1/health needs no token. The tests themselves require it.

Web client

  • The web client sends the token only through the Vite dev proxy. The documented production route (serve web/dist over HTTPS and open it in the Quest Browser) gets 401 on every call, and so does a server URL set in the web Settings panel. The dev proxy also targets http://localhost:8000, which does not listen when TLS is on.

Store, privacy and licensing decisions

  • Still open: a privacy policy that covers camera and room-scan data, retention and deletion of uploads on the CV server, the Horizon Store app ID (HorizonStoreConfig ships empty), and the history purge decision (tracked separately).
  • THIRD_PARTY.md section 6 lists the licensing items for the owner. They include showing the notices in the app and in web/dist, replacing the placeholder launcher icon, asking Unity to confirm the terms of the Perfect DOS VGA 437 font, and keeping hardware statistics off in any new build profile.
  • With "Enable Only In Debug Build" on, the Immersive Debugger still started its log cache in release builds on Meta XR SDK 85 (f700fcb). That has not been re-checked on SDK 209.

Merge method

Please use Create a merge commit, not squash or rebase.

  • The branch keeps its five --no-ff merges of the fix branches. Its commit messages cite nine of the branch's own commits by hash; for example, 442ebce corrects df2cf11, and cd21533 refers to 36fe595 and e4faa1c. A squash or rebase merge would leave those hashes off main. A rebase merge would also rewrite every hash and flatten the merges.
  • The files on the branch cite only commits that are already on main (a862495 and ebd1535 in THIRD_PARTY.md), so the docs stay correct with any method.
  • The branch is 0 commits behind main, so the merge commit is clean.
  • If it is squashed anyway, keep integrate/release-rc1 on GitHub afterwards (automatic branch deletion is off), so the cited hashes stay fetchable.
  • Tag the release from the merge result or 1c594c9, not from an intermediate commit. The CV server image built from 926582c, for example, cannot load its models.
  • Six commit messages (cd21533, 5c24922, 044c7b1, e685834, 92f261a and 926582c) cite commits of a local upgrade/unity-6000.6.9f1 branch whose changes were ported, not merged. That branch is not on GitHub, so those hashes will not resolve there.

🤖 Generated with Claude Code

mrhegemon and others added 30 commits November 12, 2026 10:38
The Meta Quest build profile overrode the Android application identifier
with com.companionintelligence.CompanionCapture while the global Player
Settings (the identifier that has actually been built and installed) use
com.CompanionIntelligence.CompanionCapture. Builds from the profile would
therefore install as a different app with separate PlayerPrefs and
permissions. Align the profile with the global identifier.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…profile

The Meta Quest build profile set "Allow downloads over HTTP" to Not
allowed, so UnityWebRequest refused every http:// URL and a LAN CV
server without TLS could never be reached, even from a development
build. Match the global Player Settings value (Allowed in development
builds). Release builds stay HTTPS-only; which hosts may use cleartext in
a development build is restricted separately by the Android network
security config.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The README says to run `pytest` from cv-server/, but without the package
root on sys.path test collection failed with ModuleNotFoundError: app.
Add a pytest.ini that sets pythonpath and testpaths, and ignore a local
.venv and test caches.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The API had no authentication, so anyone who could reach the port could
run inference and write glTF uploads to disk.

Add an ASGI middleware that checks `Authorization: Bearer <token>`
against CV_SERVER_API_TOKEN (comma-separated to allow rotation) with a
constant-time comparison. It wraps the whole app, so /docs, /openapi.json
and future routes are covered; only /v1/health stays public. WS
/v1/stream accepts the same header, or a ["bearer", <token>] subprotocol
pair for browsers, and is closed with 1008 otherwise. The server fails
closed: startup refuses to run without a token and protected routes
answer 503 if none is configured.

The settings field is bound to CV_SERVER_API_TOKEN only (an unrelated
API_TOKEN variable is ignored) and stored as a SecretStr. Smoke tests
and the locust load test send the header.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Pin com.coplaydev.unity-mcp to v10.3.0
  (aa5fc638d623f56178d50329d9ad8c541a57fe66) instead of the moving #main
  branch (previously resolved to 9.5.2, f130dcb).
- Pin com.github-glitchenzo.nugetforunity to the commit already recorded in
  packages-lock.json (a22299e7, 4.4.0), so a fresh clone resolves the same
  code.
- MCPForUnity.Runtime has no platform restriction in its asmdef, so Unity
  copied it into every player. EditorOnlyPackageAssemblyFilter
  (IFilterBuildAssemblies) drops MCPForUnity*.dll from player builds; the
  Editor bridge keeps working. EditMode tests cover the filter.
- Remove Assets/Resources/PerformanceTestRun{Info,Settings}.json: generated
  Performance Testing artefacts that shipped in every player build through
  Resources and embedded the dev dependency list (including unity-mcp).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
PlayerSettings.submitAnalytics was 1, so player builds sent Unity hardware
statistics. All Unity Connect services (analytics, crash and performance
reporting) were already disabled in UnityConnectSettings.asset.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Floating major tags (@v4) let the code that runs in CI change without a
commit here. Pin each action to the commit of a specific release and keep
the version in a trailing comment so Dependabot can still bump it.

- actions/checkout v7.0.1, actions/upload-artifact v7.0.2 and
  actions/setup-node v7.1.0: current node24 releases (runners dropped
  Node 20 on 2026-09-23); no input changes affect these workflows.
- game-ci/unity-test-runner v4.3.2: the self-contained v4 line. v4.4.0
  downloads the game-ci CLI at run time (cliVersion defaults to latest),
  which a SHA pin would not cover.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
TORCH_CUDA_ARCH_LIST was 8.9, so the GroundingDINO and SAM 2 extensions
only had kernels for RTX 40-series / Ada GPUs and failed on A100, A10,
RTX 30-series and H100 hosts.

Build for 8.0;8.6;8.9;9.0 plus PTX for newer GPUs, as a build arg so a
local build can narrow it. CUDA 12.1 in the base image supports all of
these; flash-attn picks its own architectures and is unaffected.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Both test jobs hard-coded 6000.3.9f1 while the project is pinned to
6000.3.10f1 in ProjectSettings/ProjectVersion.txt, so CI tested with a
different editor than the one the project is saved with. The unit job
now reads m_EditorVersion from that file and hands it to the integration
job through a job output, so the version lives in one place.

The step also emits a warning annotation when README.md no longer
mentions that version, so the documented version cannot drift silently.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The ci-local gate left this workflow on workflow_dispatch only, so no
pull request was ever tested. The gate exists to stop billed
GitHub-hosted minutes; this workflow runs on the self-hosted GPU runner,
so pull requests to main that touch the Unity project (Assets, Packages,
ProjectSettings, test fixtures or this file) run the unit job again. The
ci-local marker block is left as is, so `ci-local restore` still works.

Because the repository is public and the runner is self-hosted:
- the unit job skips pull requests from forks, so outside code never
  runs on the runner (forks would not get the licence secrets anyway);
- the token is read-only and checkout does not persist credentials.

The integration job needs a live cv-server on the runner host, so it
stays off pull requests (manual runs, or push/schedule if restored), as
planned in docs/qa-ci.md. Test artifacts now upload on failure too, and
UNITY_SERIAL is accepted for Plus/Pro licences like the build workflow.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was no way to produce a Quest build in CI. quest-build.yml builds
the Android (ARM64, IL2CPP) APK with game-ci/unity-builder v5.0.1, pinned
by commit SHA, on a GitHub-hosted Ubuntu runner (free for this public
repository). It runs on manual dispatch and on v* tags, so nothing builds
on ordinary pushes, in line with the gated-trigger policy.

- The editor version is read from ProjectSettings/ProjectVersion.txt and
  passed to GameCI; it also keys the Library cache, which is restored
  only from builds with the same editor version.
- A preflight step names any missing Unity licence secret before the
  long build starts. ANDROID_KEYSTORE_* secrets are optional: without
  them the APK is debug-signed, which the job summary points out.
- GameCI semantic versioning (fetch-depth 0) sets the APK version from
  v* tags and commit count. The APK and its SHA-256 are uploaded as an
  artifact (7-day retention, same cap as the other workflows).
- On a v* tag a separate job with contents: write creates (or updates)
  a draft GitHub Release with the APK attached; the build job itself
  only has read access.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
configs/ and checkpoints/ are gitignored, so the GroundingDINO config and
weights and the SAM 2.1 tiny checkpoint had to be fetched by hand, and the
Dockerfile COPYed them, which made any clean build (CI included) fail.

Add scripts/fetch_weights.py (stdlib only). Each file has pinned URLs
(Hugging Face pinned to a repo commit, with the upstream GitHub release or
download as fallback) plus a pinned size and SHA-256 taken from upstream
metadata. Downloads stream to a temp file next to the target, are checked
for size and checksum, then renamed into place. A verified file is kept;
a mismatching one is reported and only replaced with --force. --check
verifies without downloading. Destinations follow GDINO_CONFIG_PATH,
GDINO_WEIGHTS_PATH and SAM2_WEIGHTS_PATH, so the same files the server
loads are the ones verified. The model choice is unchanged.

The entrypoint runs it on start (CV_SERVER_FETCH_WEIGHTS=0 skips) after
failing fast when CV_SERVER_API_TOKEN is unset; the image can bake the
files in with --build-arg FETCH_WEIGHTS_AT_BUILD=1. The Dockerfile no
longer COPYs configs/ and checkpoints/, compose mounts them writable, and
a .dockerignore keeps .venv, certs, .env and model files out of the
build context. Also restores the line breaks in the README curl example.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
docker-compose.yml hard-coded certificate and key paths named after a
personal tailnet host. Replace them with CV_SERVER_SSL_CERTFILE /
CV_SERVER_SSL_KEYFILE (from the shell or cv-server/.env), defaulting to
/app/certs/server.crt and server.key; without both files the entrypoint
still falls back to HTTP only. Pass CV_SERVER_API_TOKEN through the same
way, and add a .env.example with placeholders only.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Meta XR SDK 85 ships OVRPlugin.aar, InteractionSdk.aar and SDKTelemetry.aar,
which all declare the namespace com.oculus.Integration. AGP 9 (Unity 6000.3)
rejects duplicate namespaces by default, so CommandLineBuild.BuildAndroidQuest
failed in :launcher:processReleaseMainManifest. A custom Gradle properties
template sets android.uniquePackageNames=false, keeping the AGP 8 behaviour,
until Meta ships unique namespaces.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Turn on the SDK's "Enable Only In Debug Build" setting. The debugger still
works in the Editor and in Development builds, where Unity defines DEBUG.
The SDK still starts its log cache in release builds, because it checks only
the main enable flag.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was no way to publish the cv-server image. Add a manual
(workflow_dispatch) workflow that, from the default branch only, builds
cv-server/ and pushes ghcr.io/<owner>/ci-xr-scan-cv-server:<number>, where
the number is the run number or a digits-only input. It refuses to
overwrite an existing tag, reads the digest back from the registry and
prints it (log, notice and job summary) as <image>:<number>@<digest> for
pinning in CI-Marketplace. Only GITHUB_TOKEN is used (contents: read,
packages: write), and checkout is pinned to a commit SHA. The runner is
pinned to ubuntu-24.04 because the disk clean-up depends on its layout.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With core.autocrlf the script is checked out with CRLF on Windows, and an
image built from that checkout fails to start because the #! line names
"/bin/bash\r". Add cv-server/.gitattributes (*.sh eol=lf) and strip CRs
when the Dockerfile copies the script, so existing checkouts build a
working image too.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Say how to run cv-server-publish.yml, which tag it uses, what it prints for
CI-Marketplace, and what a container of the published image needs (the API
token and volumes for the model files).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There were no instructions for getting a build onto a headset. The new
guide covers where an APK comes from (Quest APK Build artifact, draft
release, local CompanionScan menu build) and how to check its SHA-256,
the one-time headset setup (developer team, Developer Mode, Windows ADB
driver, USB debugging), installing with Meta Quest Developer Hub or adb
(including wireless adb), first launch (Unknown Sources, Space Setup,
permissions), and replacing a build signed with a different key without
losing the glTF exports kept in the app's storage.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The check only warned when README.md did not mention the editor version
at all, so a README or docs page that named both the old and the new
version passed. A separate step now scans README.md and docs/**/*.md for
Unity version strings and emits a warning annotation, with file and
line, for each one that differs from ProjectSettings/ProjectVersion.txt.
It keeps the "README does not mention it" warning and is marked
continue-on-error, so documentation drift never blocks the tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
quest-build.yml points to a README section on its secrets that did not
exist. Add "Continuous integration and releases": what each workflow
runs on and when it starts, the Unity and Android signing repository
secrets (where the Personal licence file lives, how to set them with gh
without leaking values to shell history), how to dispatch a build,
download it, and cut a draft release from a v* tag, how GameCI derives
the APK version and version code from tags, and how the Library cache
is shared with tag builds.

Also:
- state the editor version (6000.3.10f1, as in ProjectVersion.txt) and
  the Android modules a local build needs in Quick Start;
- fix the build menu path (CompanionScan, not Companion Scan) and name
  the APK it writes, linking CI builds and docs/SIDELOAD.md;
- note the runner version the Node 24 actions need and that pull
  requests run the unit tests;
- list SIDELOAD.md, CI.md and qa-ci.md under Documentation.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The plan said unit tests run on every PR and the integration job starts
cv-server with docker compose on main and nightly. In fact the unit job
runs on pull requests that touch the Unity project, the integration job
is manual while its push/nightly triggers are gated and expects a
cv-server already running on the runner host, and the web tests are
manual. Say so, name the workflow file behind each job, and add the
Quest APK build as job D with a link to SIDELOAD.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ServerConfig defaulted to a personal tailnet host (in both the class and the
Resources asset), so every build talked to one developer's machine. The
default is now empty and the URL is entered on the headset:

- ServerConfig: empty default, PlayerPrefs overrides for the URL and the
  detection thresholds, URL normalization (https:// is assumed when no scheme
  is typed), and the CompanionScan_SERVER_URL environment variable is read in
  the Editor only (it cannot be set for an installed APK).
- SettingsPanel: builds a world-space panel at runtime, opens on first run
  when no URL is configured, uses the Horizon OS system keyboard and stores
  the URL as a PlayerPrefs override (the asset is never written at runtime).
- XRControllerInput: the left Menu button toggles the panel; while it is open
  A edits the URL and B saves it, and capture controls are suspended.
- CompanionCapture scene: SettingsPanel added to ControllerUI and wired to
  XRControllerInput.
- AndroidManifest: declare oculus.software.overlay_keyboard (not required) so
  the system keyboard is available.
- The CV pipeline skips server detection with one warning when no URL is set,
  and the HUD status line shows "Server: not set (Menu)".
- EditMode tests for URL resolution and normalization, the shipped asset and
  the scene wiring.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The model QA tests used 14 photographs of closets, pantries, laundry rooms
and living rooms (test/) and 11 copies of them in
Assets/CompanionScan/Tests/Fixtures. They were downloaded from the web with
no recorded source, author or licence, so we cannot redistribute them.

- Remove the 14 photos from test/ and the 11 copies (and their metas) from
  the Unity fixtures folder.
- Add tools/generate_synthetic_fixtures.py, which draws six room scenes
  (pantry, food storage, closet, laundry room, bedroom, living room) with
  Pillow only: no third-party images, textures or fonts. Output is
  deterministic; regenerating reproduces the committed JPEGs byte for byte.
- Add the six renders to test/ and four of them to the Unity fixtures
  folder, and point PerImageModelTests at them.
- test/README.md records where the images come from and asks contributors
  not to commit photos without a recorded licence.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- EmojiOne sprite sheet (TextMesh Pro sample): EmojiOne.png, EmojiOne.json,
  "EmojiOne Attribution.txt" and the EmojiOne sprite asset. The attribution
  file names no licence; it only says to review EmojiOne's licensing terms
  on their website. Nothing in the project uses <sprite> tags, so TMP
  Settings now has no default sprite asset instead.
- Assets/number_atlas.png: a digit atlas from the initial commit with no
  recorded source or licence, referenced by no asset.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Assets/Plugins/Demigiant{,/DOTween,/DOTween/Editor}.meta described DOTween,
an Asset Store package whose files were never committed, and
Assets/CompanionScanLegacy.meta described a legacy sample folder that is not
in the repository either. Unity deletes such orphan metas on import; removing
them also stops the tree from implying a DOTween dependency that we would
otherwise have to license and attribute.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…v builds

The Meta XR SDK installs a network security config that forbids all
cleartext traffic, so an APK could never reach a LAN CV server over http.
Opening it up globally would be wrong for release builds, so:

- AndroidNetworkSecurityConfig (editor build hook) generates
  res/xml/companion_network_security_config.xml for every Android build and
  points the manifest at it. The base config forbids cleartext; development
  builds add a domain-config for the hosts in
  ServerConfig.developmentCleartextHosts; release builds list none.
- CleartextHostPolicy accepts only explicit LAN hosts (private, link-local or
  loopback IPv4, single-label names, .local/.lan/.home.arpa/.internal names)
  and rejects public or CGNAT addresses, IPv6 literals, wildcards, ports and
  schemes.
- ServerConfig.IsUrlAllowed applies the same policy at runtime (https always;
  http only in development builds and, on Android, only to listed hosts), so
  SettingsPanel refuses a URL the build would block and CVServerClient,
  GltfSyncClient and the capture pipeline report a clear error instead of a
  transport failure.
- The shipped ServerConfig lists no cleartext hosts.
- EditMode tests for the host policy, the URL policy, the generated XML and
  the manifest reference.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…eeded

USE_SCENE was declared in the manifest but never requested: OVRManager's
requestScenePermissionOnStartup is off and the code only checked
HasUserAuthorizedPermission, so scene capture and environment raycasts
silently stayed off unless the user granted the permission in system
settings.

SpatialDataPermission requests com.oculus.permission.USE_SCENE the first time
a feature needs it (Meta scene capture, CV capture before pin placement, and
environment raycasts, which ask without blocking and use fallback hits
meanwhile). Concurrent callers share one request; a denial is remembered for
the session so captures do not prompt again, a later grant from the system
settings is picked up, and a dismissed dialog asks again on the next need.
On denial MetaSceneCollector reports how to enable "Spatial data" instead of
a raw permission ID. Outside Android players the permission does not apply.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Enabled Unity OpenXR / Meta OpenXR features add permissions to the generated
xrmanifest library at build time, not because the app uses them:

- Foveated Rendering (lists XR_META_foveation_eye_tracked) with a Quest Pro
  target adds com.oculus.permission.EYE_TRACKING and
  oculus.software.eye_tracking with required="true", which also hides the
  app from headsets without eye tracking in the store.
- AR Anchors adds com.oculus.permission.IMPORT_EXPORT_IOT_MAP_DATA (anchor
  sharing).
- Colocation Discovery adds USE_COLOCATION_DISCOVERY_API.
- Boundary Visibility adds com.oculus.permission.BOUNDARY_VISIBILITY.

A code search finds no eye gaze or eye-tracked foveation use (no
foveatedRenderingFlags, EyeGazeInteraction and the Meta eye-tracked
foveation feature are off, OVRManager does not request eye tracking), no
anchor sharing (no ShareAsync, OVRSpatialAnchor or ARAnchor use), no
colocation API and no boundary visibility request (boundary suppression is
off; BoundaryProvider only reads boundary points). The custom manifest now
removes these entries during the Gradle manifest merge with
tools:node="remove". USE_SCENE, USE_ANCHOR_API, passthrough camera and hand
tracking stay. EditMode tests pin the removal entries.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With "Override Default Package Name" off, Unity derives the package name as
com.<companyName>.<productName>. The profile's company name was
"companionintelligence" while the global Player Settings use
"CompanionIntelligence", so editing the profile's Player Settings would
regenerate the lowercase identifier this branch already replaced. Use the
global company name so the profile keeps com.CompanionIntelligence.CompanionCapture.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
mrhegemon and others added 28 commits November 12, 2026 15:01
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The project as the 6000.6.9f1 editor upgraded it when opened in batch mode
(-batchmode -nographics -quit -accept-apiupdate), with nothing else changed:

- ProjectVersion.txt: 6000.6.9f1 (8c45277fb9c5).
- Editor-recommended package updates: URP 17.6.0, XR Management 4.7.0,
  OpenXR 1.18.0, Meta OpenXR 2.6.1, Input System 1.20.1, Test Framework
  1.8.0, Timeline 6.6.0, uGUI 2.6.0, AI Navigation 2.0.16, Rider 3.1.0,
  Multiplayer Center 2.1.0, Visual Scripting 1.9.13; new built-in modules
  physicscore2d, tetgen and timelinefoundation; com.unity.modules.vr removed.
- URP 17.6 migration of the global settings asset, OpenXR 1.18 / Meta OpenXR
  2.6.1 re-serialization of the OpenXR package settings (new features added
  disabled; ARCameraFeature now has m_CameraImageSupport, serialized as 0),
  EditorBuildSettings, and the new PhysicsCoreProjectSettings2D and
  ProjectAuditorSettings assets.

The Meta XR SDK 85 packages, UnityGLTF 2.18.8 and the vendored
NaughtyAttributes editor code do not compile on 6000.6 (Object.GetInstanceID,
UnityEditor.GUID, Physics.BakeMesh(int, bool), SceneHandle to int and the URP
compatibility-mode render pass API), so the first two batch opens stopped at
"Scripts have compiler errors" before the editor finished the upgrade. The
third open added -ignorecompilererrors so the editor could finish and save it.
The following commits make the project compile again. unity-mcp v10.3.0
(aa5fc638) already compiles on 6000.6.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Ported from upgrade/unity-6000.6.9f1 a193aeb and reconciled with
fix/licensing-notices, which replaced com.meta.xr.sdk.all with the Meta
packages it installed minus the Voice SDK and the Interaction SDK.

Unity 6000.6 turns Object.GetInstanceID(), EditorUtility.InstanceIDToObject(int),
Physics.BakeMesh(int, bool) and the SceneHandle-to-int conversion into compile
errors, moves UnityEditor.GUID and drops the URP compatibility-mode
ScriptableRenderPass overrides, so the locked versions did not compile:

- com.meta.xr.sdk.core, audio, haptics, platform and com.meta.xr.mrutilitykit
  85.0.0 -> 209.0.0, still listed one by one: no com.meta.xr.sdk.all, so the
  Voice SDK and the Interaction SDK stay out (licensing branch, 36fe595 and
  e4faa1c). Core 209 adds com.unity.xr.hands 1.9.0. 209.0.0 is the first
  release whose audio package compiles (UnityEditor.GUID).
- org.khronos.unitygltf release/2.18.8 -> release/2.20.0 (74d7064f), the first
  release that guards GetInstanceID and the render-graph-only URP API.
- com.coplaydev.unity-mcp stays pinned to the immutable v10.3.0 commit
  aa5fc638d623f56178d50329d9ad8c541a57fe66: it already uses GetEntityId on
  6000.5+ and compiles on 6000.6.9f1 without errors, so 6000.6 does not need
  the newer #main that a193aeb locked.

OpenXR Package Settings: the new Meta and XR Hands features are added
disabled; no existing feature changed state. Unlike a193aeb there is no
Microgestures feature and no Interaction SDK QDS tags in TagManager, because
the Interaction SDK is gone.

With the NaughtyAttributes fix in the next commit, 6000.6.9f1 compiles the
project in batch mode with 0 errors.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Ported unchanged from upgrade/unity-6000.6.9f1 8a07557.

Object.GetInstanceID() is a compile error (CS0619) on Unity 6000.6. Both call
sites only build string keys (foldout EditorPrefs key and reorderable-list
cache key), so EntityId.ToString() is a drop-in replacement.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Ported from upgrade/unity-6000.6.9f1 5353042.

Meta OpenXR 2.5.0-pre.1 made camera image access opt-in through the new
ARCameraFeature m_CameraImageSupport field, and the upgrade to 2.6.1
serialized it as 0 on the enabled 'ARCameraFeature Android'. With it off,
MetaOpenXRCameraSubsystem stays in SupportNotRequested, so
ARCameraManager.TryAcquireLatestCpuImage always returns false and
SpatialCapturePipeline (preferArCameraOnQuest) gets no frames on Quest, and
the package no longer adds com.oculus.permission.USE_PASSTHROUGH_CAMERA,
horizonos.permission.HEADSET_CAMERA and the optional android.hardware.camera
feature to the manifest. Setting it to 1 restores the Meta OpenXR 2.4.0
behaviour. The Standalone camera feature stays disabled.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Ported from upgrade/unity-6000.6.9f1 e29e9dd; only the doc comment changed,
because the Meta Voice SDK it named is no longer in the project.

Meta XR Core SDK 209 creates Assets/Resources/DevAgentSettings.asset on
every editor load with the machine's LAN IP and AgentBridge access token,
and its DevAgentBuildProcessor injects both again at build time. Resources
ship in the player, so every APK carried the build machine's address and
token.

DevAgentSettingsBuildFilter deletes the asset in a pre-build callback that
runs after the SDK's processor. CommandLineBuild.BuildAndroidQuest and
QuestBuilder also call it before BuildPipeline.BuildPlayer, because Unity
skips the remaining build callbacks when one throws while Unity creates it
(on the upgrade branch the Meta Voice SDK's ConduitManifestGenerationManager
did, once the Immersive Debugger had reloaded Assembly-CSharp from bytes).
The SDK does not recreate the asset while a player is building, and
recreates it on the next editor load. The Immersive Debugger AI Assistant,
its only runtime reader, is unused here and skips itself when the asset is
missing. The asset is also gitignored so the token is never committed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Why the upgrade branch's APK had no Burst code: Unity creates one instance
of every build-callback class before a build
(BuildPipelineInterfaces.InitializeBuildCallbacks). In its last build the
Meta Voice SDK's ConduitManifestGenerationManager constructor threw there
("An item with the same key has already been added. Key: Assembly-CSharp",
because the Meta Immersive Debugger had reloaded Assembly-CSharp from
bytes). Unity logged it, registered none of the callbacks it had not
reached yet, and still built the APK. One of those was the editor's
BurstAOTCompilerPostprocessor (IGenerateNativePluginsForAssemblies; Burst
is part of the 6000.6 editor, com.unity.burst 2.0.0 is only a runtime
stub), so no lib_burst_generated.so was produced and every Burst job, URP's
included, ran as plain IL2CPP code. The branch's first build, where nothing
threw, compiled Burst normally. The OpenXR hooks that strip disabled
features' native libraries were cut off too, which is why that APK also
carried the mock runtime and conformance libraries.

The trigger is gone: fix/licensing-notices removed the Voice SDK and the
6000.6 package update keeps it out. To make any repeat fail loudly:

- BuildIntegrityChecks.VerifyBuildCallbacksConstruct creates every build
  callback the way Unity does and fails the build naming each one that
  throws. CommandLineBuild.BuildAndroidQuest and QuestBuilder run it before
  BuildPipeline.BuildPlayer.
- BuildIntegrityChecks.VerifyBurstCode fails the build when the APK (or
  AAB) has no lib_burst_generated.so for an ABI in Player Settings while
  ProjectSettings/BurstAotSettings_Android.json has Burst AOT on.
- EditMode tests cover both checks, including that no build callback in
  this project throws when created.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Companion Scan captures frames through the Passthrough Camera API, which
only Quest 3 and Quest 3S have, so the app must not be offered on Quest 2
or Quest Pro. The APKs declared quest2|questpro|quest3|quest3s. Three places
feed com.oculus.supportedDevices, and all three now say the same:

- Assets/Plugins/Android/AndroidManifest.xml: quest3|quest3s (Meta's
  documented values).
- OpenXR Meta Quest Support feature (Android): only Quest 3 (codename
  eureka) and Quest 3S stay enabled; Quest, Quest 2 and Quest Pro are off.
- OculusProjectConfig targetDeviceTypes: Quest3 (4) and Quest3S (5) only,
  which the Meta XR SDK's manifest tooling and project setup checks use.

EditMode tests pin all three.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…gh capture

QuestCameraProvider only asked for Unity's WebCam authorization, which is
android.permission.CAMERA. Horizon OS gates the Quest 3 / 3S passthrough
cameras behind horizonos.permission.HEADSET_CAMERA (Passthrough Camera API,
Horizon OS v74+), which the manifest declared but nothing requested at run
time. The provider also checked WebCamTexture.devices before asking, and
without the permission the passthrough cameras may not be listed at all,
so it could return without ever prompting.

- QuestCameraProvider requests HEADSET_CAMERA first, together with
  android.permission.CAMERA in the same dialog, before it looks for or
  opens a camera. Permission callbacks only record the answer; Update()
  starts the WebCamTexture on the main thread once both are granted. A
  denial is remembered for the session and logged with how to allow it; a
  dismissed dialog asks again the next time capture starts.
- android.permission.CAMERA stays requested and declared: Unity's
  WebCamTexture checks it, and Meta OpenXR's camera feature declares it
  too while camera image support is on. Remove it from
  QuestCameraProvider.RequiredPermissions and the manifest only once
  capture has been verified on a headset without it. That needs a device,
  so it is not done here.
- EditMode tests: HEADSET_CAMERA is requested first, and every permission
  the provider requests is declared (not removed) in the manifest.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Meta requires Quest apps created after 1 March 2026 to target API level 34,
and levels above 34 are outside what Horizon OS accepts for immersive apps.
Player Settings and the Meta Quest build profile say 34, but nothing kept it
there: "Automatic (highest installed)" would pick 36 on this machine, and the
sibling Companion APK shipped with 36 that way.

- QuestTargetSdkRequirement (IPreprocessBuildWithReport, runs first) fails
  every Android build whose target API level is not exactly 34, so
  CommandLineBuild, QuestBuilder, the Build Profiles window and GameCI's own
  build method are all covered.
- The Quest APK workflow passes androidTargetSdkVersion: AndroidApiLevel34
  to GameCI explicitly.
- EditMode tests: Player Settings and the build profile say 34; Automatic,
  32, 35 and 36 fail the build.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Both Quest APKs were signed with Unity's debug key, which Meta rejects, and
CommandLineBuild had no way to sign with a release key. It now reads
everything from the environment and never creates a keystore:

- Signs with the release key only when KEYSTORE_PATH, KEYSTORE_PASS,
  KEY_ALIAS and KEY_PASS are all set (and KEYSTORE_PATH exists); otherwise
  Unity's debug key signs the APK and a warning names any missing
  variables. Logs and errors name variables, never their values.
- -release makes the build fail unless all four are set.
- versionCode is VERSION_CODE when set, otherwise MAJOR*1000000 +
  MINOR*1000 + PATCH of the version name (VERSION_NAME when set, otherwise
  bundleVersion), the same rule GameCI's semantic versioning uses in CI:
  0.1.0 builds as versionCode 1000. Invalid values fail the build.
- The settings apply to that one build (AndroidReleaseSettings.Apply) and
  the previous Player Settings come back afterwards, so ProjectSettings.asset
  never records a keystore path or alias, and passwords stay in memory.
- README: "Release builds from the command line". .gitignore: *.jks,
  *.keystore, *.p12 and keystore.properties.
- EditMode tests for the variable handling, the -release rule, the
  versionCode rule and the Player Settings restore.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CommandLineBuild.BuildAndroidQuest -aab sets
EditorUserBuildSettings.buildAppBundle for that build only (the previous
value comes back afterwards) and writes Builds/Android/<product>.aab
instead of the APK. Signing, versionCode, the target API level check, the
build-callback check and the Burst check (base/lib/<abi>/ in a bundle) work
the same way. README documents it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Integration fix between fix/cv-server-release and
fix/server-config-and-store. The server now requires "Authorization:
Bearer <CV_SERVER_API_TOKEN>" (c4ba4d5), but neither CVServerClient nor
GltfSyncClient sent any header, so after the merge every capture and glTF
upload from the headset would get 401.

- ServerConfig.ResolveApiToken: a PlayerPrefs override entered in-headset,
  or in the Editor only the CompanionScan_API_TOKEN environment variable
  (Play Mode tests against a local server). The asset has no token field,
  so no build ships one. ApplyAuthorization adds the bearer header when a
  token is set.
- CVServerClient and GltfSyncClient send it. 401, 403, 413 and 503 are not
  retried, and their errors say what to fix (401: enter the token in the
  settings panel; 503: the server has no token configured).
- SettingsPanel: X opens the system keyboard in secure mode for the token
  (empty removes it); the panel only says whether a token is set and never
  shows it. XRControllerInput routes X while the panel is open.
- The Unity Tests integration job passes CompanionScan_API_TOKEN from a new
  CV_SERVER_API_TOKEN secret; README documents the Menu panel, the test
  variables and the secret.
- EditMode tests for token resolution, the header, removal, the Editor
  variable, the shipped asset and the error messages.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
cv-server could not be built: requirements.txt pins pillow==13.0.0 (from
Dependabot), which declares Requires-Python >=3.11, while the image installed
Ubuntu 22.04's default Python 3.10, so "pip install -r requirements.txt"
had no matching Pillow.

Fix chosen as the least risky of the options:
- Pinning Pillow back to 12.x would build, but brings back the decoder
  vulnerabilities fixed in 13.0.0 on a server that decodes images from the
  network (the dependency audit counted 41 advisories for 12.3.0), and keeps
  filelock at 4.1.0, the last release for 3.10.
- A newer base image (Ubuntu 24.04, Python 3.12) would also change the CUDA
  stack under torch, flash-attn and the GroundingDINO/SAM 2 extensions.
- Python 3.11 from Ubuntu 22.04's own archive (python3.11, -dev and -venv in
  jammy-updates) keeps the same CUDA 12.1 base image, apt source and pins,
  and adds no third-party PPA.

The Dockerfile installs python3.11, python3.11-dev and python3.11-venv instead
of python3.10 and python3-pip, creates /opt/venv with it and puts it first on
PATH, so pip, python3 (entrypoint, GroundingDINO build, fetch_weights.py) and
uvicorn all run 3.11. flash-attn builds without isolation, so wheel is
installed next to packaging (the system pip used to pull it in).

Checked with uv for x86_64-manylinux_2_35: requirements.txt is unsatisfiable
for Python 3.10 (pillow==13.0.0 needs >=3.11) and resolves for 3.11, also
together with torch 2.5.1+cu121, torchvision 0.20.1+cu121 and torchaudio
2.5.1+cu121 from the cu121 index (filelock 4.2.10, transformers 5.10.1,
accelerate 1.15.0). Docker was not running here, so the image itself was not
built.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…uded

fix/cv-server-release (c4ba4d5) put a bearer token on every route except
GET /v1/health. That route is not a bare liveness probe: it reports the GPU
model, VRAM use, which models are loaded and the uptime, to anyone who can
reach the port. Every route now requires the token; PUBLIC_PATHS is empty.
With no token configured every route answers 503, as protected routes
already did.

Callers updated so nothing that probes health breaks:
- Unity Tests integration job: the health wait sends the new
  CV_SERVER_API_TOKEN secret (and stops early if it is missing).
- web/: the Vite dev proxy adds the header from CV_SERVER_API_TOKEN on the
  Node side, so the web client's /v1 calls (health included) keep working
  in development without the token reaching the browser.
- Tests, entrypoint message, .env.example, compose, locust and the docs
  (cv-server/README.md, README.md, docs/qa-ci.md, web/README.md) no longer
  describe /v1/health as public.

pytest (Python 3.14 venv, CPU torch): 37 passed, 5 skipped (the model smoke
tests need weights).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With a certificate and key in place the entrypoint started HTTPS on :443
and, next to it, plain HTTP on :8000 ("Always start HTTP on port 8000"), so
a client pointed at :8000 sent the bearer token and room images in clear
text even on a TLS-configured server.

entrypoint.sh now decides once:
- TLS on (SSL_CERTFILE and SSL_KEYFILE both exist): uvicorn serves HTTPS on
  :443 only; no plain-HTTP listener is started.
- TLS off (neither file exists): plain HTTP on :8000, as before.
- Only one of the two files: refuse to start (a broken TLS setup no longer
  falls back to clear text silently).
- CV_SERVER_REQUIRE_TLS=1: refuse to start without TLS (compose passes it
  through, default 0).
uvicorn is exec'd, so it is PID 1 and gets the container's stop signal.
README, compose and .env.example describe the new behaviour.

Checked with bash and a stub uvicorn: both files -> only "--port 443
--ssl-certfile ... --ssl-keyfile ..."; no files -> only "--port 8000"; one
file -> exit 1; no files with CV_SERVER_REQUIRE_TLS=1 -> exit 1; no token
-> exit 1.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Nothing limited request bodies: /v1/detect, /v1/segment and /v1/florence
take base64 images in JSON, and POST /v1/gltf read whole multipart files
into memory and wrote them to disk, so one request could exhaust memory or
fill the upload volume.

- app/limits.py RequestSizeLimitMiddleware caps every HTTP request body at
  CV_SERVER_MAX_REQUEST_BYTES (default 32 MiB). A larger Content-Length is
  refused with 413 before any of the body is read; a body without one
  (chunked) is counted as it arrives and refused with 413 once it passes the
  cap, so an oversize glTF upload writes nothing. An invalid Content-Length
  gets 400. It runs inside the token check, so unauthenticated requests are
  refused before their body is read at all.
- entrypoint.sh passes --ws-max-size (CV_SERVER_MAX_WS_MESSAGE_BYTES, default
  16 MiB, uvicorn's own default made explicit) to cap /v1/stream messages.
- README and .env.example document both settings.
- tests/test_limits.py: under-limit requests pass, declared and chunked
  oversize bodies get 413, an oversize glTF upload leaves the upload
  directory empty, a bad Content-Length gets 400, and auth comes first.

pytest (Python 3.14 venv, CPU torch): 45 passed, 5 skipped.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…iles

The rest of the 6000.6.9f1 upgrade, as the editor wrote it on the first
batch run (EditMode tests) after the project compiled with 0 errors. The
upgrade commit could not include it: with Meta XR SDK 85, UnityGLTF 2.18.8
and NaughtyAttributes failing to compile, the editor never got this far.
Nothing was edited by hand except one line, noted below.

- ProjectSettings.asset: PlayerSettings serializedVersion 28 -> 30 (new
  fields with defaults, removed Holographic/VR fields, typed arrays).
  AndroidKeystoreName is kept empty: the run wrote '{inproject}: ' there
  because an EditMode test set and restored the keystore. The signing
  scaffolding no longer touches the keystore for unsigned builds, and the
  test no longer sets one.
- Mobile_RPAsset: URP 17.6 fields.
- XRGeneralSettingsPerBuildTarget: XR Management 4.7 format
  (m_SettingsPerBuildTarget, m_Manager).
- OculusProjectConfig: Meta XR Core SDK 209 fields (useOpenXRPromptDeclined,
  useForwardHeadPose; virtualKeyboardSupport removed) and the typed
  targetDeviceTypes array (still Quest 3 and Quest 3S).
- UnityGLTFSettings: UnityGLTF 2.20.0 registers its new ExrImport and
  WebpImport plugins; it adds them again on every editor load otherwise.

The same changes are in upgrade/unity-6000.6.9f1 240530e and a193aeb,
except the Interaction SDK TagManager entries, which do not apply here.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- README: the pinned editor is 6000.6.9f1 (Quick Start and the editor
  table), which also clears the documented-version drift warning that
  ci/build-and-docs added to the Unity Tests workflow.
- THIRD_PARTY.md section 1.1 (from fix/licensing-notices) now matches
  Packages/packages-lock.json after the upgrade: Meta XR SDK 85.0.0 ->
  209.0.0 (core, platform, audio, haptics, MR Utility Kit; still without
  Voice and Interaction), UnityGLTF 2.18.8 -> 2.20.0 (74d7064), URP/core/
  Shader Graph 17.6.0, OpenXR 1.18.0, Meta OpenXR 2.6.1, XR Management
  4.7.0, AR Foundation 6.6.2 and the other Unity packages. New rows for
  com.unity.xr.hands 1.9.0 (Unity Package Distribution License, pulled in
  by Meta XR Core 209, ships libUnityOpenXRHands.so), com.unity.profiling.core
  and com.unity.graph-authoring. Burst 2.0.0 is now a runtime stub and the
  compiler ships with the editor, with its own licence and notices.
- Licence texts checked against the 209 packages: core, MRUK, platform and
  audio LICENSE/NOTICE files are byte-identical to 85.0.0; haptics'
  THIRD_PARTY_NOTICES.txt changed (its Rust crates now list zlib instead of
  BSL-1.0), so that row says so. UnityGLTF's LICENSE is unchanged.
- NOTICE.md: Meta XR SDK 209.0.0 and UnityGLTF 2.20.0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The last two upgrade re-serializations, which the editor only writes on the
first Android player build: URP 17.6 adds the Bloom "filter" override to
DefaultVolumeProfile, and 6000.6 adds the graphics state collection, light
baker and shader build settings fields to GraphicsSettings. Same content as
in upgrade/unity-6000.6.9f1 240530e. Without them every build would dirty
both files again.

The other files that build touched are build-time side effects and were
restored instead: the URP runtime settings list, the XR preloaded assets in
ProjectSettings, UnityGLTFSettings' packageVersion, the Immersive Debugger's
inspected-data list, and line endings of OVRBuildConfig and Mobile_RPAsset.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ions

df2cf11 added the HEADSET_CAMERA request to QuestCameraProvider, but Quest
builds never use that provider. The scene sets preferArCameraOnQuest, so on
Android SpatialCapturePipeline.Awake replaces it with an auto-created
MobileCameraProvider on AR Foundation's ARCameraManager (Meta OpenXR's camera
subsystem), and that provider requested no permission. This also corrects
df2cf11's rationale. HEADSET_CAMERA was requested at run time, by OVRManager at
startup (requestPassthroughCameraAccessPermissionOnStartup, in the scene since
6feafbb). The reason given for keeping android.permission.CAMERA (WebCamTexture
checks it) does not apply to the AR path.

The real problem was on the AR path. Meta OpenXR 2.6.1 checks HEADSET_CAMERA
once, in MetaOpenXRCameraSubsystem's Start(). That ran when the pipeline added
the ARCameraManager in Awake, while OVRManager's request was still pending.
Only Stop() and Start() change that state, and nothing restarted the subsystem
after the grant, so first-launch capture could get no frames until the app was
restarted.

- PassthroughCameraPermission (Core) asks for HEADSET_CAMERA and CAMERA in one
  request when capture starts, following SpatialDataPermission. Concurrent
  callers share the request and a denial is remembered for the session. A
  dismissed dialog is shown again the next time a frame is needed, and a grant
  made later in the settings is picked up.
- CameraPermissionGate keeps the camera off until both permissions are
  granted and stops a camera that already runs without them. After the grant
  it switches the camera on, which starts the subsystem again, so Start() sees
  the permission.
- MobileCameraProvider uses the gate in Android players.
  SpatialCapturePipeline assembles the PCA camera inactive, with the
  ARCameraManager disabled, so the subsystem never starts before the gate
  allows it. Passthrough rendering is unaffected: the scene draws it with
  OVRPassthroughLayer.
- QuestCameraProvider (the WebCamTexture fallback, used only when
  preferArCameraOnQuest is off) now uses the same helper and gate instead of
  its own request code.
- OVRManager's startup request is turned off in the scene. With both requests,
  Unity 6 queues them, and a user who denies is asked for HEADSET_CAMERA twice
  in a row.
- android.permission.CAMERA stays requested and declared. Meta OpenXR's native
  camera code opens the passthrough cameras with the NDK Camera2 API
  (ACameraManager_openCamera in libUnityARFoundationMeta.so), which checks it.
  Meta OpenXR's manifest provider also adds it while camera image support is
  on, so removing it would also need tools:node="remove". Whether capture
  works without it, and first-launch capture as a whole, still has to be
  checked on a Quest 3.
- EditMode tests cover the gate (first launch, later launch, denial followed by
  a grant in the settings, a dismissed dialog, stop while waiting, the poll
  interval), the shared permission list, and the scene's OVRManager flag.
  The manifest comment and docs/SIDELOAD.md describe the new prompts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
NOTICE.md's native-library rows came from the Meta XR SDK 85 APK. Checked
against the Unity 6000.6.9f1 / Meta XR SDK 209 APK:

- libdouble-conversion.so is no longer shipped. SDK 209's OVRPlugin.aar does
  not contain it, and the new folly logging library has no double_conversion
  symbols, so the double-conversion row and its BSD clause-3 holder are gone.
- New: libxplat_folly_logging__logging.so from OVRPlugin.aar (folly,
  Apache-2.0, Meta). Added as a row next to Zstandard; folly is also listed in
  MRUK's NOTICE.txt.
- The shipped libopenxr_loader.so (524,224 bytes) is the one in Meta's
  OVRPlugin.aar, not Unity's openxr_loader.aar. The Khronos row now says so,
  and it adds com.unity.xr.hands (libUnityOpenXRHands.so), whose Third Party
  Notices.md lists OpenXR-SDK-Source.
- LibRuntimeOptimizer.so (RuntimeOptimizer_Plugin.aar) and the
  libxplat_perflogger_* libraries are Meta's own code under the Meta SDK
  licence, with no third-party licence strings. THIRD_PARTY.md now lists them
  in the com.meta.xr.sdk.core row.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
gradleTemplate.properties existed only to set android.uniquePackageNames=false.
Under AGP 9, Meta XR SDK 85's OVRPlugin.aar, InteractionSdk.aar and
SDKTelemetry.aar all declared the namespace com.oculus.Integration. The
licensing branch removed the Interaction and Voice SDKs, and with them the
other two AARs. Of the four AARs in the build, only OVRPlugin.aar declares
com.oculus.Integration now; the others are com.meta.agenticxr,
com.oculus.RuntimeOptimizer and org.khronos.openxr.openxr_loader_for_android.

The template's own comment said to delete the line and the template once the
duplicates were gone. Apart from that line it matched Unity 6000.6.9f1's
default template, so this deletes the file and turns
useCustomGradlePropertiesTemplate off. A future duplicate namespace fails the
build again instead of being hidden. CommandLineBuild.BuildAndroidQuest
builds without it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
8324e4e was only checked with a dependency resolution. Once built, the image
from that commit could not start its server. The startup hook loads every model
(CV_SERVER_LOAD_ALL defaults to true), and two things broke:

- transformers 5.10.1, from the dependabot bump in dfebb4e, needs a newer torch
  than 2.5.1. It reads torch.float8_e8m0fnu at import time, so BertModel
  (GroundingDINO) and the Florence-2 auto classes fail to import, and
  load_grounding_dino() raises. torch 2.5.1 is the last release with CUDA 12.1
  wheels, so the cu121 index cannot provide a newer one.
- jammy's python3.11 package is 3.11.0~rc1, a 2022 pre-release that gets no
  fixes. With transformers fixed, `import timm` (GroundingDINO's backbone and
  Florence-2's model code) kills it with SIGSEGV inside torch.jit.script. In
  an A/B test with the same packages, upgrading only the interpreter to
  deadsnakes' 3.11.18 made the import work.

Changes:
- Python 3.11 now comes from the deadsnakes PPA (3.11.18) instead of Ubuntu's
  python3.11. The CUDA base image is unchanged.
- transformers==4.40.1, the version the server ran with before the bump. It
  works with torch 2.5.1 and accelerate 1.15.0, which stays. Moving to 5.x
  means moving torch and the CUDA base image first. 4.40.1 has published
  advisories (ReDoS in tokenizers and processors the server does not use,
  deserialization in conversion scripts, code execution through a crafted
  model config or Trainer), all fixed in 4.48 to 5.10. THIRD_PARTY.md
  records them.
- requirements are installed with --no-build-isolation. pip used to build
  SAM 2 against torch 2.15.0 for CUDA 13 (the newest on PyPI), a
  multi-gigabyte download in every build, and SAM 2's CUDA extension was
  then skipped. GroundingDINO's _C now comes from the same build, so the
  separate rebuild of an unpinned clone is removed.
- Pinned to what this image was built and checked with: torch 2.5.1,
  torchvision 0.20.1, torchaudio 2.5.1, flash-attn 2.8.3.post2 (prebuilt
  cp311 / torch 2.5 wheel), packaging 26.3, wheel 0.48.0, GroundingDINO
  856dde2 and SAM 2 2b90b9f. This is THIRD_PARTY.md open item 4, apart
  from Florence-2's revision.
- cv-server/README.md and THIRD_PARTY.md describe the image.

Verified on this machine with Docker 29.9.3 and an RTX 4080 Laptop GPU:
- docker build exited 0 (23.7 min).
- In the image, the flash-attn kernel, GroundingDINO's ms_deform_attn CUDA op
  (checked against its PyTorch reference) and SAM 2's _C run on the GPU.
- The entrypoint fetched the pinned weights and loaded GroundingDINO, SAM 2
  and Florence-2-large at startup. /v1/health answered 401 without the token
  and 200 with it. /v1/detect, /v1/segment and /v1/florence answered 200 on a
  test fixture.
- pytest in the image: 45 passed, 5 skipped. With the weights mounted: 49
  passed, 1 skipped (test_florence is skipped unconditionally).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@mrhegemon
mrhegemon merged commit cf04600 into main Nov 13, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant