Skip to content

Device support shows generic network error when npm blocks install via min-release-age #40684

Open

Description

@listlessbird

What happened

After updating to 0.1.12-nightly.20261122.5071, Settings → Devices failed with:

Device support failed during installing device support. Check the host connection and network access, then retry.

Retrying gave the same error. The actual cause was min-release-age=2 in ~/.npmrc, which made npm reject expo-device-hub@0.26.1 because it was published less than two days earlier. None of npm's stderr is shown in the UI, so the message points at a network problem instead.

Diagnosis

#40095 (merged 2026-11-21) bumped the pinned hub to expo-device-hub@0.26.1 (published 2026-11-20 13:22 UTC). DeviceToolchain.installTool (apps/server/src/device/DeviceToolchain.ts:128) runs npm install --prefix <staging> expo-device-hub@0.26.1, which exits with ETARGET under min-release-age.

Respecting min-release-age matches #19855 (closed as working as designed). Unlike #19855, where npm's stderr reached the user, DeviceToolchainInstallError here is wrapped in a generic DeviceHostUnavailableError and the Settings → Devices banner tells the user to check their host connection and network access (the still-open part noted when closing #17431).

DeviceToolchainInstallError already has a dedicated message for npm_not_found (#28227). Handling ETARGET date-cutoff errors the same way (naming the release-age setting and cutoff date, or showing a safe npm install failure summary instead of generic network advice) would show what actually blocked the install.

Steps to reproduce

  1. Set min-release-age=2 in ~/.npmrc.
  2. Run a build whose pinned expo-device-hub version is under 2 days old (e.g., 0.1.12-nightly.20261122.5071 before 2026-11-22 13:23 UTC).
  3. Open Settings → Devices with "Use devices" enabled.
  4. Observe the generic network/install error with no mention of min-release-age or ETARGET.

Version

Desktop 0.1.12-nightly.20261122.5071 (local server same version, commit 047fb5b).

Environment

  • Linux x64 (kernel 7.0.0-43-generic)
  • Desktop app with a local server
  • Node v26.13.1, npm 11.12.1
  • ~/.npmrc: min-release-age=2

Evidence

From server.trace.ndjson (DeviceToolchain.installTool):

DeviceToolchainInstallError: Installing expo-device-hub failed while running npm install (exit code 1).
  [cause]: {"stderr":"npm error code ETARGET
npm error notarget No matching version found for expo-device-hub@0.26.1 with a date before 20/11/2026, 10:56:49 am."}

The server converts that to DeviceHostUnavailableError: This machine is unavailable: Device support failed during installing device support., which is all the UI displays alongside the generic network advice.

Related issues

Fix applied or workaround

Wait until the pinned version is older than min-release-age, then click Retry. Temporarily removing min-release-age from ~/.npmrc, clicking Retry, and restoring it unblocked the install (couldn't find a per-package min-release-age-exclude option in npm 11.12.1).

Filed by

Claude Code (Claude Opus 5.5), revised with Gemini 4 Neon, via T3 Code triage.

Activity

  1. changed the title [-]Device support fails to install when npm min-release-age excludes the pinned expo-device-hub version[/-] [+]Device support shows generic network error when npm blocks install via min-release-age[/+] on Nov 22, 2026
  2. added a commit that references this issue on Nov 22, 2026
    a62add6
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    via-triageFiled through npx t3 triage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions