Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/native-serving.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,10 @@ jobs:
env:
FLARE_TEST_TEMPLATE_DIR: ${{ runner.temp }}/flare-test-templates
run: cargo test --locked --release --manifest-path flare/Cargo.toml --target-dir flare-cli/target
- name: Test Windows desktop bridge
env:
FLARE_TEST_TEMPLATE_DIR: ${{ runner.temp }}/flare-test-templates
run: cargo test --locked --release --manifest-path flare-winui/bridge/Cargo.toml --target-dir flare-cli/target
- name: Exercise native Windows executable
if: runner.os == 'Windows'
shell: pwsh
Expand Down
41 changes: 34 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -167,29 +167,56 @@ jobs:
if ($LASTEXITCODE -ne 0) { throw 'Release version update failed.' }
- name: Build the desktop client
run: ./scripts/build_winui.ps1 -Platform ${{ matrix.platform }} -SingleFile
- name: Package the desktop client and license notices
- name: Build the CLI
run: |
. ./scripts/dev_windows.ps1
$env:CARGO_TARGET_DIR = Join-Path $localDev 'winui-target'
cargo --config "target.${{ matrix.target }}.rustflags=['-C','target-feature=+crt-static']" `
build --locked --release --manifest-path flare-cli/Cargo.toml --bin flare --target ${{ matrix.target }}
if ($LASTEXITCODE -ne 0) { throw "CLI build failed with exit code $LASTEXITCODE." }
- name: Package the CLI, desktop client, and license notices
run: |
. ./scripts/dev_windows.ps1
$cli = Join-Path $localDev 'winui-target\${{ matrix.target }}\release\flare.exe'
rustup component add rust-docs
if ($LASTEXITCODE -ne 0) { throw 'Rust documentation component installation failed.' }
python packaging/archive.py --binary .local-dev/winui/${{ matrix.platform }}/SingleFile/Flare.exe --target ${{ matrix.target }} --winui-packages .local-dev/native-packages --output $env:ARCHIVE
python packaging/archive.py --binary $cli --desktop-binary .local-dev/winui/${{ matrix.platform }}/SingleFile/flare-app.exe --target ${{ matrix.target }} --winui-packages .local-dev/native-packages --output $env:ARCHIVE
if ($LASTEXITCODE -ne 0) { throw 'Archive packaging failed.' }
- name: Start the packaged desktop client
- name: Verify the packaged CLI and desktop client
run: |
. ./scripts/dev_windows.ps1
$extract = Join-Path $env:RUNNER_TEMP 'flare-archive'
Expand-Archive -LiteralPath $env:ARCHIVE -DestinationPath $extract
foreach ($file in @('Flare.exe', 'LICENSE', 'NOTICE', 'THIRD_PARTY_NOTICES.md', 'licenses\PyTorch.txt',
foreach ($file in @('flare.exe', 'flare-app.exe', 'LICENSE', 'NOTICE', 'THIRD_PARTY_NOTICES.md', 'licenses\PyTorch.txt',
'third_party\rust\README.md', 'third_party\rust-standard-library\version.txt', 'third_party\nuget\README.md')) {
$path = Join-Path $extract "flare\$file"
if (-not (Test-Path -LiteralPath $path -PathType Leaf) -or (Get-Item -LiteralPath $path).Length -eq 0) {
throw "$env:ARCHIVE lacks flare\$file."
}
}
# Launch from a directory that holds only the executable.
# Verify the CLI from a directory that holds only flare.exe.
$cliLaunch = Join-Path $env:RUNNER_TEMP 'flare-cli-launch'
New-Item -ItemType Directory -Path $cliLaunch | Out-Null
Copy-Item -LiteralPath (Join-Path $extract 'flare\flare.exe') -Destination $cliLaunch
$cli = Join-Path $cliLaunch 'flare.exe'
$dependents = & dumpbin /nologo /dependents $cli
if ($LASTEXITCODE -ne 0) { throw 'dumpbin failed to inspect flare.exe.' }
$vcRuntime = $dependents | Where-Object { $_ -match '(?i)^\s*(vcruntime|msvcp|concrt|vcomp)[^ ]*\.dll\s*$' }
if ($vcRuntime) { throw "flare.exe must link the static C runtime; found dynamic VC++ runtime imports: $($vcRuntime -join ', ')" }
$reported = (& $cli --version | Out-String).Trim()
if ($LASTEXITCODE -ne 0) { throw "flare.exe --version failed with exit code $LASTEXITCODE." }
if ($reported -ne "flare $env:VERSION") { throw "flare.exe --version printed `"$reported`"; expected `"flare $env:VERSION`"." }
foreach ($command in @('run', 'download', 'models')) {
& $cli $command --help | Out-Null
if ($LASTEXITCODE -ne 0) { throw "flare.exe $command --help failed with exit code $LASTEXITCODE." }
}
& $cli agent
if ($LASTEXITCODE -eq 0) { throw 'flare.exe accepted unsupported multi-host serving.' }
# Launch the desktop client from a directory that holds only flare-app.exe.
$launch = Join-Path $env:RUNNER_TEMP 'flare-launch'
New-Item -ItemType Directory -Path $launch | Out-Null
Copy-Item -LiteralPath (Join-Path $extract 'flare\Flare.exe') -Destination $launch
$launcher = Start-Process -FilePath (Join-Path $launch 'Flare.exe') -WorkingDirectory $launch -PassThru
Copy-Item -LiteralPath (Join-Path $extract 'flare\flare-app.exe') -Destination $launch
$launcher = Start-Process -FilePath (Join-Path $launch 'flare-app.exe') -WorkingDirectory $launch -PassThru
# Windows PowerShell reports no exit code unless the handle is opened before the process exits.
$null = $launcher.Handle
if (-not $launcher.WaitForExit(120000)) {
Expand Down
1 change: 1 addition & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -316,6 +316,7 @@ cargo test --locked --release --manifest-path selene/Cargo.toml --features test-
cargo test --locked --release --manifest-path selene-manager/Cargo.toml --features test-support --target-dir flare-cli/target
cargo test --locked --release --manifest-path helios/Cargo.toml --features runtime-core,server --target-dir flare-cli/target
cargo test --locked --release --manifest-path flare/Cargo.toml --target-dir flare-cli/target
cargo test --locked --release --manifest-path flare-winui/bridge/Cargo.toml --target-dir flare-cli/target
cargo test --locked --release --manifest-path flare-cli/Cargo.toml
```

Expand Down
35 changes: 20 additions & 15 deletions THIRD_PARTY_NOTICES.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ and notice texts. [packages.json](third_party/rust/packages.json) records versio
source locations, and runtime versus build/proc-macro roles for each target.
Build-tool notices are included conservatively; this does not mean the tools are
distributed. The inventory covers the default Flare build for Linux x86_64,
Linux aarch64, and Windows x86_64 MSVC. Optional `rdma` builds require their own
dependency review before release.
Linux aarch64, Windows x86_64 MSVC, and Windows aarch64 MSVC. Optional `rdma`
builds require their own dependency review before release.

The release packager, `packaging/archive.py`, copies the Rust standard library's
notices from the build toolchain into `third_party/rust-standard-library/` inside
Expand Down Expand Up @@ -84,13 +84,15 @@ runtime files. Its dependency versions are pinned in
`flare-winui/launcher/Cargo.lock`. The CLI notice inventory above does not
cover the desktop.

The desktop release archive carries the desktop's notices. `packaging/archive.py
--winui-packages` collects the Rust dependency notices of the two desktop
lockfiles for the archive's target into `third_party/rust/`, and the license and
notice files of every NuGet package pinned in `flare-winui/packages.config` into
`third_party/nuget/`. Packaging fails when a pinned crate or NuGet package has
no license text. The pinned WebView2 package supplies build metadata only; its
notices are included although none of its files are bundled.
The Windows release archive carries both `flare.exe` and `flare-app.exe` along
with their notices. `packaging/archive.py --binary ... --desktop-binary ...
--winui-packages ...` collects the Rust dependency notices of `flare-cli`,
`flare-winui/bridge`, and `flare-winui/launcher` for the archive's target into
`third_party/rust/`, and the license and notice files of every NuGet package
pinned in `flare-winui/packages.config` into `third_party/nuget/`. Packaging
fails when a pinned crate or NuGet package has no license text. The pinned
WebView2 package supplies build metadata only; its notices are included although
none of its files are bundled.

The Visual C++ runtime DLLs are copied from the newest app-local runtime
directory, such as `Microsoft.VC143.CRT`, of the Visual Studio installation that
Expand All @@ -100,7 +102,7 @@ permits distributing unmodified files from that folder with a program, subject
to the Visual Studio license terms. Visual Studio supplies no license file
beside them, and the archive contains none for them.

The single-file `Flare.exe` embeds the bundled runtime but no notices.
The single-file `flare-app.exe` embeds the bundled runtime but no notices.
Distribute it inside the release archive.

| System component | Terms and use |
Expand Down Expand Up @@ -152,14 +154,17 @@ packager includes LICENSE, NOTICE, this document, adapted-code licenses, native
dependency notices, and toolchain notices. It copies no Python packages,
Heliopause extension, model weights, or prepared model assets.

Package the Windows desktop after `scripts/build_winui.ps1 -SingleFile`, from
the shell that `scripts/dev_windows.ps1` configures, so that `cargo` and `rustc`
are the toolchain that built it. `--winui-packages` names the directory into
which the build restored the pinned NuGet packages:
Package the Windows release archive after building the desktop with
`scripts/build_winui.ps1 -SingleFile` and building `flare.exe`, from the shell
that `scripts/dev_windows.ps1` configures, so that `cargo` and `rustc` are the
toolchain that built them. `--winui-packages` names the directory into which
the build restored the pinned NuGet packages:

```powershell
rustup component add rust-docs
python packaging/archive.py --binary .local-dev/winui/ARM64/SingleFile/Flare.exe `
python packaging/archive.py `
--binary "$env:LOCALAPPDATA\FlareDev\winui-target\aarch64-pc-windows-msvc\release\flare.exe" `
--desktop-binary .local-dev/winui/ARM64/SingleFile/flare-app.exe `
--target aarch64-pc-windows-msvc --winui-packages .local-dev/native-packages `
--output flare-windows-arm64.zip
```
Expand Down
2 changes: 1 addition & 1 deletion docs/TODO.txt
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@
integration test. A CRLF checkout changes the hash used by the upgrade check.

[ ] Qualify the Windows desktop client beyond Windows 11 ARM64: x64 linking and
inference, Flare.exe on a machine without the development environment,
inference, flare-app.exe on a machine without the development environment,
transfer interruption, switching under load, accessibility, and recovery
from sleep or GPU reset. See flare-winui/README.md.

Expand Down
55 changes: 32 additions & 23 deletions docs/release.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,23 @@
The GitHub Actions workflow `.github/workflows/release.yml` publishes a GitHub
Release when a version tag is pushed. A release holds one archive per platform:

| Asset | Runner | Executable |
| Asset | Runner | Executables |
|---|---|---|
| `flare-linux-amd64.tgz` | `ubuntu-24.04` | `flare/flare`, the CLI |
| `flare-linux-arm64.tgz` | `ubuntu-24.04-arm` | `flare/flare`, the CLI with the RoCE transport |
| `flare-windows-amd64.zip` | `windows-2025` | `flare/Flare.exe`, the [desktop client](../flare-winui/README.md) |
| `flare-windows-arm64.zip` | `windows-11-arm` | `flare/Flare.exe`, the desktop client |
| `flare-windows-amd64.zip` | `windows-2025` | `flare/flare.exe`, the CLI; `flare/flare-app.exe`, the [desktop client](../flare-winui/README.md) |
| `flare-windows-arm64.zip` | `windows-11-arm` | `flare/flare.exe`, the CLI; `flare/flare-app.exe`, the desktop client |

Archive names carry no version, so
`releases/latest/download/flare-linux-arm64.tgz` always names the most recent
release. Each archive also contains `LICENSE`, `NOTICE`,
`THIRD_PARTY_NOTICES.md`, `licenses/`, and `third_party/`, as
[third-party notices](../THIRD_PARTY_NOTICES.md) describes.

A release contains no Windows CLI, Debian package, Selene manager, or
container image. Build those from source: [Windows serving](windows.md),
[Debian packages](debian.md), [the Selene manager](../selene-manager/README.md),
and [container](container.md). Ignition, Python, and model cores are separate
A release contains no Debian package, Selene manager, or container image. Build
those from source: [Debian packages](debian.md),
[the Selene manager](../selene-manager/README.md), and
[container](container.md). Ignition, Python, and model cores are separate
preparation inputs and are never part of a release.

## Host requirements
Expand All @@ -33,8 +33,10 @@ libraries, and no build links the CUDA toolkit.
when serving multi-host RoCE cores. Single-host serving requires no RDMA
packages; multi-host RoCE serving requires `libibverbs1` and
`ibverbs-providers`.
- The Windows desktop requires Windows 11. It bundles its Windows App SDK and
Visual C++ runtime files. `Flare.exe` is unsigned.
- The Windows release executables link the static C runtime (`+crt-static`) and
are unsigned. `flare-app.exe` requires Windows 11 and bundles its Windows App
SDK and Visual C++ runtime files; `flare.exe` requires no separate Visual C++
Redistributable installation.

Release executables embed no publisher verification profiles; publisher
acceptance follows [signing](signing.md) as it does for a source build.
Expand Down Expand Up @@ -78,12 +80,19 @@ before anything is published; no target can be skipped.
`flare --version` must print `flare VERSION`, and `flare run --help`,
`flare agent --help`, and `flare orbit --help` must succeed.
- **Windows.** The runner installs tools with
`scripts/setup_windows.ps1 -RustToolchain 1.94.1 -BuildToolsOnly`, builds
with `scripts/build_winui.ps1 -Platform PLATFORM -SingleFile`, and packages
with `packaging/archive.py --winui-packages`. `Flare.exe` is then started
from a directory that contains no other file. The launcher must exit with
code zero, and `flare-winui.exe` must open a window from the extracted
runtime and still be running 15 seconds later.
`scripts/setup_windows.ps1 -RustToolchain 1.94.1 -BuildToolsOnly`, builds the
desktop client with `scripts/build_winui.ps1 -Platform PLATFORM -SingleFile`,
builds `flare.exe` from `flare-cli/Cargo.toml` with `+crt-static` in the same
target directory, and packages both executables with
`packaging/archive.py --binary ... --desktop-binary ... --winui-packages ...`.
The job checks `flare.exe` from a directory that holds no other file:
`dumpbin /dependents` must show no dynamic Visual C++ runtime imports,
`flare.exe --version` must print `flare VERSION`, `flare.exe run --help`,
`flare.exe download --help`, and `flare.exe models --help` must succeed, and
`flare.exe agent` must exit non-zero. `flare-app.exe` is then started from a
directory that contains no other file. The launcher must exit with code zero,
and `flare-winui.exe` must open a window from the extracted runtime and still
be running 15 seconds later.
- **Publication.** `gh release create --draft --generate-notes` attaches the
four archives, then `gh release edit --draft=false` publishes the release.
If publication fails after the draft exists, delete the draft before
Expand All @@ -100,12 +109,12 @@ Serving qualification is stated per platform in [Windows serving](windows.md),
extend it. The workflow runs no crate test suites; `Native serving` runs them
on x86_64 Linux and x86_64 Windows only.

Qualified on x86_64 Linux outside GitHub Actions: packaging the CLI with
`packaging/archive.py` and the workflow's clean-container check, including its
rejection of a version that differs from the expected one. The desktop archive
layout is qualified with a placeholder in place of `Flare.exe` and the pinned
NuGet packages downloaded from nuget.org.
Qualified on x86_64 Linux outside GitHub Actions: packaging CLI-only archives
and combined Windows CLI and desktop archives with `packaging/archive.py`
(using placeholder executables and fixture NuGet notice files for both
`x86_64-pc-windows-msvc` and `aarch64-pc-windows-msvc`), and the workflow's
clean-container Linux check, including rejection of a mismatched version.

Not qualified: any run of the workflow on GitHub-hosted runners, the arm64
Linux build and check, the Windows build and startup check on either
architecture, and publication.
Not qualified: the Windows combined CLI and desktop build and verification
steps on GitHub-hosted `windows-2025` and `windows-11-arm` runners, including
static-CRT `flare.exe` linking and `dumpbin` inspection.
16 changes: 9 additions & 7 deletions docs/windows.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,10 @@ Ignition can also prepare the single-GPU `qwen3.8-27b` recipe on Windows with

The Windows runtime uses the NVIDIA driver directly through `nvcuda.dll`.
Python, the CUDA toolkit, WSL, and Wine are not runtime dependencies.
Install the NVIDIA driver. CLI builds also require the Microsoft Visual C++
Redistributable for the host architecture. The desktop distribution includes
its runtime dependencies.
Install the NVIDIA driver. Default local CLI builds also require the Microsoft
Visual C++ Redistributable for the host architecture; release `flare.exe`
binaries link the static C runtime, and the desktop distribution includes its
runtime dependencies.

On Windows and Unix terminals, startup displays the static banner once.
Loading progress continues below the static banner.
Expand Down Expand Up @@ -267,7 +268,7 @@ Build from the repository root after setting up the native development tools:

```powershell
.\scripts\build_winui.ps1 -Platform ARM64 -SingleFile
.\.local-dev\winui\ARM64\SingleFile\Flare.exe
.\.local-dev\winui\ARM64\SingleFile\flare-app.exe
```

The default launch reads the same user configuration and core cache as the
Expand All @@ -279,7 +280,7 @@ development cache configured by the setup script.

Use `-Platform x64` for an x64 distribution. The helper restores pinned Windows
App SDK and C++/WinRT packages, links the Rust static library, and bundles the
Release runtime into one desktop `Flare.exe`. Its launcher silently extracts
Release runtime into one desktop `flare-app.exe`. Its launcher silently extracts
the runtime beneath the Windows Local App Data known folder at
`Flare/Desktop/<ARM64|x64>/<archive-SHA256>` on first launch, then starts the
native `flare-winui.exe`. Repeat launches reuse the extracted version; versions
Expand All @@ -294,8 +295,9 @@ create and validate the embedded ZIP without compiling the launcher. The ZIP
records file sizes and SHA-256 digests with fixed ordering and timestamps.
The launcher uses the static C runtime; build outputs are unsigned. An
installer, signing workflow, and automatic runtime-cache cleanup are not provided.
[Binary releases](release.md) publish `Flare.exe` with its license notices as
`flare-windows-amd64.zip` and `flare-windows-arm64.zip`.
[Binary releases](release.md) publish `flare.exe` and `flare-app.exe` with
their license notices as `flare-windows-amd64.zip` and
`flare-windows-arm64.zip`.

Omit `-SingleFile` for the loose development workflow, launching
`.local-dev\winui\<ARM64|x64>\Release\flare-winui.exe` with its complete
Expand Down
2 changes: 1 addition & 1 deletion flare-winui/Assets/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,5 @@ window and taskbar; no external icon file is required at runtime.
`flare-winui/flare-winui.rc` also embeds `flare-app-128.png` as the
`IDB_FLARE_TITLE` resource, which supplies the title bar image.
`flare-winui/resource.h` defines both identifiers. The single-file launcher
`Flare.exe` embeds `flare-app.ico` as icon resource 1 through
`flare-app.exe` embeds `flare-app.ico` as icon resource 1 through
`flare-winui/launcher/build.rs`.
Loading
Loading