RPC Command Console QML Surface #508

Closed
opened 2026-02-28 16:54:04 +00:00 by johnny9 · 5 comments
johnny9 commented 2026-02-28 16:54:04 +00:00 (Migrated from github.com)

Summary

Provide a QML-native RPC console using interfaces::Node::executeRpc and listRpcCommands.

Complexity

  • L

Dependencies

  • 01
  • 02

Global Constraints

  • All implementation lives under gui-qml/.
  • No GUI runtime dependency on bitcoin/src/qt components. Reused logic must be moved/ported into gui-qml/.
  • Do not change interfaces::Wallet or interfaces::Node in this version.
  • Issue completion must satisfy DefinitionOfDone.md.

Scope

  • Create RPC console page with input, history, output, help hinting, and clear behavior.
  • Support command parsing with params and safe error display.
  • Include anti-scam warning messaging equivalent to Qt behavior.
  • Do not reuse qt/rpcconsole.*.

Acceptance Criteria (DoD-Aligned)

  1. Known safe RPC calls (e.g., getnetworkinfo) execute and render JSON output.
  2. Invalid commands and malformed params show actionable errors.
  3. Command history works via keyboard navigation and does not leak across app modes unexpectedly.

Required Tests

  • C++ unit tests: Unit tests for command parsing/execution adapter.
  • QML QTest: QTests for history navigation, focus behavior, and rendering states.
  • Python E2E (qml/test/testbridge.h): E2E flow: open console -> run valid command -> run invalid command -> verify output/error surfaces.

Implementation Notes

  • Long-running RPC calls must run off UI thread and marshal results back safely.
## Summary Provide a QML-native RPC console using `interfaces::Node::executeRpc` and `listRpcCommands`. ## Complexity - `L` ## Dependencies - `01` - `02` ## Global Constraints - All implementation lives under `gui-qml/`. - No GUI runtime dependency on `bitcoin/src/qt` components. Reused logic must be moved/ported into `gui-qml/`. - Do not change `interfaces::Wallet` or `interfaces::Node` in this version. - Issue completion must satisfy `DefinitionOfDone.md`. ## Scope - Create RPC console page with input, history, output, help hinting, and clear behavior. - Support command parsing with params and safe error display. - Include anti-scam warning messaging equivalent to Qt behavior. - Do not reuse `qt/rpcconsole.*`. ## Acceptance Criteria (DoD-Aligned) 1. Known safe RPC calls (e.g., `getnetworkinfo`) execute and render JSON output. 2. Invalid commands and malformed params show actionable errors. 3. Command history works via keyboard navigation and does not leak across app modes unexpectedly. ## Required Tests - C++ unit tests: Unit tests for command parsing/execution adapter. - QML QTest: QTests for history navigation, focus behavior, and rendering states. - Python E2E (`qml/test/testbridge.h`): E2E flow: open console -> run valid command -> run invalid command -> verify output/error surfaces. ## Implementation Notes - Long-running RPC calls must run off UI thread and marshal results back safely.
GBKS commented 2026-03-23 11:00:22 +00:00 (Migrated from github.com)

Initial designs are here. Very sure they need to be iterated and finessed, for which it would be great to get some feedback from people who use the console frequently.

Initial designs are [here](https://bitcoincore.app/console/). Very sure they need to be iterated and finessed, for which it would be great to get some feedback from people who use the console frequently.
hebasto commented 2026-03-23 20:36:35 +00:00 (Migrated from github.com)

It seems prudent to keep this in mind during work on the implementation.

It seems prudent to keep [this](https://github.com/bitcoin-core/gui/issues/932) in mind during work on the implementation.
GBKS commented 2026-03-24 06:57:26 +00:00 (Migrated from github.com)

It seems prudent to keep this in mind during work on the implementation.

Interesting one. QML might not have this problem, but we may also need to ask if it is actually useful to spit out ~4MB of raw data on the screen. That does not seem very useful or usable. An alternative could be to show a truncated version with the option to download the full data (as JSON or otherwise). What do users typically do with the raw transaction data?

> It seems prudent to keep [this](https://github.com/bitcoin-core/gui/issues/932) in mind during work on the implementation. Interesting one. QML might not have this problem, but we may also need to ask if it is actually useful to spit out ~4MB of raw data on the screen. That does not seem very useful or usable. An alternative could be to show a truncated version with the option to download the full data (as JSON or otherwise). What do users typically do with the raw transaction data?
hebasto commented 2026-03-24 09:08:23 +00:00 (Migrated from github.com)

It seems prudent to keep this in mind during work on the implementation.

Interesting one. QML might not have this problem, but we may also need to ask if it is actually useful to spit out ~4MB of raw data on the screen. That does not seem very useful or usable. An alternative could be to show a truncated version with the option to download the full data (as JSON or otherwise).

Right. My understanding is similar.

What do users typically do with the raw transaction data?

As input to other RPCs?

> > It seems prudent to keep [this](https://github.com/bitcoin-core/gui/issues/932) in mind during work on the implementation. > > Interesting one. QML might not have this problem, but we may also need to ask if it is actually useful to spit out ~4MB of raw data on the screen. That does not seem very useful or usable. An alternative could be to show a truncated version with the option to download the full data (as JSON or otherwise). Right. My understanding is similar. > What do users typically do with the raw transaction data? As input to other RPCs?
johnny9 commented 2026-05-11 16:25:10 +00:00 (Migrated from github.com)
https://github.com/bitcoin-core/gui-qml/pull/540
Sign in to join this conversation.
No description provided.