Skip to content

Windows WHPX: container-update --cpus 2 bypasses run/create single-vCPU fail-closed #262

Closed

Description

@ZhiXiao-Lin

Summary

On Windows WHPX, a3s-box run --cpus 2 and create --cpus 2 fail closed correctly, but container-update --cpus 2 accepts and persists cpus: 2. A later start then fails with the WHPX single-vCPU error. This bypasses the platform invariant and leaves the box in a poisoned configuration.

Evidence (a3s-box 3.2.5, WHPX)

a3s-box create --name upd2 --cpus 1 alpine -- sleep 60   # ok
a3s-box container-update --cpus 2 upd2                   # rc=0, inspect cpus becomes 2
a3s-box start upd2
# stderr: Configuration error: the Windows WHPX backend currently supports exactly 1 virtual CPU; requested 2
# stdout: Starting box upd2...

a3s-box run --rm --cpus 2 alpine -- true
# stderr: --cpus: the Windows WHPX backend currently supports exactly 1 virtual CPU; requested 2

Also observed: container-update --cpus 2 --memory 1g on a dead box returned rc=0 and inspect showed cpus: 2.

Expected

  • container-update applies the same WHPX vCPU validation as run/create before persisting.
  • Reject --cpus != 1 on Windows with the same diagnostic; leave prior config unchanged.
  • CLI coverage: Windows test that update with --cpus 2 fails and inspect remains cpus: 1.

First-principles test cases

  • WIN-NEG-CUPD-01: update --cpus 2 on created/stopped box fails closed, no persist
  • WIN-NEG-CUPD-02: update --cpus 2 on running box fails closed (live Tier-2 path)
  • WIN-NEG-CUPD-03: run/create --cpus 2 remain fail-closed (already true)

Activity

  1. added
    bug
    area/runtime
    priority/medium
    on Sep 7, 2026
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

    area/runtimebugpriority/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions