Skip to content

Show effective AMM registry source and snapshot status - #412

Open
3esmit wants to merge 1 commit into
mainfrom
fix/registry-source-status-176
Open

3esmit wants to merge 1 commit into
mainfrom
fix/registry-source-status-176

Conversation

@3esmit

@3esmit 3esmit commented Oct 5, 2026 •

Copy link
Copy Markdown
Collaborator

Settings now identifies the configured registry URL separately from the source supplying the current token and pool lists. A QtRO status map exposes the effective request URL, environment override, published snapshot source and origin, and refresh progress or failure.

When registry B is requested while registry A remains loaded, Settings continues to identify A as the data source. A cached snapshot is labeled with its validated cache URL. Local configuration and empty network lists receive explicit explanations. The modal scrolls within short windows and displays long URLs as plain text.

Status-only changes use a separate loader signal, so starting or failing a request does not bump registryRevision or re-publish AMM program/config IDs. The existing source precedence and cache acceptance rules remain intact.

Validation

  • Standalone amm_registry_status CTest passes with Qt 6.11.0, covering local and URL overrides, pending and failed refreshes, matching and mismatched cache origins, invalid/empty registry documents, and superseded requests.
  • Focused Settings QML tests cover editable saved preferences, retained snapshot provenance, network selection and empty states, and long URL layout in a 320 × 300 viewport.
  • Qt 6.9.2 repc generates the updated source contract successfully.

Fixes #407 https://github.com/logos-co/audit-reports/issues/176

Copilot AI balanced review requested due to automatic review settings October 5, 2026 05:50

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

The implementation matches the requested provenance behavior and includes focused coverage for state transitions and UI edge cases.

Review effort: Balanced
Findings: None

What changed in this PR

Adds accurate AMM registry provenance and refresh status to Settings while preserving loaded snapshots during pending or failed requests.

Changes:

  • Exposes registry request, snapshot, override, loading, and error status through QtRO.
  • Adds a responsive, scrollable Settings status UI.
  • Adds C++ and QML coverage for provenance, caching, failures, and layout.
File Description
apps/​amm/​CMakeLists.txt Registers C++ tests.
apps/​amm/​qml/​chrome/​SettingsModal.qml Displays registry provenance and status.
apps/​amm/​src/​AmmUiBackend.cpp Publishes loader status through QtRO.
apps/​amm/​src/​AmmUiBackend.rep Adds the registry status property.
apps/​amm/​src/​RegistryLoader.cpp Tracks request and snapshot state separately.
apps/​amm/​src/​RegistryLoader.h Defines the status API and state.
apps/​amm/​tests/​cpp/​CMakeLists.txt Configures registry status tests.
apps/​amm/​tests/​cpp/​RegistryStatusTest.cpp Tests loader status behavior.
apps/​amm/​tests/​qml/​tst_SettingsModal.qml Tests Settings presentation and responsiveness.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@3esmit 3esmit added type: bug Something isn't working amm AMM protocol, its Logos module and the DEX application. app User application UI/backend, screens, flows, settings, presentation or application fixture/setup. labels Oct 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

amm AMM protocol, its Logos module and the DEX application. app User application UI/backend, screens, flows, settings, presentation or application fixture/setup. type: bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Show effective AMM registry source and snapshot status

2 participants