Skip to content

WIP: gRPC: Add gRPC interface to cardano-node with tests in cardano-testnet#6273

Open
carbolymer wants to merge 8 commits intomasterfrom
mgalazyn/feature/add-grpc-interface
Open

WIP: gRPC: Add gRPC interface to cardano-node with tests in cardano-testnet#6273
carbolymer wants to merge 8 commits intomasterfrom
mgalazyn/feature/add-grpc-interface

Conversation

@carbolymer
Copy link
Contributor

@carbolymer carbolymer commented Jul 4, 2025

Description

This PR adds an experimental gRPC endpoint to cardano-node. The gRPC endpoint implements UTXORPC schema. For now the following methods are supported:

The gRPC endpoint is disabled by default, can be enabled by CLI flag or by configuration option.

Support for enabling gRPC endpoint is added into cardano-testnet.

Things necessary to do before the merge:

  • Release cardano-cli to remove SRP
  • Release cardano-rpc to remove SRP

Checklist

  • Commit sequence broadly makes sense and commits have useful messages
  • New tests are added if needed and existing tests are updated. These may include:
    • golden tests
    • property tests
    • roundtrip tests
    • integration tests
      See Runnings tests for more details
  • Any changes are noted in the CHANGELOG.md for affected package
  • The version bounds in .cabal files are updated
  • CI passes. See note on CI. The following CI checks are required:
    • Code is linted with hlint. See .github/workflows/check-hlint.yml to get the hlint version
    • Code is formatted with stylish-haskell. See .github/workflows/stylish-haskell.yml to get the stylish-haskell version
    • Code builds on Linux, MacOS and Windows for ghc-9.6 and ghc-9.12
  • Self-reviewed the diff

Note on CI

If your PR is from a fork, the necessary CI jobs won't trigger automatically for security reasons.
You will need to get someone with write privileges. Please contact IOG node developers to do this
for you.

@carbolymer carbolymer self-assigned this Jul 4, 2025
@carbolymer carbolymer changed the title cardano-rpc | Add gRPC interface to cardano-node, add tests to cardano-testnet cardano-rpc | Add gRPC interface to cardano-node with tests in cardano-testnet Jul 4, 2025
@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch 2 times, most recently from 864cf20 to 12bae80 Compare July 10, 2025 15:37
@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch from 0004d02 to 2c89086 Compare July 23, 2025 14:20
@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch 3 times, most recently from aaab28c to eab2ed1 Compare July 25, 2025 16:57
@palas palas force-pushed the mgalazyn/feature/add-grpc-interface branch 4 times, most recently from 4d19d4c to 98d8073 Compare August 3, 2025 20:00
@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch from 12d7ab5 to 73c37e6 Compare September 4, 2025 16:45
@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch from 8cbf3f2 to 0ec9ea7 Compare October 2, 2025 12:29
@carbolymer carbolymer changed the title cardano-rpc | Add gRPC interface to cardano-node with tests in cardano-testnet gRPC: Add gRPC interface to cardano-node with tests in cardano-testnet Nov 13, 2025
@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch 2 times, most recently from 7c29f29 to ebf5f8b Compare November 17, 2025 08:33
@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch 2 times, most recently from a8564a9 to 5d772e5 Compare November 28, 2025 20:50
@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch from 5d772e5 to 450a849 Compare January 7, 2026 18:51
@carbolymer carbolymer changed the title gRPC: Add gRPC interface to cardano-node with tests in cardano-testnet WIP: gRPC: Add gRPC interface to cardano-node with tests in cardano-testnet Feb 20, 2026
@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch from eb845fe to ecc60aa Compare February 20, 2026 14:37
- name: Cache Cabal store
uses: actions/cache/save@v4
- name: Cache and install Cabal dependencies
# TODO pin this action version
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Suggested change
# TODO pin this action version


allow-newer:
, katip:Win32
, cardano-cli:cardano-api
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Suggested change
, cardano-cli:cardano-api

@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch 7 times, most recently from 86ec635 to 9984a35 Compare February 24, 2026 17:13
@carbolymer carbolymer requested a review from Copilot February 24, 2026 17:13
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds experimental gRPC (UTXORPC) support to cardano-node, wires it into cardano-testnet, and introduces integration tests to exercise Query/Submit over gRPC, along with build/CI updates to support the new dependency stack.

Changes:

  • Add gRPC runtime + tracing plumbing to cardano-node and configuration/CLI parsing for enabling it.
  • Add cardano-testnet flag/support for enabling node gRPC and add RPC integration tests.
  • Update Nix/Cabal/CI inputs to build cardano-rpc/proto-lens and gRPC dependencies across platforms.

Reviewed changes

Copilot reviewed 36 out of 37 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
nix/haskell.nix Nix tooling tweaks; add protobuf build tools and proto-lens override.
nix/cardanolib-py/default.nix Switch Python packaging to pyproject/setuptools build system.
flake.nix Add Windows overlay tweak for abseil-cpp pthreads dependency.
flake.lock Bump/pin flake inputs (haskell.nix, nixpkgs, HLS, etc.).
cardano-testnet/test/cardano-testnet-test/cardano-testnet-test.hs Register new RPC test groups.
cardano-testnet/test/cardano-testnet-test/Cardano/Testnet/Test/Rpc/Transaction.hs New gRPC SubmitTx integration test.
cardano-testnet/test/cardano-testnet-test/Cardano/Testnet/Test/Rpc/Query.hs New gRPC readParams/readUtxos integration test.
cardano-testnet/test/cardano-testnet-golden/files/golden/help/create-env.cli Update help output for renamed flag + new --enable-grpc.
cardano-testnet/test/cardano-testnet-golden/files/golden/help/cardano.cli Update help output for renamed flag + new --enable-grpc.
cardano-testnet/test/cardano-testnet-golden/files/golden/help.cli Update top-level help output for renamed flag + new --enable-grpc.
cardano-testnet/src/Testnet/Types.hs Add nodeRpcSocketPath helper.
cardano-testnet/src/Testnet/Start/Types.hs Add cardanoEnableRpc option; improve logging-format pretty printing.
cardano-testnet/src/Testnet/Start/Cardano.hs Pass --grpc-enable through to nodes when enabled.
cardano-testnet/src/Testnet/Runtime.hs Minor list concatenation cleanup for node args.
cardano-testnet/src/Testnet/Defaults.hs Refactor TraceOptions value; add commented guidance for prometheus.
cardano-testnet/src/Parsers/Cardano.hs CLI: rename logging-format flag, add --enable-grpc switch.
cardano-testnet/src/Cardano/Testnet.hs Re-export nodeRpcSocketPath.
cardano-testnet/changelog.d/20260220_120000_mgalazyn_add_grpc_interface.md Changelog entry for testnet gRPC enablement + tests.
cardano-testnet/cardano-testnet.cabal Add cardano-rpc deps; include new test modules.
cardano-submit-api/cardano-submit-api.cabal Bump cardano-api bound to 10.24.
cardano-node/test/Test/Cardano/Node/POM.hs Extend expected node config with RPC config field.
cardano-node/test/Test/Cardano/Node/FilePermissions.hs Minor import/namespace adjustments in tests.
cardano-node/src/Cardano/Tracing/Tracers.hs Add rpcTracer wiring to tracer set.
cardano-node/src/Cardano/Node/Types.hs Add AdjustFilePaths support for RPC config and File.
cardano-node/src/Cardano/Node/Tracing/Tracers/Rpc.hs New logging/metrics instances for RPC tracing.
cardano-node/src/Cardano/Node/Tracing/Tracers.hs Create/configure RPC tracer and attach into Tracers.
cardano-node/src/Cardano/Node/Tracing/Documentation.hs Include RPC tracer in generated tracing docs.
cardano-node/src/Cardano/Node/Tracing.hs Extend Tracers record with rpcTracer.
cardano-node/src/Cardano/Node/Run.hs Start RPC server alongside node; restructure config building.
cardano-node/src/Cardano/Node/Parsers.hs Add gRPC CLI parsing into PartialNodeConfiguration.
cardano-node/src/Cardano/Node/Configuration/POM.hs Add RPC config to node config and YAML parsing/merging.
cardano-node/cardano-node.cabal Add cardano-rpc dependency + include new tracer module.
cabal.project Add SRPs for unreleased cardano-rpc/cardano-cli and proto-lens; adjust bounds.
bench/tx-generator/tx-generator.cabal Bump cardano-api bound to 10.24.
bench/plutus-scripts-bench/plutus-scripts-bench.cabal Bump cardano-api and plutus bounds.
.github/workflows/haskell.yml CI: add GHC 9.10, update cabal, add gRPC deps + new cache action.
.github/ISSUE_TEMPLATE/config.yml Add “Cardano gRPC Issues” contact link.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

, resourcet
, rio
, regex-compat
, rio
Copy link

Copilot AI Feb 24, 2026

Choose a reason for hiding this comment

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

The build-depends list for the cardano-testnet-test suite includes rio twice. Duplicated dependencies make the cabal file noisier and can trigger cabal check warnings; please keep each dependency listed once.

Suggested change
, rio

Copilot uses AI. Check for mistakes.
Comment on lines 141 to 142
H.note_ $ "Enxure that there are 2 UTXOs in the address " <> show addrTxt1
utxosForAddress <- H.noteShowM . flip filterM (utxos ^. U5c.items) $ \utxo -> do
Copy link

Copilot AI Feb 24, 2026

Choose a reason for hiding this comment

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

Spelling: the note says "Enxure". Please correct to "Ensure" so test output/messages are professional and searchable.

Copilot uses AI. Check for mistakes.
@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch 3 times, most recently from 6aa34ba to 7b30930 Compare February 25, 2026 20:02
@carbolymer carbolymer force-pushed the mgalazyn/feature/add-grpc-interface branch from 7b30930 to 8e67434 Compare February 26, 2026 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

3 participants