Claude 07cf57ef06
fix: load the blockchain UI module in the basecamp/standalone host
BlockchainBackend's constructor called LogosAPIClient::requestObject()
for liblogos_blockchain_module while running inside initLogos(). ui-host
invokes initLogos() synchronously (Qt::DirectConnection) and only
signals READY after it returns, but requestObject() blocks for its full
20s timeout when the backend node module isn't running yet — the normal
case, since the node is started from this UI. ui-host therefore missed
its readiness deadline, the host killed the process, and the whole view
failed to load ("Failed to load UI plugin").

Defer the newBlock subscription to subscribeToBlockEvents(), invoked
after a successful startBlockchain(), so initLogos() returns immediately
and the QML view loads whether or not the node is running yet. Also stop
forcing ErrorSubscribeFailed at construction.

Add tests/ui-tests.mjs: a hermetic integration test
(nix build .#integration-test) that loads the module in
logos-standalone-app and asserts the config view renders, guarding
against this regression.

https://claude.ai/code/session_01LJrxZLLrdQZXakNMCEyExE
2026-05-15 22:18:43 +00:00
2026-02-25 00:05:51 +01:00

logos-blockchain-ui

A QML + C++ backend UI module for the Logos platform that provides a graphical interface to control and monitor the Logos blockchain node.

Built with logos-module-builder using the mkLogosQmlModule pattern (QML frontend + C++ backend with Qt Remote Objects).

Features

  • Start/Stop blockchain node
  • Configure node parameters (config path, deployment)
  • Check wallet balances
  • Monitor node status and information
  • Account management

Standalone App Quickstart

  1. Build and run the app:
nix run
  1. Generate a new config using initial peers from the live testnet. Find peers here.

  2. Start the node and let it sync. Track progress:

watch -n1 'curl -s localhost:8080/cryptarchia/info'

Compare the height with the block explorer.

  1. Request funds from the faucet — copy one of the keys from the UI and paste it there.

  2. Once synced, refresh your balance to see your funds.

Leaving the node running for ~3.5 hours allows your tokens to age and become eligible for consensus participation (automatic).

For a video walkthrough, see this recording.

How to Run

# Run directly
nix run

# With local workspace overrides
nix run --override-input liblogos_blockchain_module path:../logos-blockchain-module \
        --override-input liblogos_blockchain_module/logos-module-builder path:../logos-module-builder

In Basecamp

# Build LGX
nix build .#lgx

# Install into Basecamp's plugin directory
lgpm --ui-plugins-dir ~/Library/Application\ Support/Logos/LogosBasecampDev/plugins \
     install --file result/*.lgx

Or from the workspace:

ws bundle logos-blockchain-ui --auto-local

Build Targets

nix build            # default — combined plugin + QML output
nix build .#lgx      # .lgx package for distribution
nix build .#install  # lgpm-installed output (modules/ + plugins/)
nix run              # standalone app with blockchain module
nix develop          # enter development shell

Module Structure

logos-blockchain-ui/
├── flake.nix                       # mkLogosQmlModule
├── metadata.json                   # Module config (ui_qml type)
├── CMakeLists.txt                  # logos_module() macro
└── src/
    ├── BlockchainBackend.rep       # RemoteObject interface
    ├── BlockchainBackend.h/cpp     # Business logic (extends BlockchainBackendSimpleSource)
    ├── BlockchainPlugin.h/cpp      # Thin plugin entry point
    ├── BlockchainPluginInterface.h # Plugin interface marker
    ├── AccountsModel.h/cpp         # QAbstractListModel for accounts
    ├── LogModel.h/cpp              # QAbstractListModel for logs
    └── qml/
        └── BlockchainView.qml     # QML frontend (+ sub-views)

Configuration

Blockchain Node Configuration

  • Via UI: Enter the config path in the "Config Path" field
  • Via Environment Variable: Set LB_CONFIG_PATH to your configuration file path

QML Hot Reload

During development, set the environment variable to load QML from disk:

export BLOCKCHAIN_UI_QML_PATH=/path/to/logos-blockchain-ui/src/qml

Dependencies

Dependency Purpose
Qt6 Core, Gui, RemoteObjects, Declarative UI framework + IPC
logos-module-builder Build system (mkLogosQmlModule)
logos-blockchain-module Blockchain backend module
Repository Role
logos-blockchain-module Blockchain backend — this UI's required dependency
logos-module-builder Module build system
logos-liblogos Logos Core platform
Description
Blockchain UI app for Logos Core
Readme
Languages
QML 46.3%
C++ 29.1%
Nix 14.6%
CMake 10%