sipeed/picoclaw · error

feishu channel is not supported on 32-bit architectures (arm

Error message

feishu channel is not supported on 32-bit architectures (armv7l, 386, etc.). Please use a 64-bit system or disable feishu in your config

What it means

Returned by NewFeishuChannel in pkg/channels/feishu/feishu_32.go:23, a stub file selected by the build tag '//go:build !amd64 && !arm64 && !riscv64 && !mips64 && !ppc64' — i.e. every 32-bit GOARCH (386, arm, armv7l, 386, mips, etc.). The Feishu (Lark) SDK dependency only compiles on 64-bit architectures, so on 32-bit builds the constructor, Start, Stop, and Send are stubs that always return errors. Startup of a picoclaw binary with a feishu channel enabled on 32-bit therefore fails at channel construction.

Source

Thrown at pkg/channels/feishu/feishu_32.go:23

import (
	"context"
	"errors"

	"github.com/sipeed/picoclaw/pkg/bus"
	"github.com/sipeed/picoclaw/pkg/channels"
	"github.com/sipeed/picoclaw/pkg/config"
)

// FeishuChannel is a stub implementation for 32-bit architectures
type FeishuChannel struct {
	*channels.BaseChannel
}

var errUnsupported = errors.New("feishu channel is not supported on 32-bit architectures")

// NewFeishuChannel returns an error on 32-bit architectures where the Feishu SDK is not supported
func NewFeishuChannel(bc *config.Channel, cfg *config.FeishuSettings, bus *bus.MessageBus) (*FeishuChannel, error) {
	return nil, errors.New(
		"feishu channel is not supported on 32-bit architectures (armv7l, 386, etc.). Please use a 64-bit system or disable feishu in your config",
	)
}

// Start is a stub method to satisfy the Channel interface
func (c *FeishuChannel) Start(ctx context.Context) error {
	return errUnsupported
}

// Stop is a stub method to satisfy the Channel interface
func (c *FeishuChannel) Stop(ctx context.Context) error {
	return errUnsupported
}

// Send is a stub method to satisfy the Channel interface
func (c *FeishuChannel) Send(ctx context.Context, msg bus.OutboundMessage) ([]string, error) {
	return nil, errUnsupported
}

View on GitHub (pinned to 49183d7e8d)

Solutions

  1. Use a 64-bit build/OS: rebuild with GOARCH=arm64 or GOARCH=amd64, or install a 64-bit OS/image (e.g. Raspberry Pi OS 64-bit)
  2. If 32-bit must stay, remove or disable the feishu channel from the config so the stub constructor is never invoked
  3. For Docker, ensure the image platform matches the host: docker run --platform linux/arm64 ...
  4. Substitute feishu with a channel that supports 32-bit (e.g. another notification channel) if Feishu delivery is required

Example fix

// before (config.yaml fragment)
channels:
  - name: feishu
    type: feishu
    enabled: true

// after: disable on 32-bit hosts
channels:
  - name: feishu
    type: feishu
    enabled: false
Defensive patterns

Strategy: fallback

Validate before calling

import "runtime"

// before constructing the channel
if runtime.GOARCH == "386" || runtime.GOARCH == "arm" || runtime.GOARCH == "mips" || runtime.GOARCH == "mipsle" {
    // skip feishu: the 32-bit stub build only returns errors
    log.Printf("feishu channel disabled on %s; requires a 64-bit build", runtime.GOARCH)
} else {
    ch, err := feishu.NewFeishuChannel(bc, cfg, bus)
}

Type guard

func is64BitArch() bool {
    switch runtime.GOARCH {
    case "amd64", "arm64", "riscv64", "mips64", "mips64le", "ppc64", "ppc64le":
        return true
    }
    return false
}

Try / catch

ch, err := feishu.NewFeishuChannel(bc, cfg, bus)
if err != nil {
    if strings.Contains(err.Error(), "not supported on 32-bit") {
        // degrade gracefully: continue without feishu rather than aborting startup
        log.Printf("skipping feishu channel: %v", err)
        continue
    }
    return fmt.Errorf("feishu channel: %w", err)
}

Prevention

When it happens

Trigger: Building or running picoclaw with GOARCH=386 or GOARCH=arm (e.g. on a Raspberry Pi 32-bit OS or legacy x86) while config enables the feishu channel; cross-compiling a 32-bit binary from a 64-bit host with CGO_ENABLED=0 GOARCH=386 and deploying it with the same config.

Common situations: Deploying to ARMv7 boards (original Raspberry Pi OS 32-bit, some NAS firmware); Docker image pulled with the wrong platform (linux/386 or linux/arm instead of linux/arm64); a config file copied from a 64-bit machine that used feishu notifications.

Related errors


AI-assisted analysis of sipeed/picoclaw@49183d7e8d (2026-08-15). Data as JSON: /api/errors/572502b860891d00. Report an issue: GitHub.