Source builds: missing UI library error suggests `perry target add`, which cannot work without update keys

Open Beginner friendly
#15,210 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
70/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
rust
Domain
build-system, cli

Research direction

Search the perry CLI crate for the diagnostic text "which is not installed, and this perry cannot verify a download" to find where the missing UI library hint is assembled. Read the neighbouring missing-runtime-library message that already prints the source-build route (cargo build -p perry-runtime-static, PERRY_RUNTIME_DIR) and mirror that wording for the UI crate. Done when a build without update keys suggests cargo build --release -p perry-ui-<platform> plus PERRY_RUNTIME_DIR instead of perry target add, and the existing CLI tests still pass.

Written by the indexing model from the issue text.

Description

type:bug
Where does it go wrong?

Installing or running the perry CLI itself

What happened

With a perry built from source, compiling a perry/ui program for any target fails with:

error: this perry/ui program links `libperry_ui_macos.a`; it ships in @perryts/[email protected], which is not installed, and this perry cannot verify a download: this Perry release has no trusted CLI update public keys; self-update is disabled until the release is built with PERRY_CLI_UPDATE_PUBLIC_KEYS
Install them:
  perry target add --ui

The suggested command cannot succeed for the reason given in the same message. The missing runtime library error already explains the source-build route (cargo build --release -p perry-runtime-static --target <triple>, scripts/gc_call_effects/sidecars.sh, PERRY_RUNTIME_DIR). The UI library error does not.

What you expected

On a build without update keys, the hint names the source route for the UI crate: cargo build --release -p perry-ui-<platform> --target <triple>, plus PERRY_RUNTIME_DIR pointing at that target dir. That is what worked for me on macos, ios-simulator and android.

Minimal reproduction
import { Text } from "perry/ui"
Text("hi")
Command you ran
cargo build --release -p perry
./target/release/perry compile main.ts -o app --target macos
Perry version

perry 0.5.1663 (built from source at 05812f75d9)

Host OS

macOS 27.0.1 arm64

How did you install Perry?

Built from source

Target platform

macos, ios-simulator, android

Dominant language
Rust
Stars
4.9k
Forks
166
Avg merge
6h 59m
Merged PRs (30d)
955

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from PerryTS/perry

All issues in PerryTS/perry

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.