apache/beam · error · ValueError

Machine architecture

Error message

Machine architecture "%s" unsupported for constructing a Prism release binary URL.

What it means

Prism releases are only published for amd64 and arm64 architectures. After normalizing common machine names (x86_64, aarch64, etc.), _construct_download_url raises this ValueError for any other architecture, so no release binary URL can be built.

Solutions

  1. Build prism from source (`go build`) for your architecture and pass --prism_location.
  2. Run on an amd64 or arm64 machine/container instead.
  3. Use an external prism job server via --job_endpoint.

Example fix

// before (ppc64le, no override)
--runner=PrismRunner
// after
--runner=PrismRunner --prism_location=/opt/prism/prism-ppc64le
Defensive patterns

Strategy: validation

Validate before calling

import platform, sys
arch = platform.machine().lower()
OK = {'amd64', 'x86_64', 'x86-64', 'x64', 'arm64', 'aarch64', 'aarch64_be', 'armv8b', 'armv8l'}
if arch not in OK and not prism_location_override:
    sys.exit(f'no prism release for {arch}; build prism and set --prism_location')

Prevention

When it happens

Trigger: Running PrismRunner (without a local binary or --prism_location override) on architectures like 386, riscv64, ppc64le, s390x, or armv7.

Common situations: Older 32-bit machines; RISC-V/POWER dev boards; s390x mainframe Linux (e.g. Z/OS-based CI); Raspberry Pi on 32-bit ARM OS.

Understand the failure class

Background: "unsupported platform" / "not supported on this platform" errors: what they mean and how to fix them — this error's family across 47 libraries.

Related errors


AI-assisted analysis of apache/beam@12126d8942 (2026-09-13). Data as JSON: /api/errors/ee0a8f168bf5bdb3. Report an issue: GitHub.

Appendix: source

Thrown at sdks/python/apache_beam/runners/portability/prism_runner.py:331

    and canonical names used by the Go build targets.

    platform.system() provides compatible listings, so we need to filter out
    the unsupported versions."""
    opsys = sys.lower()
    if opsys not in ['linux', 'windows', 'darwin']:
      raise ValueError(
          'Operating System "%s" unsupported for constructing a Prism release '
          'binary URL.' % (opsys))

    # platform.machine() will vary by system, but many names are compatible.
    arch = mach.lower()
    if arch in ['amd64', 'x86_64', 'x86-64', 'x64']:
      arch = 'amd64'
    if arch in ['arm64', 'aarch64_be', 'aarch64', 'armv8b', 'armv8l']:
      arch = 'arm64'

    if arch not in ['amd64', 'arm64']:
      raise ValueError(
          'Machine architecture "%s" unsupported for constructing a Prism '
          'release binary URL.' % (opsys))

    # Some special handling is needed when creating url for release candidates.
    # For example, v2.66.0rc2 should have the following url
    # https://github.com/apache/beam/releases/download/v2.66.0-RC2/apache_beam-v2.66.0-prism-xxx-yyy.zip
    if 'rc' in version:
      version = version.split('rc')[0]

    if 'rc' in root_tag:
      root_tag = '-RC'.join(root_tag.split('rc'))

    return (
        GITHUB_DOWNLOAD_PREFIX +
        f"{root_tag}/apache_beam-{version}-prism-{opsys}-{arch}.zip")

  @staticmethod
  def _resolve_from_location_override(path, version) -> str:

View on GitHub (pinned to 12126d8942)