Skip to content

docs(building): note elevated-prompt ActiveRuntime trap re-triggers the ABI failure#644

Open
leaiss wants to merge 1 commit into
docs/from-source-dp-registration-abifrom
docs/from-source-dp-registration-elevated
Open

docs(building): note elevated-prompt ActiveRuntime trap re-triggers the ABI failure#644
leaiss wants to merge 1 commit into
docs/from-source-dp-registration-abifrom
docs/from-source-dp-registration-elevated

Conversation

@leaiss

@leaiss leaiss commented Jun 23, 2026

Copy link
Copy Markdown
Collaborator

Stacked on #642.

What this adds

A from-source dev (Cyrus) followed the #642 guidance correctly — register_dev_plugin.bat + displayxr-cli selftestSELF-TEST PASSED — but launching cube_hosted_d3d11_win.bat from a fresh elevated prompt still went purple / "Failed to initialize OpenXR". It looked like the registration "only applied to the one prompt where I ran it."

It didn't. Two separate scopes were being conflated:

  • Plug-in registration (HKLM\Software\DisplayXR\DisplayProcessors) is machine-wide and permanent — not per-session.
  • Which runtime loads is what varies. run_*.bat sets XR_RUNTIME_JSON to the from-source runtime, but the Khronos loader silently ignores XR_RUNTIME_JSON in an elevated/admin process and falls back to the installed runtime via ActiveRuntime. That older runtime then ABI-rejects the freshly-registered plug-in — re-triggering the exact negotiate returned -17 failure docs(building): clarify from-source DP registration (ABI-stale plug-in case) #642 documents.

This is not a runtime bug — the ABI gate, registry-only discovery, and the loader's elevated env-var refusal are all working as designed. It's a docs/ergonomics gap: the existing callout didn't connect the elevated-terminal caveat to the ABI-rejection trap.

Change

One paragraph appended to the from-source DP-registration callout in docs/getting-started/building.md, pointing at the two fixes: run non-elevated (so XR_RUNTIME_JSON is honored), or dev-setup.bat once (sets ActiveRuntime machine-wide so any prompt works with no env var).

Docs-only.

🤖 Generated with Claude Code

@leaiss leaiss requested a review from dfattal as a code owner June 23, 2026 15:27
…he ABI failure

After a correct, ABI-matched plug-in registration, running a test app from an
elevated prompt still goes purple / "Failed to initialize OpenXR": the Khronos
loader ignores XR_RUNTIME_JSON in an elevated process and falls back to the
installed runtime via ActiveRuntime, which then ABI-rejects the freshly-
registered plug-in. It reads as if the registration "only applied to one
prompt" when registration is actually machine-wide and permanent — what's
session-scoped is which runtime the loader picks.

Add a third paragraph to the from-source DP-registration callout connecting the
elevated-terminal caveat to the ABI-rejection trap, and point at the two fixes:
run non-elevated (XR_RUNTIME_JSON honored) or dev-setup.bat (sets ActiveRuntime).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@leaiss leaiss force-pushed the docs/from-source-dp-registration-elevated branch from b8f921c to 5feb3dc Compare June 23, 2026 15:29
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