From eb0393efb165841c7b0820ebcf9138878bb18fa3 Mon Sep 17 00:00:00 2001 From: incrypto32 Date: Thu, 2 Oct 2025 18:33:40 +0400 Subject: [PATCH 01/10] cargo: update workspace crates version to v0.41.0 --- Cargo.lock | 52 +++++++++++++++++++-------------------- Cargo.toml | 2 +- chain/ethereum/Cargo.toml | 2 +- 3 files changed, 28 insertions(+), 28 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index f1168906765..bc8539178fe 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1889,7 +1889,7 @@ dependencies = [ [[package]] name = "gnd" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "clap", @@ -1910,7 +1910,7 @@ dependencies = [ [[package]] name = "graph" -version = "0.36.0" +version = "0.41.0" dependencies = [ "Inflector", "anyhow", @@ -1994,7 +1994,7 @@ dependencies = [ [[package]] name = "graph-chain-common" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "heck 0.5.0", @@ -2004,7 +2004,7 @@ dependencies = [ [[package]] name = "graph-chain-ethereum" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "base64 0.22.1", @@ -2026,7 +2026,7 @@ dependencies = [ [[package]] name = "graph-chain-near" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "diesel", @@ -2042,7 +2042,7 @@ dependencies = [ [[package]] name = "graph-chain-substreams" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "base64 0.22.1", @@ -2060,7 +2060,7 @@ dependencies = [ [[package]] name = "graph-core" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "async-trait", @@ -2081,7 +2081,7 @@ dependencies = [ [[package]] name = "graph-graphql" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "async-recursion", @@ -2096,7 +2096,7 @@ dependencies = [ [[package]] name = "graph-node" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "clap", @@ -2130,7 +2130,7 @@ dependencies = [ [[package]] name = "graph-runtime-derive" -version = "0.36.0" +version = "0.41.0" dependencies = [ "heck 0.5.0", "proc-macro2", @@ -2140,7 +2140,7 @@ dependencies = [ [[package]] name = "graph-runtime-test" -version = "0.36.0" +version = "0.41.0" dependencies = [ "graph", "graph-chain-ethereum", @@ -2154,7 +2154,7 @@ dependencies = [ [[package]] name = "graph-runtime-wasm" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "async-trait", @@ -2173,7 +2173,7 @@ dependencies = [ [[package]] name = "graph-server-http" -version = "0.36.0" +version = "0.41.0" dependencies = [ "graph", "graph-core", @@ -2183,7 +2183,7 @@ dependencies = [ [[package]] name = "graph-server-index-node" -version = "0.36.0" +version = "0.41.0" dependencies = [ "blake3 1.8.2", "git-testament", @@ -2196,7 +2196,7 @@ dependencies = [ [[package]] name = "graph-server-json-rpc" -version = "0.36.0" +version = "0.41.0" dependencies = [ "graph", "jsonrpsee", @@ -2205,14 +2205,14 @@ dependencies = [ [[package]] name = "graph-server-metrics" -version = "0.36.0" +version = "0.41.0" dependencies = [ "graph", ] [[package]] name = "graph-store-postgres" -version = "0.36.0" +version = "0.41.0" dependencies = [ "Inflector", "anyhow", @@ -2248,7 +2248,7 @@ dependencies = [ [[package]] name = "graph-tests" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "assert-json-diff", @@ -2272,7 +2272,7 @@ dependencies = [ [[package]] name = "graph_derive" -version = "0.36.0" +version = "0.41.0" dependencies = [ "heck 0.5.0", "proc-macro-utils", @@ -2283,7 +2283,7 @@ dependencies = [ [[package]] name = "graphman" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "diesel", @@ -2297,7 +2297,7 @@ dependencies = [ [[package]] name = "graphman-server" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "async-graphql", @@ -2322,7 +2322,7 @@ dependencies = [ [[package]] name = "graphman-store" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", "chrono", @@ -5293,7 +5293,7 @@ dependencies = [ [[package]] name = "substreams-head-tracker" -version = "0.36.0" +version = "0.41.0" [[package]] name = "substreams-macro" @@ -5323,7 +5323,7 @@ dependencies = [ [[package]] name = "substreams-trigger-filter" -version = "0.36.0" +version = "0.41.0" dependencies = [ "hex", "prost", @@ -5471,7 +5471,7 @@ dependencies = [ [[package]] name = "test-store" -version = "0.36.0" +version = "0.41.0" dependencies = [ "diesel", "graph", @@ -6071,7 +6071,7 @@ dependencies = [ [[package]] name = "trigger-filters" -version = "0.36.0" +version = "0.41.0" dependencies = [ "anyhow", ] diff --git a/Cargo.toml b/Cargo.toml index 2620237e28e..9980f1bf0be 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -30,7 +30,7 @@ members = [ ] [workspace.package] -version = "0.36.0" +version = "0.41.0" edition = "2021" authors = ["The Graph core developers & contributors"] readme = "README.md" diff --git a/chain/ethereum/Cargo.toml b/chain/ethereum/Cargo.toml index ee350ea69a7..07348bf7a6b 100644 --- a/chain/ethereum/Cargo.toml +++ b/chain/ethereum/Cargo.toml @@ -22,7 +22,7 @@ graph-runtime-wasm = { path = "../../runtime/wasm" } graph-runtime-derive = { path = "../../runtime/derive" } [dev-dependencies] -base64 = "0" +base64 = "0.22" [build-dependencies] tonic-build = { workspace = true } From 3a92ab3d07838487dce5793b4805a4043fcab054 Mon Sep 17 00:00:00 2001 From: incrypto32 Date: Thu, 2 Oct 2025 18:33:54 +0400 Subject: [PATCH 02/10] Update NEWS.md --- NEWS.md | 238 +++++++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 220 insertions(+), 18 deletions(-) diff --git a/NEWS.md b/NEWS.md index 719d2f12e49..40f944ff1a7 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,36 +1,238 @@ # NEWS +## v0.41.0 + +### New Features + +- Added support for struct field access in declarative calls - enables accessing nested struct fields directly in declarative subgraph handlers (#6099) +- New standalone `gnd` (Graph Node Dev) crate - a graph-node binary optimized for local development with minimal setup required (#6167) +- Extended IPFS usage metrics and logging capabilities (#6058) +- Extended support for additional IPFS content path formats (#6058) + +### Improvements + +- Deferred IPFS manifest fetching when starting subgraphs - fixes issue where slow IPFS responses could block assignment event processing, preventing new subgraphs from being assigned (#6170) +- Added Content Identifier (CID) to IPFS retry logs for better debugging and tracking of IPFS operations (#6144) +- Runtime now uses interior mutability in `AscHeapCtx` for improved performance (#6053) +- Fixed handling of empty arrays in indexing status queries - prevents errors when querying deployments with empty array filters (#6143) +- Fixed case-insensitive array inputs in queries - array filter values are now properly case-normalized (#6075) +- Fixed panic when handling empty lists in `list_values` - resolves crashes with empty array filters (#6100) +- Enhanced logging for subgraph assignment processing with more detailed information (#6169) +- Added logging for `MAX_BLOCKING_THREADS` configuration setting (#6161) + + +## v0.40.1 + +### Improvements +- Enhanced IPFS logging to include Content Identifiers (CIDs) in operation names for better debugging + +## v0.40.0 +### Critical Bugfix +**GraphQL Empty Array Panic Fix** +Fixed GraphQL query panic with empty arrays: Resolved a critical bug where GraphQL queries using _in filters (like id_in, name_in, etc.) with empty arrays would cause the graph-node to panic with `index out of bounds: the len is 0 but the index is 0`(#6100) + +### New Features + +**IPFS File System Caching** +- IPFS files can now be cached to disk using the `GRAPH_IPFS_CACHE_LOCATION` environment variable - reduces IPFS requests after restarts and improves performance. Cache directory must be writable by graph-node and in a trusted location (#6031) + +### Improvements + +**Performance** +- Speed up appending changes to batch operations (#6025) +- Improved backoff strategy for offchain data sources - files not found are subject to exponential backoff, with configurable maximum backoff via `GRAPH_FDS_MAX_BACKOFF` (default: 600 seconds) (#6043) + +**GraphQL** +- Better error messages for OR operator usage with column filters (#6078) + +**graphman** +- Remove create flag from `graphman deploy` command (#6077) +- `graphman reassign` now shows clearer success messages (#6074) + +**Runtime** +- Update Wasmtime version for improved WebAssembly performance (#6050) + +### Bug Fixes + +- Fixed subgraph composition sync failures when entities have different ID types - resolves "UNION types bytea and text cannot be matched" error (#6080) +- Fixed database down migration issue (#6065) +- Fixed pruning status reporting accuracy - completion percentage now correctly reflects progress when copying non-final entities (#6062) + + +## v0.39.0 + +### Breaking Changes + +#### Database Schema Changes +- **Major schema migration**: The `subgraphs.subgraph_deployment` table has been split into two tables: ([#6003](https://github.com/graphprotocol/graph-node/pull/6003)) + - `subgraphs.head` - stores frequently changing metadata (block hash, block number, entity count, firehose cursor) + - `subgraphs.deployment` - stores less frequently changing data + + **Note**: This migration will run automatically but may take time on large databases; anything beyond a minute or two will most likely be due to long-running queries blocking the migration. While it is possible to apply this migration with rolling updates to all graph-node processes, it is recommended to shut down all graph-node processes first and them start them up again. + + **Note**: External processes accessing the `subgraph_deployment` table, such as dashboards, will not work after the migration. Queries that these tools run will need to be updated. Joining the `head` and `deployment` table on `id` will yield the same data that used to live in the `subgraph_deployment` table, though a few columns were also renamed. See [the documentation](https://github.com/graphprotocol/graph-node/blob/master/docs/implementation/metadata.md#subgraphshead) for details. + +#### Removed Features +- **Arweave blockchain support removed** - Arweave subgraphs are no longer supported (Arweave file data sources remain unaffected) ([#5951](https://github.com/graphprotocol/graph-node/pull/5951)) +- **`graphman drop` command removed** - To remove a deployment, run `graphman remove ` for each name the deployment has (see `graphman info`), then run `graphman unused record && graphman unused remove` ([#5974](https://github.com/graphprotocol/graph-node/pull/5974)) + +#### Behavior Changes +- **Failed subgraphs are now paused instead of unassigned** - This prevents unwanted side effects like canceling active copy operations ([#5971](https://github.com/graphprotocol/graph-node/pull/5971)) +- **Various store errors are now classified as deterministic** - May affect error handling in your monitoring ([#5943](https://github.com/graphprotocol/graph-node/pull/5943)) + +--- + +### New Features + +#### Enhanced Pruning Management +- **Pruning status tracking**: New database tables track pruning progress per deployment ([#5949](https://github.com/graphprotocol/graph-node/pull/5949)) +- **Pruning timeout protection**: Long-running prune operations can be killed and retried if they exceed `GRAPH_STORE_BATCH_TIMEOUT` ([#6002](https://github.com/graphprotocol/graph-node/pull/6002)) +- **Better pruning estimates**: Uses PostgreSQL statistics for more accurate predictions (requires PostgreSQL 17+ for full functionality) ([#6012](https://github.com/graphprotocol/graph-node/pull/6012)) +- **New graphman commands**: ([#5949](https://github.com/graphprotocol/graph-node/pull/5949)) + - `graphman prune status` - View status of prune operations + - `graphman prune run` - Manually trigger pruning + - `graphman prune set` - Configure pruning parameters + +#### Block Ingestion Tools +- **`graphman chain ingest `** - Manually ingest specific blocks into the block cache ([#5945](https://github.com/graphprotocol/graph-node/pull/5945)) + +#### IPFS Improvements +- **Configurable retry limits**: Set max retry attempts with `GRAPH_IPFS_MAX_ATTEMPTS` (default: 100,000) ([#5998](https://github.com/graphprotocol/graph-node/pull/5998)) +- **Configurable timeouts**: ([e1d9876](https://github.com/graphprotocol/graph-node/commit/e1d98766724adf9089f52006df0152090b27395d)) + - `GRAPH_IPFS_REQUEST_TIMEOUT` - Request timeout (default: 60s release, 1s debug) + - Max retry delay increased to 60 seconds ([#5995](https://github.com/graphprotocol/graph-node/pull/5995)) + +--- + +### Improvements + +#### Error Handling +- Store errors now properly classified as deterministic vs non-deterministic ([#5943](https://github.com/graphprotocol/graph-node/pull/5943)) +- Pruning errors no longer cause subgraph failure - they're logged and retried later ([#5972](https://github.com/graphprotocol/graph-node/pull/5972)) +- Better error messages for: + - Source subgraph manifest resolution ([#5950](https://github.com/graphprotocol/graph-node/pull/5950)) + - Store write failures + - Unique constraint violations ([#5943](https://github.com/graphprotocol/graph-node/pull/5943)) + +#### Performance +- Optimized GraphQL result caching ([#6006](https://github.com/graphprotocol/graph-node/pull/6006)) +- Reduced code duplication in subgraph processing ([#5952](https://github.com/graphprotocol/graph-node/pull/5952)) + +#### Operational +- Pruning status history limited to last 5 runs per deployment (configurable via `GRAPH_STORE_HISTORY_KEEP_STATUS`) ([#5949](https://github.com/graphprotocol/graph-node/pull/5949)) +- Deployments being pruned are properly handled during concurrent operations +- Subgraph reassignment now shows the current node assignment ([be6c9402](https://github.com/graphprotocol/graph-node/commit/be6c9402dbd2eb14898fe948a5a7bfd633f1c42e)) +- CLI accepts bare numeric deployment IDs in all `graphman` commands ([#5954](https://github.com/graphprotocol/graph-node/pull/5954)) +- Removed Ganache-specific chain handling - cleans up obsolete code ([#5975](https://github.com/graphprotocol/graph-node/pull/5975)) + +--- + +### Bug Fixes + +- Fixed VID sequence naming to comply with PostgreSQL 63-character limit ([a322a634](https://github.com/graphprotocol/graph-node/commit/a322a63455421a94429d3ca9f7543bfca6b2086d)) +- Fixed pruning of tables with VID sequences using CASCADE drops ([#5968](https://github.com/graphprotocol/graph-node/pull/5968)) +- PostgreSQL unique constraint violations now lead to deterministic subgraph failures ([#5943](https://github.com/graphprotocol/graph-node/pull/5943)) +- Fixed various edge cases in error classification ([#5943](https://github.com/graphprotocol/graph-node/pull/5943)) +- Fixed numerical precision issues with large VID values ([#5970](https://github.com/graphprotocol/graph-node/pull/5970)) + +--- + +### Configuration Changes + +#### New Environment Variables +- `GRAPH_IPFS_MAX_ATTEMPTS` - Maximum IPFS retry attempts (default: 100,000) +- `GRAPH_IPFS_REQUEST_TIMEOUT` - IPFS request timeout in seconds +- `GRAPH_STORE_BATCH_TIMEOUT` - Timeout for batch operations like pruning +- `GRAPH_STORE_HISTORY_KEEP_STATUS` - Number of pruning status records to keep (default: 5) +- `GRAPH_STORE_PRUNE_DISABLE_RANGE_BOUND_ESTIMATION` - Disable new pruning estimation method (temporary compatibility flag) +- `GRAPH_STORE_ERRORS_ARE_NON_DETERMINISTIC` - Revert to treating all errors as non-deterministic (temporary compatibility flag) + +--- + ## v0.38.0 -### What's new +### Breaking changes + +- **Removal of GraphQL subscriptions** – the WebSocket server and every `Subscription`‑related code path were deleted. Applications that need live updates must switch to polling or an external event system. ([#5836](https://github.com/graphprotocol/graph-node/pull/5836)) +- **Removal of Cosmos support** – all Cosmos chain and runtime code was removed. ([#5833](https://github.com/graphprotocol/graph-node/pull/5833)) +- **`GRAPH_STORE_LAST_ROLLUP_FROM_POI` deleted** – this setting is no longer needed and will be ignored. ([#5936](https://github.com/graphprotocol/graph-node/pull/5936)) +- **No dependency on `pg_stat_statements`** – Graph Node no longer executes `pg_stat_statements_reset()` after running database migrations and therefore is agnostic to whether that extension is installed or not ([#5926](https://github.com/graphprotocol/graph-node/pull/5926)) + +--- + +### New features & improvements -- A new `deployment_synced` metric is added [(#5816)](https://github.com/graphprotocol/graph-node/pull/5816) - that indicates whether a deployment has reached the chain head since it was deployed. +1. **Faster grafting and copying** + - A single graft/copy operation can now copy multiple tables in parallel. The number of parallel operations per graft/copy can be configured by setting `GRAPH_STORE_BATCH_WORKERS`, which defaults to 1. The total number of parallel operations is also limited by the `fdw_pool_size` which defaults to 5 and can be set in `graph-node.toml` + - A large number of parallel grafts/copies might get blocked by the size of tokio's blocking thread pool. To avoid that block, the size of that pool can now be configured with `GRAPH_MAX_BLOCKING_THREADS`. It defaults to 512 (tokio's default) but setting this to a large number like 2048 should be safe. ([#5948](https://github.com/graphprotocol/graph-node/pull/5948)) - **Possible values for the metric:** - - `0` - means that the deployment is not synced; - - `1` - means that the deployment is synced; +3. **Better control of graft/copy batches** + - To avoid table bloat, especially in `subgraphs.subgraph_deployment`, graft/copy splits the work up into smaller batches which should take `GRAPH_STORE_BATCH_TARGET_DURATION` each. Sometimes, the estimation for how long a batch will take goes horribly wrong. To guard against that, the new setting `GRAPH_STORE_BATCH_TIMEOUT` sets a timeout, which is unlimited by default. When set, batches that take longer than this are aborted and restarted with a much smaller size. ([3c183731](https://github.com/graphprotocol/graph-node/commit/3c18373109d16dadab2d9c52fdd5f81cf3de6dbe)) + - The number of rows that are fetched from the source shard for cross-shard grafts/copies in a single operation can be controlled through `GRAPH_STORE_FDW_FETCH_SIZE`. Its default has been lowered from 10 000 to 1 000, as larger sizes have shown to not be effective and actually cause the graft/copy to slow down in some cases ([#5924](https://github.com/graphprotocol/graph-node/pull/5924)) + - Deployments being copied are excluded from pruning. ([#5893](https://github.com/graphprotocol/graph-node/pull/5893)) + - Failed deployments can now be copied. ([#5893](https://github.com/graphprotocol/graph-node/pull/5893)) + +5. **Composable subgraphs** + - Mutable entities are no longer allowed in composed subgraphs. ([#5909](https://github.com/graphprotocol/graph-node/pull/5909)) + - Graft chains are validated for incompatible spec versions. ([#5911](https://github.com/graphprotocol/graph-node/pull/5911)) + - New env‑var `GRAPH_ETHEREUM_FORCE_RPC_FOR_BLOCK_PTRS` prefers RPC over Firehose. ([#5876](https://github.com/graphprotocol/graph-node/pull/5876)) + +6. **Aggregations** + - Aggregate entities can be ordered by any field, not only `timestamp` / `id`. ([#5829](https://github.com/graphprotocol/graph-node/pull/5829)) + +7. **Start‑up hardening** + - Database setup now uses a single lock on the primary to prevent race conditions when multiple nodes start together. ([#5926](https://github.com/graphprotocol/graph-node/pull/5926)) + - Shards with pool size 0 are filtered out at boot. ([#5926](https://github.com/graphprotocol/graph-node/pull/5926)) + +8. **Graphman quality‑of‑life** + - Load management disabled while running `graphman` commands. ([c765ce7a](https://github.com/graphprotocol/graph-node/commit/c765ce7a09dd93249a8541503f7c55f0a686dfc6)) + - `graphman copy create` errors include the source deployment ID. ([701f77d2](https://github.com/graphprotocol/graph-node/commit/701f77d2d39decfef2ec2d91aa5df0cf5abb7c69)) + +9. **Combined views of sharded tables in the primary** + - The primary now has a namespace `sharded` that contains views that combines sharded tables such as `subgraph_deployment` into one view across shards. ([#5820](https://github.com/graphprotocol/graph-node/pull/5820)) +--- + +### Fixes (selected) + +- Aggregate indexes were sometimes created twice when postponed. ([4be64c16](https://github.com/graphprotocol/graph-node/commit/4be64c16f575c9da424ac730e26a497f829683ee)) +- Duplicate `remove` operations in a write batch no longer cause failures. ([17360f56](https://github.com/graphprotocol/graph-node/commit/17360f56c7657e49d2b5da2fafa5d8d633d556f7)) +- Incorrect hashing when grafting from subgraphs with `specVersion` < 0.0.6 fixed. ([#5917](https://github.com/graphprotocol/graph-node/pull/5917)) +- Firehose TLS configuration corrected. ([36ad6a24](https://github.com/graphprotocol/graph-node/commit/36ad6a24a2456fa5504f14b20dd59c0cffae2b40)) +- Numerous small fixes in estimation of graft/copy batch size, namespace mapping, copy status display, and error messages. + +--- - _If a deployment is not running, the metric reports no value for that deployment._ ## v0.37.0 ### What's new -- A new `deployment_status` metric is added [(#5720)](https://github.com/graphprotocol/graph-node/pull/5720) with the - following behavior: - - Once graph-node has figured out that it should index a deployment, `deployment_status` is set to `1` _(starting)_; - - When the block stream is created and blocks are ready to be processed, `deployment_status` is set to `2` _( - running)_; - - When a deployment is unassigned, `deployment_status` is set to `3` _(stopped)_; - - If a temporary or permanent failure occurs, `deployment_status` is set to `4` _(failed)_; - - If indexing manages to recover from a temporary failure, the `deployment_status` is set back to `2` _( - running)_; +- **Composable Subgraphs**: A feature that enables subgraphs to use other subgraphs as data sources. This introduces modularity in subgraph development by allowing developers to create source subgraphs that can be referenced by dependent subgraphs. The feature supports up to 5 subgraph datasources. + + **Note for Indexers**: To deploy a dependent subgraph, the source subgraph(s) must already be deployed and available on your infrastructure. + +- **YAML Parsing in Subgraph Mappings**: Added YAML parsing support to subgraph mappings through new host functions, enabling subgraphs to parse YAML documents (including subgraph manifests) directly in their mappings + +### Improvements + +- Added new deployment metrics: + - `deployment_status`: Tracks deployment lifecycle (starting, running, stopped, failed) + - `deployment_synced`: Indicates if deployment has reached chain head +- Optimized copy, graft, and prune operations for unevenly distributed rows +- Improved error handling for substreams-powered subgraphs +- Enhanced error handling when restarting paused subgraphs +- Improved Firehose block request handling with retries and block cache + +- Fixed issue with metrics not reporting updated values + +### Graphman + +- Added unassign/reassign commands to GraphQL API ### Breaking changes -- The `deployment_failed` metric is removed and the failures are reported by the new `deployment_status` - metric. [(#5720)](https://github.com/graphprotocol/graph-node/pull/5720) +- The `deployment_failed` metric has been removed in favor of the new `deployment_status` metric + ## v0.36.0 From b8bd318dd826bb1aa20da1a735bdffba74b4c6a7 Mon Sep 17 00:00:00 2001 From: incrypto32 Date: Thu, 2 Oct 2025 18:34:26 +0400 Subject: [PATCH 03/10] .github: use arm runner for building linux arm binaries for gnd --- .github/workflows/gnd-binary-build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/gnd-binary-build.yml b/.github/workflows/gnd-binary-build.yml index 753388733d2..33319924e74 100644 --- a/.github/workflows/gnd-binary-build.yml +++ b/.github/workflows/gnd-binary-build.yml @@ -15,7 +15,7 @@ jobs: runner: ubuntu-22.04 asset_name: gnd-linux-x86_64 - target: aarch64-unknown-linux-gnu - runner: ubuntu-22.04 + runner: ubuntu-22.04-arm asset_name: gnd-linux-aarch64 - target: x86_64-apple-darwin runner: macos-13 From 9b61e60caba744fc6fb3d267c25cf4256abaf28a Mon Sep 17 00:00:00 2001 From: Krishnanand V P <44740264+incrypto32@users.noreply.github.com> Date: Mon, 20 Oct 2025 22:30:02 +0530 Subject: [PATCH 04/10] chain/ethereum: Fix POI inconsistencies in receipt handling (#6200) --- chain/ethereum/src/ethereum_adapter.rs | 22 +++++++++++++++++++--- chain/ethereum/src/trigger.rs | 25 ++++++++++++++++++++++--- 2 files changed, 41 insertions(+), 6 deletions(-) diff --git a/chain/ethereum/src/ethereum_adapter.rs b/chain/ethereum/src/ethereum_adapter.rs index 7c4d2d38f73..3ca046f359b 100644 --- a/chain/ethereum/src/ethereum_adapter.rs +++ b/chain/ethereum/src/ethereum_adapter.rs @@ -58,7 +58,7 @@ use std::time::Instant; use crate::adapter::EthereumRpcError; use crate::adapter::ProviderStatus; use crate::chain::BlockFinality; -use crate::trigger::LogRef; +use crate::trigger::{LogPosition, LogRef}; use crate::Chain; use crate::NodeCapabilities; use crate::TriggerFilter; @@ -1978,8 +1978,24 @@ pub(crate) fn parse_log_triggers( .transaction_receipts .iter() .flat_map(move |receipt| { - receipt.logs.iter().enumerate().map(move |(index, _)| { - EthereumTrigger::Log(LogRef::LogPosition(index, receipt.cheap_clone())) + receipt.logs.iter().enumerate().map(move |(index, log)| { + let requires_transaction_receipt = log + .topics + .first() + .map(|signature| { + log_filter.requires_transaction_receipt( + signature, + Some(&log.address), + &log.topics, + ) + }) + .unwrap_or(false); + + EthereumTrigger::Log(LogRef::LogPosition(LogPosition { + index, + receipt: receipt.cheap_clone(), + requires_transaction_receipt, + })) }) }) .collect() diff --git a/chain/ethereum/src/trigger.rs b/chain/ethereum/src/trigger.rs index c87a0211ae9..e479004778d 100644 --- a/chain/ethereum/src/trigger.rs +++ b/chain/ethereum/src/trigger.rs @@ -222,24 +222,43 @@ impl ToAscPtr for MappingTrigger { } } +#[derive(Clone, Debug)] +pub struct LogPosition { + pub index: usize, + pub receipt: Arc, + pub requires_transaction_receipt: bool, +} + #[derive(Clone, Debug)] pub enum LogRef { FullLog(Arc, Option>), - LogPosition(usize, Arc), + LogPosition(LogPosition), } impl LogRef { pub fn log(&self) -> &Log { match self { LogRef::FullLog(log, _) => log.as_ref(), - LogRef::LogPosition(index, receipt) => receipt.logs.get(*index).unwrap(), + LogRef::LogPosition(pos) => pos.receipt.logs.get(pos.index).unwrap(), } } + /// Returns the transaction receipt if it's available and required. + /// + /// For `FullLog` variants, returns the receipt if present. + /// For `LogPosition` variants, only returns the receipt if the + /// `requires_transaction_receipt` flag is true, otherwise returns None + /// even though the receipt is stored internally. pub fn receipt(&self) -> Option<&Arc> { match self { LogRef::FullLog(_, receipt) => receipt.as_ref(), - LogRef::LogPosition(_, receipt) => Some(receipt), + LogRef::LogPosition(pos) => { + if pos.requires_transaction_receipt { + Some(&pos.receipt) + } else { + None + } + } } } From 329b5f06e73c4270d28cea6d2560eefd0f895d99 Mon Sep 17 00:00:00 2001 From: incrypto32 Date: Tue, 20 Jan 2026 23:21:55 +0400 Subject: [PATCH 05/10] log alloy stuff --- Cargo.lock | 1763 +++++++++++++++++++++++- chain/ethereum/Cargo.toml | 4 + chain/ethereum/src/ethereum_adapter.rs | 63 +- 3 files changed, 1771 insertions(+), 59 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index bc8539178fe..2b59a9c4347 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -51,6 +51,611 @@ version = "0.2.21" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "683d7910e743518b0e34f1186f92494becacb047c7b6bf616c96772180fef923" +[[package]] +name = "alloy" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e502b004e05578e537ce0284843ba3dfaf6a0d5c530f5c20454411aded561289" +dependencies = [ + "alloy-consensus", + "alloy-contract", + "alloy-core", + "alloy-eips", + "alloy-genesis", + "alloy-network", + "alloy-provider", + "alloy-rpc-client", + "alloy-rpc-types", + "alloy-serde", + "alloy-signer", + "alloy-signer-local", + "alloy-transport", + "alloy-transport-http", + "alloy-trie", +] + +[[package]] +name = "alloy-chains" +version = "0.2.28" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3842d8c52fcd3378039f4703dba392dca8b546b1c8ed6183048f8dab95b2be78" +dependencies = [ + "alloy-primitives", + "num_enum", + "strum 0.27.2", +] + +[[package]] +name = "alloy-consensus" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c3a590d13de3944675987394715f37537b50b856e3b23a0e66e97d963edbf38" +dependencies = [ + "alloy-eips", + "alloy-primitives", + "alloy-rlp", + "alloy-serde", + "alloy-trie", + "alloy-tx-macros", + "auto_impl", + "borsh", + "c-kzg", + "derive_more 2.0.1", + "either", + "k256", + "once_cell", + "rand 0.8.5", + "secp256k1 0.30.0", + "serde", + "serde_json", + "serde_with", + "thiserror 2.0.16", +] + +[[package]] +name = "alloy-consensus-any" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f28f769d5ea999f0d8a105e434f483456a15b4e1fcb08edbbbe1650a497ff6d" +dependencies = [ + "alloy-consensus", + "alloy-eips", + "alloy-primitives", + "alloy-rlp", + "alloy-serde", + "serde", +] + +[[package]] +name = "alloy-contract" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "990fa65cd132a99d3c3795a82b9f93ec82b81c7de3bab0bf26ca5c73286f7186" +dependencies = [ + "alloy-consensus", + "alloy-dyn-abi", + "alloy-json-abi", + "alloy-network", + "alloy-network-primitives", + "alloy-primitives", + "alloy-provider", + "alloy-rpc-types-eth", + "alloy-sol-types", + "alloy-transport", + "futures 0.3.31", + "futures-util", + "serde_json", + "thiserror 2.0.16", +] + +[[package]] +name = "alloy-core" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9d4087016b0896051dd3d03e0bedda2f4d4d1689af8addc8450288c63a9e5f68" +dependencies = [ + "alloy-dyn-abi", + "alloy-json-abi", + "alloy-primitives", + "alloy-rlp", + "alloy-sol-types", +] + +[[package]] +name = "alloy-dyn-abi" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "369f5707b958927176265e8a58627fc6195e5dfa5c55689396e68b241b3a72e6" +dependencies = [ + "alloy-json-abi", + "alloy-primitives", + "alloy-sol-type-parser", + "alloy-sol-types", + "itoa", + "serde", + "serde_json", + "winnow 0.7.13", +] + +[[package]] +name = "alloy-eip2124" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "741bdd7499908b3aa0b159bba11e71c8cddd009a2c2eb7a06e825f1ec87900a5" +dependencies = [ + "alloy-primitives", + "alloy-rlp", + "crc", + "serde", + "thiserror 2.0.16", +] + +[[package]] +name = "alloy-eip2930" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9441120fa82df73e8959ae0e4ab8ade03de2aaae61be313fbf5746277847ce25" +dependencies = [ + "alloy-primitives", + "alloy-rlp", + "borsh", + "serde", +] + +[[package]] +name = "alloy-eip7702" +version = "0.6.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2919c5a56a1007492da313e7a3b6d45ef5edc5d33416fdec63c0d7a2702a0d20" +dependencies = [ + "alloy-primitives", + "alloy-rlp", + "borsh", + "serde", + "thiserror 2.0.16", +] + +[[package]] +name = "alloy-eips" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09535cbc646b0e0c6fcc12b7597eaed12cf86dff4c4fba9507a61e71b94f30eb" +dependencies = [ + "alloy-eip2124", + "alloy-eip2930", + "alloy-eip7702", + "alloy-primitives", + "alloy-rlp", + "alloy-serde", + "auto_impl", + "borsh", + "c-kzg", + "derive_more 2.0.1", + "either", + "serde", + "serde_with", + "sha2", + "thiserror 2.0.16", +] + +[[package]] +name = "alloy-genesis" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1005520ccf89fa3d755e46c1d992a9e795466c2e7921be2145ef1f749c5727de" +dependencies = [ + "alloy-eips", + "alloy-primitives", + "alloy-serde", + "alloy-trie", + "borsh", + "serde", + "serde_with", +] + +[[package]] +name = "alloy-json-abi" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "84e3cf01219c966f95a460c95f1d4c30e12f6c18150c21a30b768af2a2a29142" +dependencies = [ + "alloy-primitives", + "alloy-sol-type-parser", + "serde", + "serde_json", +] + +[[package]] +name = "alloy-json-rpc" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b626409c98ba43aaaa558361bca21440c88fd30df7542c7484b9c7a1489cdb" +dependencies = [ + "alloy-primitives", + "alloy-sol-types", + "http 1.3.1", + "serde", + "serde_json", + "thiserror 2.0.16", + "tracing", +] + +[[package]] +name = "alloy-network" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "89924fdcfeee0e0fa42b1f10af42f92802b5d16be614a70897382565663bf7cf" +dependencies = [ + "alloy-consensus", + "alloy-consensus-any", + "alloy-eips", + "alloy-json-rpc", + "alloy-network-primitives", + "alloy-primitives", + "alloy-rpc-types-any", + "alloy-rpc-types-eth", + "alloy-serde", + "alloy-signer", + "alloy-sol-types", + "async-trait", + "auto_impl", + "derive_more 2.0.1", + "futures-utils-wasm", + "serde", + "serde_json", + "thiserror 2.0.16", +] + +[[package]] +name = "alloy-network-primitives" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f0dbe56ff50065713ff8635d8712a0895db3ad7f209db9793ad8fcb6b1734aa" +dependencies = [ + "alloy-consensus", + "alloy-eips", + "alloy-primitives", + "alloy-serde", + "serde", +] + +[[package]] +name = "alloy-primitives" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6a0fb18dd5fb43ec5f0f6a20be1ce0287c79825827de5744afaa6c957737c33" +dependencies = [ + "alloy-rlp", + "bytes", + "cfg-if 1.0.0", + "const-hex", + "derive_more 2.0.1", + "foldhash 0.2.0", + "hashbrown 0.16.1", + "indexmap 2.11.4", + "itoa", + "k256", + "keccak-asm", + "paste", + "proptest", + "rand 0.9.2", + "rapidhash", + "ruint", + "rustc-hash 2.1.1", + "serde", + "sha3", + "tiny-keccak 2.0.2", +] + +[[package]] +name = "alloy-provider" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b56f7a77513308a21a2ba0e9d57785a9d9d2d609e77f4e71a78a1192b83ff2d" +dependencies = [ + "alloy-chains", + "alloy-consensus", + "alloy-eips", + "alloy-json-rpc", + "alloy-network", + "alloy-network-primitives", + "alloy-primitives", + "alloy-rpc-client", + "alloy-rpc-types-eth", + "alloy-signer", + "alloy-sol-types", + "alloy-transport", + "alloy-transport-http", + "async-stream", + "async-trait", + "auto_impl", + "dashmap", + "either", + "futures 0.3.31", + "futures-utils-wasm", + "lru", + "parking_lot", + "pin-project", + "reqwest", + "serde", + "serde_json", + "thiserror 2.0.16", + "tokio", + "tracing", + "url", + "wasmtimer", +] + +[[package]] +name = "alloy-rlp" +version = "0.3.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f70d83b765fdc080dbcd4f4db70d8d23fe4761f2f02ebfa9146b833900634b4" +dependencies = [ + "alloy-rlp-derive", + "arrayvec 0.7.4", + "bytes", +] + +[[package]] +name = "alloy-rlp-derive" +version = "0.3.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "64b728d511962dda67c1bc7ea7c03736ec275ed2cf4c35d9585298ac9ccf3b73" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.106", +] + +[[package]] +name = "alloy-rpc-client" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff01723afc25ec4c5b04de399155bef7b6a96dfde2475492b1b7b4e7a4f46445" +dependencies = [ + "alloy-json-rpc", + "alloy-primitives", + "alloy-transport", + "alloy-transport-http", + "futures 0.3.31", + "pin-project", + "reqwest", + "serde", + "serde_json", + "tokio", + "tokio-stream", + "tower 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)", + "tracing", + "url", + "wasmtimer", +] + +[[package]] +name = "alloy-rpc-types" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f91bf006bb06b7d812591b6ac33395cb92f46c6a65cda11ee30b348338214f0f" +dependencies = [ + "alloy-primitives", + "alloy-rpc-types-eth", + "alloy-serde", + "serde", +] + +[[package]] +name = "alloy-rpc-types-any" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "212ca1c1dab27f531d3858f8b1a2d6bfb2da664be0c1083971078eb7b71abe4b" +dependencies = [ + "alloy-consensus-any", + "alloy-rpc-types-eth", + "alloy-serde", +] + +[[package]] +name = "alloy-rpc-types-eth" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5715d0bf7efbd360873518bd9f6595762136b5327a9b759a8c42ccd9b5e44945" +dependencies = [ + "alloy-consensus", + "alloy-consensus-any", + "alloy-eips", + "alloy-network-primitives", + "alloy-primitives", + "alloy-rlp", + "alloy-serde", + "alloy-sol-types", + "itertools 0.14.0", + "serde", + "serde_json", + "serde_with", + "thiserror 2.0.16", +] + +[[package]] +name = "alloy-serde" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ed8531cae8d21ee1c6571d0995f8c9f0652a6ef6452fde369283edea6ab7138" +dependencies = [ + "alloy-primitives", + "serde", + "serde_json", +] + +[[package]] +name = "alloy-signer" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fb10ccd49d0248df51063fce6b716f68a315dd912d55b32178c883fd48b4021d" +dependencies = [ + "alloy-primitives", + "async-trait", + "auto_impl", + "either", + "elliptic-curve", + "k256", + "thiserror 2.0.16", +] + +[[package]] +name = "alloy-signer-local" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4d992d44e6c414ece580294abbadb50e74cfd4eaa69787350a4dfd4b20eaa1b" +dependencies = [ + "alloy-consensus", + "alloy-network", + "alloy-primitives", + "alloy-signer", + "async-trait", + "k256", + "rand 0.8.5", + "thiserror 2.0.16", +] + +[[package]] +name = "alloy-sol-macro" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09eb18ce0df92b4277291bbaa0ed70545d78b02948df756bbd3d6214bf39a218" +dependencies = [ + "alloy-sol-macro-expander", + "alloy-sol-macro-input", + "proc-macro-error2", + "proc-macro2", + "quote", + "syn 2.0.106", +] + +[[package]] +name = "alloy-sol-macro-expander" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95d9fa2daf21f59aa546d549943f10b5cce1ae59986774019fbedae834ffe01b" +dependencies = [ + "alloy-json-abi", + "alloy-sol-macro-input", + "const-hex", + "heck 0.5.0", + "indexmap 2.11.4", + "proc-macro-error2", + "proc-macro2", + "quote", + "syn 2.0.106", + "syn-solidity", + "tiny-keccak 2.0.2", +] + +[[package]] +name = "alloy-sol-macro-input" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9396007fe69c26ee118a19f4dee1f5d1d6be186ea75b3881adf16d87f8444686" +dependencies = [ + "alloy-json-abi", + "const-hex", + "dunce", + "heck 0.5.0", + "macro-string", + "proc-macro2", + "quote", + "serde_json", + "syn 2.0.106", + "syn-solidity", +] + +[[package]] +name = "alloy-sol-type-parser" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af67a0b0dcebe14244fc92002cd8d96ecbf65db4639d479f5fcd5805755a4c27" +dependencies = [ + "serde", + "winnow 0.7.13", +] + +[[package]] +name = "alloy-sol-types" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09aeea64f09a7483bdcd4193634c7e5cf9fd7775ee767585270cd8ce2d69dc95" +dependencies = [ + "alloy-json-abi", + "alloy-primitives", + "alloy-sol-macro", + "serde", +] + +[[package]] +name = "alloy-transport" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f50a9516736d22dd834cc2240e5bf264f338667cc1d9e514b55ec5a78b987ca" +dependencies = [ + "alloy-json-rpc", + "auto_impl", + "base64 0.22.1", + "derive_more 2.0.1", + "futures 0.3.31", + "futures-utils-wasm", + "parking_lot", + "serde", + "serde_json", + "thiserror 2.0.16", + "tokio", + "tower 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)", + "tracing", + "url", + "wasmtimer", +] + +[[package]] +name = "alloy-transport-http" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0a18b541a6197cf9a084481498a766fdf32fefda0c35ea6096df7d511025e9f1" +dependencies = [ + "alloy-json-rpc", + "alloy-transport", + "reqwest", + "serde_json", + "tower 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)", + "tracing", + "url", +] + +[[package]] +name = "alloy-trie" +version = "0.9.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "428aa0f0e0658ff091f8f667c406e034b431cb10abd39de4f507520968acc499" +dependencies = [ + "alloy-primitives", + "alloy-rlp", + "arrayvec 0.7.4", + "derive_more 2.0.1", + "nybbles", + "serde", + "smallvec", + "tracing", +] + +[[package]] +name = "alloy-tx-macros" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2289a842d02fe63f8c466db964168bb2c7a9fdfb7b24816dbb17d45520575fb" +dependencies = [ + "darling 0.21.3", + "proc-macro2", + "quote", + "syn 2.0.106", +] + [[package]] name = "android_system_properties" version = "0.1.5" @@ -127,6 +732,195 @@ version = "1.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "69f7f8c3906b62b754cd5326047894316021dcfe5a194c8ea52bdd94934a3457" +[[package]] +name = "ark-ff" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b3235cc41ee7a12aaaf2c575a2ad7b46713a8a50bda2fc3b003a04845c05dd6" +dependencies = [ + "ark-ff-asm 0.3.0", + "ark-ff-macros 0.3.0", + "ark-serialize 0.3.0", + "ark-std 0.3.0", + "derivative", + "num-bigint 0.4.6", + "num-traits", + "paste", + "rustc_version 0.3.3", + "zeroize", +] + +[[package]] +name = "ark-ff" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec847af850f44ad29048935519032c33da8aa03340876d351dfab5660d2966ba" +dependencies = [ + "ark-ff-asm 0.4.2", + "ark-ff-macros 0.4.2", + "ark-serialize 0.4.2", + "ark-std 0.4.0", + "derivative", + "digest 0.10.7", + "itertools 0.10.5", + "num-bigint 0.4.6", + "num-traits", + "paste", + "rustc_version 0.4.0", + "zeroize", +] + +[[package]] +name = "ark-ff" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a177aba0ed1e0fbb62aa9f6d0502e9b46dad8c2eab04c14258a1212d2557ea70" +dependencies = [ + "ark-ff-asm 0.5.0", + "ark-ff-macros 0.5.0", + "ark-serialize 0.5.0", + "ark-std 0.5.0", + "arrayvec 0.7.4", + "digest 0.10.7", + "educe", + "itertools 0.13.0", + "num-bigint 0.4.6", + "num-traits", + "paste", + "zeroize", +] + +[[package]] +name = "ark-ff-asm" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db02d390bf6643fb404d3d22d31aee1c4bc4459600aef9113833d17e786c6e44" +dependencies = [ + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-asm" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ed4aa4fe255d0bc6d79373f7e31d2ea147bcf486cba1be5ba7ea85abdb92348" +dependencies = [ + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-asm" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "62945a2f7e6de02a31fe400aa489f0e0f5b2502e69f95f853adb82a96c7a6b60" +dependencies = [ + "quote", + "syn 2.0.106", +] + +[[package]] +name = "ark-ff-macros" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db2fd794a08ccb318058009eefdf15bcaaaaf6f8161eb3345f907222bac38b20" +dependencies = [ + "num-bigint 0.4.6", + "num-traits", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-macros" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565" +dependencies = [ + "num-bigint 0.4.6", + "num-traits", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-macros" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09be120733ee33f7693ceaa202ca41accd5653b779563608f1234f78ae07c4b3" +dependencies = [ + "num-bigint 0.4.6", + "num-traits", + "proc-macro2", + "quote", + "syn 2.0.106", +] + +[[package]] +name = "ark-serialize" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d6c2b318ee6e10f8c2853e73a83adc0ccb88995aa978d8a3408d492ab2ee671" +dependencies = [ + "ark-std 0.3.0", + "digest 0.9.0", +] + +[[package]] +name = "ark-serialize" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "adb7b85a02b83d2f22f89bd5cac66c9c89474240cb6207cb1efc16d098e822a5" +dependencies = [ + "ark-std 0.4.0", + "digest 0.10.7", + "num-bigint 0.4.6", +] + +[[package]] +name = "ark-serialize" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f4d068aaf107ebcd7dfb52bc748f8030e0fc930ac8e360146ca54c1203088f7" +dependencies = [ + "ark-std 0.5.0", + "arrayvec 0.7.4", + "digest 0.10.7", + "num-bigint 0.4.6", +] + +[[package]] +name = "ark-std" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1df2c09229cbc5a028b1d70e00fdb2acee28b1055dfb5ca73eea49c5a25c4e7c" +dependencies = [ + "num-traits", + "rand 0.8.5", +] + +[[package]] +name = "ark-std" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94893f1e0c6eeab764ade8dc4c0db24caf4fe7cbbaafc0eba0a9030f447b5185" +dependencies = [ + "num-traits", + "rand 0.8.5", +] + +[[package]] +name = "ark-std" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "246a225cc6131e9ee4f24619af0f19d67761fff15d7ccc22e42b80846e69449a" +dependencies = [ + "num-traits", + "rand 0.8.5", +] + [[package]] name = "arrayref" version = "0.3.7" @@ -144,6 +938,9 @@ name = "arrayvec" version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" +dependencies = [ + "serde", +] [[package]] name = "ascii_utils" @@ -220,11 +1017,11 @@ checksum = "fd45deb3dbe5da5cdb8d6a670a7736d735ba65b455328440f236dfb113727a3d" dependencies = [ "Inflector", "async-graphql-parser", - "darling", + "darling 0.20.10", "proc-macro-crate", "proc-macro2", "quote", - "strum", + "strum 0.26.3", "syn 2.0.106", "thiserror 1.0.61", ] @@ -320,6 +1117,17 @@ dependencies = [ "winapi", ] +[[package]] +name = "auto_impl" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ffdcb70bdbc4d478427380519163274ac86e52916e10f0a8889adf0f96d3fee7" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.106", +] + [[package]] name = "autocfg" version = "1.3.0" @@ -460,6 +1268,12 @@ version = "0.2.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4cbbc9d0964165b47557570cce6c952866c2678457aca742aafc9fb771d30270" +[[package]] +name = "base16ct" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c7f02d4ea65f2c1853089ffd8d2787bdbc63de2f0d29dedbcf8ccdfa0ccd4cf" + [[package]] name = "base64" version = "0.13.1" @@ -478,6 +1292,12 @@ version = "0.22.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" +[[package]] +name = "base64ct" +version = "1.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2af50177e190e07a26ab74f8b1efbfe2ef87da2116221318cb1c2e82baf7de06" + [[package]] name = "beef" version = "0.5.2" @@ -510,6 +1330,37 @@ dependencies = [ "num-traits", ] +[[package]] +name = "bit-set" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08807e080ed7f9d5433fa9b275196cfc35414f66a0c79d864dc51a0d825231a3" +dependencies = [ + "bit-vec", +] + +[[package]] +name = "bit-vec" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e764a1d40d510daf35e07be9eb06e75770908c27d411ee6c92109c9840eaaf7" + +[[package]] +name = "bitcoin-io" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2dee39a0ee5b4095224a0cfc6bf4cc1baf0f9624b96b367e53b66d974e51d953" + +[[package]] +name = "bitcoin_hashes" +version = "0.14.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26ec84b80c482df901772e931a9a681e26a1b9ee2302edeff23cb30328745c8b" +dependencies = [ + "bitcoin-io", + "hex-conservative", +] + [[package]] name = "bitflags" version = "1.3.2" @@ -580,6 +1431,41 @@ dependencies = [ "generic-array", ] +[[package]] +name = "blst" +version = "0.3.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dcdb4c7013139a150f9fc55d123186dbfaba0d912817466282c73ac49e71fb45" +dependencies = [ + "cc", + "glob", + "threadpool", + "zeroize", +] + +[[package]] +name = "borsh" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1da5ab77c1437701eeff7c88d968729e7766172279eab0676857b3d63af7a6f" +dependencies = [ + "borsh-derive", + "cfg_aliases", +] + +[[package]] +name = "borsh-derive" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0686c856aa6aac0c4498f936d7d6a02df690f614c03e4d906d1018062b5c5e2c" +dependencies = [ + "once_cell", + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 2.0.106", +] + [[package]] name = "bs58" version = "0.4.0" @@ -635,6 +1521,21 @@ dependencies = [ "serde", ] +[[package]] +name = "c-kzg" +version = "2.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e00bf4b112b07b505472dbefd19e37e53307e2bfed5a79e0cc161d58ccd0e687" +dependencies = [ + "blst", + "cc", + "glob", + "hex", + "libc", + "once_cell", + "serde", +] + [[package]] name = "cc" version = "1.2.16" @@ -658,6 +1559,12 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" +[[package]] +name = "cfg_aliases" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613afe47fcd5fac7ccf1db93babcb082c5994d996f20b8b159f2ad1658eb5724" + [[package]] name = "chrono" version = "0.4.42" @@ -764,6 +1671,24 @@ dependencies = [ "windows-sys 0.59.0", ] +[[package]] +name = "const-hex" +version = "1.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3bb320cac8a0750d7f25280aa97b09c26edfe161164238ecbbb31092b079e735" +dependencies = [ + "cfg-if 1.0.0", + "cpufeatures", + "proptest", + "serde_core", +] + +[[package]] +name = "const-oid" +version = "0.9.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" + [[package]] name = "constant_time_eq" version = "0.1.5" @@ -901,7 +1826,7 @@ dependencies = [ "log", "pulley-interpreter", "regalloc2", - "rustc-hash 2.0.0", + "rustc-hash 2.1.1", "serde", "smallvec", "target-lexicon", @@ -967,18 +1892,33 @@ checksum = "711baa4e3432d4129295b39ec2b4040cc1b558874ba0a37d08e832e857db7285" name = "cranelift-native" version = "0.120.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41c83e8666e3bcc5ffeaf6f01f356f0e1f9dcd69ce5511a1efd7ca5722001a3f" +checksum = "41c83e8666e3bcc5ffeaf6f01f356f0e1f9dcd69ce5511a1efd7ca5722001a3f" +dependencies = [ + "cranelift-codegen", + "libc", + "target-lexicon", +] + +[[package]] +name = "cranelift-srcgen" +version = "0.120.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "02e3f4d783a55c64266d17dc67d2708852235732a100fc40dd9f1051adc64d7b" + +[[package]] +name = "crc" +version = "3.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5eb8a2a1cd12ab0d987a5d5e825195d372001a4094a0376319d5a0ad71c1ba0d" dependencies = [ - "cranelift-codegen", - "libc", - "target-lexicon", + "crc-catalog", ] [[package]] -name = "cranelift-srcgen" -version = "0.120.2" +name = "crc-catalog" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02e3f4d783a55c64266d17dc67d2708852235732a100fc40dd9f1051adc64d7b" +checksum = "19d374276b40fb8bbdee95aef7c7fa6b5316ec764510eb64b8dd0e2ed0d7e7f5" [[package]] name = "crc32fast" @@ -1051,6 +1991,18 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" +[[package]] +name = "crypto-bigint" +version = "0.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0dc92fb57ca44df6db8059111ab3af99a63d5d0f8375d9972e319a379c6bab76" +dependencies = [ + "generic-array", + "rand_core 0.6.4", + "subtle", + "zeroize", +] + [[package]] name = "crypto-common" version = "0.1.6" @@ -1098,8 +2050,18 @@ version = "0.20.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6f63b86c8a8826a49b8c21f08a2d07338eec8d900540f8630dc76284be802989" dependencies = [ - "darling_core", - "darling_macro", + "darling_core 0.20.10", + "darling_macro 0.20.10", +] + +[[package]] +name = "darling" +version = "0.21.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cdf337090841a411e2a7f3deb9187445851f91b309c0c0a29e05f74a00a48c0" +dependencies = [ + "darling_core 0.21.3", + "darling_macro 0.21.3", ] [[package]] @@ -1116,17 +2078,57 @@ dependencies = [ "syn 2.0.106", ] +[[package]] +name = "darling_core" +version = "0.21.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1247195ecd7e3c85f83c8d2a366e4210d588e802133e1e355180a9870b517ea4" +dependencies = [ + "fnv", + "ident_case", + "proc-macro2", + "quote", + "serde", + "strsim", + "syn 2.0.106", +] + [[package]] name = "darling_macro" version = "0.20.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d336a2a514f6ccccaa3e09b02d41d35330c07ddf03a62165fcec10bb561c7806" dependencies = [ - "darling_core", + "darling_core 0.20.10", + "quote", + "syn 2.0.106", +] + +[[package]] +name = "darling_macro" +version = "0.21.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d38308df82d1080de0afee5d069fa14b0326a88c14f15c5ccda35b4a6c414c81" +dependencies = [ + "darling_core 0.21.3", "quote", "syn 2.0.106", ] +[[package]] +name = "dashmap" +version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5041cc499144891f3790297212f32a74fb938e5136a14943f338ef9e0ae276cf" +dependencies = [ + "cfg-if 1.0.0", + "crossbeam-utils", + "hashbrown 0.14.5", + "lock_api", + "once_cell", + "parking_lot_core", +] + [[package]] name = "data-encoding" version = "2.6.0" @@ -1185,6 +2187,16 @@ version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "930c7171c8df9fb1782bdf9b918ed9ed2d33d1d22300abb754f9085bc48bf8e8" +[[package]] +name = "der" +version = "0.7.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e7c1832837b905bbfb5101e07cc24c8deddf52f93225eee6ead5f4d63d53ddcb" +dependencies = [ + "const-oid", + "zeroize", +] + [[package]] name = "deranged" version = "0.3.11" @@ -1215,7 +2227,7 @@ dependencies = [ "convert_case 0.4.0", "proc-macro2", "quote", - "rustc_version", + "rustc_version 0.4.0", "syn 2.0.106", ] @@ -1343,6 +2355,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" dependencies = [ "block-buffer 0.10.4", + "const-oid", "crypto-common", "subtle", ] @@ -1416,7 +2429,7 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0892a17df262a24294c382f0d5997571006e7a4348b4327557c4ff1cd4a8bccc" dependencies = [ - "darling", + "darling 0.20.10", "either", "heck 0.5.0", "proc-macro2", @@ -1424,11 +2437,67 @@ dependencies = [ "syn 2.0.106", ] +[[package]] +name = "dunce" +version = "1.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813" + +[[package]] +name = "ecdsa" +version = "0.16.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee27f32b5c5292967d2d4a9d7f1e0b0aed2c15daded5a60300e4abb9d8020bca" +dependencies = [ + "der", + "digest 0.10.7", + "elliptic-curve", + "rfc6979", + "serdect", + "signature", + "spki", +] + +[[package]] +name = "educe" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d7bc049e1bd8cdeb31b68bbd586a9464ecf9f3944af3958a7a9d0f8b9799417" +dependencies = [ + "enum-ordinalize", + "proc-macro2", + "quote", + "syn 2.0.106", +] + [[package]] name = "either" -version = "1.13.0" +version = "1.15.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48c757948c5ede0e46177b7add2e67155f70e33c07fea8284df6576da70b3719" +dependencies = [ + "serde", +] + +[[package]] +name = "elliptic-curve" +version = "0.13.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" +checksum = "b5e6043086bf7973472e0c7dff2142ea0b680d30e18d9cc40f267efbf222bd47" +dependencies = [ + "base16ct", + "crypto-bigint", + "digest 0.10.7", + "ff", + "generic-array", + "group", + "pkcs8", + "rand_core 0.6.4", + "sec1", + "serdect", + "subtle", + "zeroize", +] [[package]] name = "embedded-io" @@ -1457,6 +2526,26 @@ dependencies = [ "cfg-if 1.0.0", ] +[[package]] +name = "enum-ordinalize" +version = "4.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4a1091a7bb1f8f2c4b28f1fe2cef4980ca2d410a3d727d67ecc3178c9b0800f0" +dependencies = [ + "enum-ordinalize-derive", +] + +[[package]] +name = "enum-ordinalize-derive" +version = "4.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ca9601fb2d62598ee17836250842873a413586e5d7ed88b356e38ddbb0ec631" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.106", +] + [[package]] name = "env_filter" version = "0.1.0" @@ -1540,7 +2629,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "11da94e443c60508eb62cf256243a64da87304c2802ac2528847f79d750007ef" dependencies = [ "crunchy", - "fixed-hash", + "fixed-hash 0.7.0", "impl-rlp", "impl-serde", "tiny-keccak 2.0.2", @@ -1553,10 +2642,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b2827b94c556145446fcce834ca86b7abf0c39a805883fe20e72c5bfdb5a0dc6" dependencies = [ "ethbloom", - "fixed-hash", + "fixed-hash 0.7.0", "impl-rlp", "impl-serde", - "primitive-types", + "primitive-types 0.11.1", "uint 0.9.5", ] @@ -1587,6 +2676,38 @@ version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" +[[package]] +name = "fastrlp" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "139834ddba373bbdd213dffe02c8d110508dcf1726c2be27e8d1f7d7e1856418" +dependencies = [ + "arrayvec 0.7.4", + "auto_impl", + "bytes", +] + +[[package]] +name = "fastrlp" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce8dba4714ef14b8274c371879b175aa55b16b30f269663f19d576f380018dc4" +dependencies = [ + "arrayvec 0.7.4", + "auto_impl", + "bytes", +] + +[[package]] +name = "ff" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c0b50bfb653653f9ca9095b427bed08ab8d75a137839d9ad64eb11810d5b6393" +dependencies = [ + "rand_core 0.6.4", + "subtle", +] + [[package]] name = "firestorm" version = "0.4.6" @@ -1611,6 +2732,18 @@ dependencies = [ "static_assertions", ] +[[package]] +name = "fixed-hash" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "835c052cb0c08c1acf6ffd71c022172e18723949c8282f2b9f27efbc51e64534" +dependencies = [ + "byteorder", + "rand 0.8.5", + "rustc-hex", + "static_assertions", +] + [[package]] name = "fixedbitset" version = "0.5.7" @@ -1639,6 +2772,12 @@ version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2" +[[package]] +name = "foldhash" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb" + [[package]] name = "foreign-types" version = "0.3.2" @@ -1780,6 +2919,12 @@ dependencies = [ "slab", ] +[[package]] +name = "futures-utils-wasm" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42012b0f064e01aa58b545fe3727f90f7dd4020f4a3ea735b50344965f5a57e9" + [[package]] name = "fxhash" version = "0.2.1" @@ -1810,6 +2955,7 @@ checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" dependencies = [ "typenum", "version_check", + "zeroize", ] [[package]] @@ -1874,6 +3020,12 @@ dependencies = [ "time", ] +[[package]] +name = "glob" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0cc23270f6e1808e30a928bdc84dea0b9b4136a8bc82338574f23baf47bbd280" + [[package]] name = "globset" version = "0.4.16" @@ -1944,7 +3096,7 @@ dependencies = [ "humantime", "hyper 1.7.0", "hyper-util", - "itertools", + "itertools 0.14.0", "lazy_static", "lru_time_cache", "maplit", @@ -1962,7 +3114,7 @@ dependencies = [ "redis", "regex", "reqwest", - "semver", + "semver 1.0.27", "serde", "serde_derive", "serde_json", @@ -2006,6 +3158,7 @@ dependencies = [ name = "graph-chain-ethereum" version = "0.41.0" dependencies = [ + "alloy", "anyhow", "base64 0.22.1", "envconfig", @@ -2013,12 +3166,13 @@ dependencies = [ "graph-runtime-derive", "graph-runtime-wasm", "hex", - "itertools", + "itertools 0.14.0", "jsonrpc-core", "prost", "prost-types", - "semver", + "semver 1.0.27", "serde", + "serde_json", "thiserror 2.0.16", "tiny-keccak 1.5.0", "tonic-build", @@ -2052,7 +3206,7 @@ dependencies = [ "lazy_static", "prost", "prost-types", - "semver", + "semver 1.0.27", "serde", "tokio", "tonic-build", @@ -2117,7 +3271,7 @@ dependencies = [ "graph-store-postgres", "graphman", "graphman-server", - "itertools", + "itertools 0.14.0", "json-structural-diff", "lazy_static", "notify", @@ -2147,7 +3301,7 @@ dependencies = [ "graph-runtime-derive", "graph-runtime-wasm", "rand 0.9.2", - "semver", + "semver 1.0.27", "test-store", "wasmtime", ] @@ -2165,7 +3319,7 @@ dependencies = [ "hex", "never", "parity-wasm", - "semver", + "semver 1.0.27", "serde_yaml", "wasm-instrument", "wasmtime", @@ -2232,7 +3386,7 @@ dependencies = [ "graphman-store", "graphql-parser", "hex", - "itertools", + "itertools 0.14.0", "lazy_static", "lru_time_cache", "maybe-owned", @@ -2262,7 +3416,7 @@ dependencies = [ "graph-runtime-wasm", "graph-server-index-node", "graph-store-postgres", - "secp256k1", + "secp256k1 0.21.3", "serde", "serde_yaml", "slog", @@ -2290,7 +3444,7 @@ dependencies = [ "graph", "graph-store-postgres", "graphman-store", - "itertools", + "itertools 0.14.0", "thiserror 2.0.16", "tokio", ] @@ -2327,7 +3481,7 @@ dependencies = [ "anyhow", "chrono", "diesel", - "strum", + "strum 0.26.3", ] [[package]] @@ -2353,6 +3507,17 @@ dependencies = [ "serde_with", ] +[[package]] +name = "group" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" +dependencies = [ + "ff", + "rand_core 0.6.4", + "subtle", +] + [[package]] name = "h2" version = "0.3.26" @@ -2411,6 +3576,12 @@ version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" +[[package]] +name = "hashbrown" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" + [[package]] name = "hashbrown" version = "0.15.2" @@ -2419,8 +3590,21 @@ checksum = "bf151400ff0baff5465007dd2f3e717f3fe502074ca563069ce3a6629d07b289" dependencies = [ "allocator-api2", "equivalent", - "foldhash", + "foldhash 0.1.5", + "serde", +] + +[[package]] +name = "hashbrown" +version = "0.16.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100" +dependencies = [ + "allocator-api2", + "equivalent", + "foldhash 0.2.0", "serde", + "serde_core", ] [[package]] @@ -2490,6 +3674,15 @@ version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" +[[package]] +name = "hex-conservative" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fda06d18ac606267c40c04e41b9947729bf8b9efe74bd4e82b61a5f26a510b9f" +dependencies = [ + "arrayvec 0.7.4", +] + [[package]] name = "hex-literal" version = "0.3.4" @@ -2657,6 +3850,7 @@ dependencies = [ "tokio", "tokio-rustls", "tower-service 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", + "webpki-roots 0.26.11", ] [[package]] @@ -2967,7 +4161,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4b0f83760fb341a774ed326568e19f5a863af4a952def8c39f9ab92fd95b88e5" dependencies = [ "equivalent", - "hashbrown 0.15.2", + "hashbrown 0.16.1", "serde", "serde_core", ] @@ -3036,6 +4230,24 @@ version = "1.70.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" +[[package]] +name = "itertools" +version = "0.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" +dependencies = [ + "either", +] + +[[package]] +name = "itertools" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "413ee7dfc52ee1a4949ceeb7dbc8a33f2d6c088194d9f922fb8318faf1f01186" +dependencies = [ + "either", +] + [[package]] name = "itertools" version = "0.14.0" @@ -3212,6 +4424,20 @@ dependencies = [ "tracing", ] +[[package]] +name = "k256" +version = "0.13.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6e3919bbaa2945715f0bb6d3934a173d1e9a59ac23767fbaaef277265a7411b" +dependencies = [ + "cfg-if 1.0.0", + "ecdsa", + "elliptic-curve", + "once_cell", + "serdect", + "sha2", +] + [[package]] name = "keccak" version = "0.1.5" @@ -3221,6 +4447,16 @@ dependencies = [ "cpufeatures", ] +[[package]] +name = "keccak-asm" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "505d1856a39b200489082f90d897c3f07c455563880bc5952e38eabf731c83b6" +dependencies = [ + "digest 0.10.7", + "sha3-asm", +] + [[package]] name = "kqueue" version = "1.1.1" @@ -3315,6 +4551,15 @@ version = "0.4.22" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" +[[package]] +name = "lru" +version = "0.16.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1dc47f592c06f33f8e3aea9591776ec7c9f9e4124778ff8a3c3b87159f7e593" +dependencies = [ + "hashbrown 0.16.1", +] + [[package]] name = "lru_time_cache" version = "0.11.11" @@ -3330,6 +4575,17 @@ dependencies = [ "libc", ] +[[package]] +name = "macro-string" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b27834086c65ec3f9387b096d66e99f221cf081c2b738042aa252bcd41204e3" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.106", +] + [[package]] name = "maplit" version = "1.0.2" @@ -3578,16 +4834,52 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", + "libm", ] [[package]] name = "num_cpus" version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" +dependencies = [ + "hermit-abi 0.3.9", + "libc", +] + +[[package]] +name = "num_enum" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b1207a7e20ad57b847bbddc6776b968420d38292bbfe2089accff5e19e82454c" +dependencies = [ + "num_enum_derive", + "rustversion", +] + +[[package]] +name = "num_enum_derive" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff32365de1b6743cb203b710788263c44a03de03802daf96092f2da4fe6ba4d7" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.106", +] + +[[package]] +name = "nybbles" +version = "0.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b5676b5c379cf5b03da1df2b3061c4a4e2aa691086a56ac923e08c143f53f59" dependencies = [ - "hermit-abi 0.3.9", - "libc", + "alloy-rlp", + "cfg-if 1.0.0", + "proptest", + "ruint", + "serde", + "smallvec", ] [[package]] @@ -3618,7 +4910,7 @@ dependencies = [ "http-body-util", "humantime", "hyper 1.7.0", - "itertools", + "itertools 0.14.0", "parking_lot", "percent-encoding", "quick-xml", @@ -3640,9 +4932,9 @@ dependencies = [ [[package]] name = "once_cell" -version = "1.19.0" +version = "1.21.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" +checksum = "42f5e15c9953c5e4ccceeb2e7382a716482c34515315f7b03532b8b4e8393d2d" [[package]] name = "opaque-debug" @@ -3774,6 +5066,12 @@ dependencies = [ "windows-targets 0.52.6", ] +[[package]] +name = "paste" +version = "1.0.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" + [[package]] name = "percent-encoding" version = "2.3.2" @@ -3908,6 +5206,16 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" +[[package]] +name = "pkcs8" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7" +dependencies = [ + "der", + "spki", +] + [[package]] name = "pkg-config" version = "0.3.30" @@ -4055,13 +5363,24 @@ version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e28720988bff275df1f51b171e1b2a18c30d194c4d2b61defdacecd625a5d94a" dependencies = [ - "fixed-hash", + "fixed-hash 0.7.0", "impl-codec", "impl-rlp", "impl-serde", "uint 0.9.5", ] +[[package]] +name = "primitive-types" +version = "0.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b34d9fd68ae0b74a41b21c03c2f62847aa0ffea044eee893b4c140b37e244e2" +dependencies = [ + "fixed-hash 0.8.0", + "impl-codec", + "uint 0.9.5", +] + [[package]] name = "priority-queue" version = "2.6.0" @@ -4081,6 +5400,28 @@ dependencies = [ "toml_edit 0.21.1", ] +[[package]] +name = "proc-macro-error-attr2" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96de42df36bb9bba5542fe9f1a054b8cc87e172759a1868aa05c1f3acc89dfc5" +dependencies = [ + "proc-macro2", + "quote", +] + +[[package]] +name = "proc-macro-error2" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "11ec05c52be0a07b08061f7dd003e7d7092e0472bc731b4af7bb1ef876109802" +dependencies = [ + "proc-macro-error-attr2", + "proc-macro2", + "quote", + "syn 2.0.106", +] + [[package]] name = "proc-macro-utils" version = "0.10.0" @@ -4118,6 +5459,25 @@ dependencies = [ "thiserror 2.0.16", ] +[[package]] +name = "proptest" +version = "1.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bee689443a2bd0a16ab0348b52ee43e3b2d1b1f931c8aa5c9f8de4c86fbe8c40" +dependencies = [ + "bit-set", + "bit-vec", + "bitflags 2.9.0", + "num-traits", + "rand 0.9.2", + "rand_chacha 0.9.0", + "rand_xorshift", + "regex-syntax", + "rusty-fork", + "tempfile", + "unarray", +] + [[package]] name = "prost" version = "0.13.5" @@ -4135,7 +5495,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "be769465445e8c1474e9c5dac2018218498557af32d9ed057325ec9a41ae81bf" dependencies = [ "heck 0.5.0", - "itertools", + "itertools 0.14.0", "log", "multimap", "once_cell", @@ -4155,7 +5515,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a56d757972c98b346a9b766e3f02746cde6dd1cd1d1d563472929fdd74bec4d" dependencies = [ "anyhow", - "itertools", + "itertools 0.14.0", "proc-macro2", "quote", "syn 2.0.106", @@ -4226,6 +5586,12 @@ dependencies = [ "wasmtime-math", ] +[[package]] +name = "quick-error" +version = "1.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" + [[package]] name = "quick-xml" version = "0.38.2" @@ -4262,7 +5628,7 @@ dependencies = [ "bytes", "rand 0.8.5", "ring", - "rustc-hash 2.0.0", + "rustc-hash 2.1.1", "rustls", "slab", "thiserror 1.0.61", @@ -4318,6 +5684,7 @@ dependencies = [ "libc", "rand_chacha 0.3.1", "rand_core 0.6.4", + "serde", ] [[package]] @@ -4328,6 +5695,7 @@ checksum = "6db2770f06117d490610c7488547d543617b21bfa07796d7a12f6f1bd53850d1" dependencies = [ "rand_chacha 0.9.0", "rand_core 0.9.3", + "serde", ] [[package]] @@ -4366,6 +5734,25 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "99d9a13982dcf210057a8a78572b2217b667c3beacbf3a0d8b454f6f82837d38" dependencies = [ "getrandom 0.3.1", + "serde", +] + +[[package]] +name = "rand_xorshift" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "513962919efc330f829edb2535844d1b912b0fbe2ca165d613e4e8788bb05a5a" +dependencies = [ + "rand_core 0.9.3", +] + +[[package]] +name = "rapidhash" +version = "4.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d8b5b858a440a0bc02625b62dd95131b9201aa9f69f411195dd4a7cfb1de3d7" +dependencies = [ + "rustversion", ] [[package]] @@ -4452,7 +5839,7 @@ dependencies = [ "bumpalo", "hashbrown 0.15.2", "log", - "rustc-hash 2.0.0", + "rustc-hash 2.1.1", "smallvec", ] @@ -4532,6 +5919,17 @@ dependencies = [ "wasm-bindgen-futures", "wasm-streams", "web-sys", + "webpki-roots 1.0.5", +] + +[[package]] +name = "rfc6979" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" +dependencies = [ + "hmac", + "subtle", ] [[package]] @@ -4558,6 +5956,40 @@ dependencies = [ "rustc-hex", ] +[[package]] +name = "ruint" +version = "1.17.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c141e807189ad38a07276942c6623032d3753c8859c146104ac2e4d68865945a" +dependencies = [ + "alloy-rlp", + "ark-ff 0.3.0", + "ark-ff 0.4.2", + "ark-ff 0.5.0", + "bytes", + "fastrlp 0.3.1", + "fastrlp 0.4.0", + "num-bigint 0.4.6", + "num-integer", + "num-traits", + "parity-scale-codec", + "primitive-types 0.12.2", + "proptest", + "rand 0.8.5", + "rand 0.9.2", + "rlp", + "ruint-macro", + "serde_core", + "valuable", + "zeroize", +] + +[[package]] +name = "ruint-macro" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48fd7bd8a6377e15ad9d42a8ec25371b94ddc67abe7c8b9127bec79bebaaae18" + [[package]] name = "rustc-demangle" version = "0.1.24" @@ -4572,9 +6004,9 @@ checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" [[package]] name = "rustc-hash" -version = "2.0.0" +version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "583034fd73374156e66797ed8e5b0d5690409c9226b22d87cb7f19821c05d152" +checksum = "357703d41365b4b27c590e3ed91eabb1b663f07c4c084095e60cbed4362dff0d" [[package]] name = "rustc-hex" @@ -4582,13 +6014,22 @@ version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3e75f6a532d0fd9f7f13144f392b6ad56a32696bfcd9c78f797f16bbb6f072d6" +[[package]] +name = "rustc_version" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0dfe2087c51c460008730de8b57e6a320782fbfb312e1f4d520e6c6fae155ee" +dependencies = [ + "semver 0.11.0", +] + [[package]] name = "rustc_version" version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" dependencies = [ - "semver", + "semver 1.0.27", ] [[package]] @@ -4690,6 +6131,18 @@ version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "955d28af4278de8121b7ebeb796b6a45735dc01436d898801014aced2773a3d6" +[[package]] +name = "rusty-fork" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cc6bf79ff24e648f6da1f8d1f011e9cac26491b619e6b9280f2b47f1774e6ee2" +dependencies = [ + "fnv", + "quick-error", + "tempfile", + "wait-timeout", +] + [[package]] name = "ryu" version = "1.0.18" @@ -4729,13 +6182,40 @@ version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" +[[package]] +name = "sec1" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3e97a565f76233a6003f9f5c54be1d9c5bdfa3eccfb189469f11ec4901c47dc" +dependencies = [ + "base16ct", + "der", + "generic-array", + "pkcs8", + "serdect", + "subtle", + "zeroize", +] + [[package]] name = "secp256k1" version = "0.21.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9c42e6f1735c5f00f51e43e28d6634141f2bcad10931b2609ddd74a86d751260" dependencies = [ - "secp256k1-sys", + "secp256k1-sys 0.4.2", +] + +[[package]] +name = "secp256k1" +version = "0.30.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b50c5943d326858130af85e049f2661ba3c78b26589b8ab98e65e80ae44a1252" +dependencies = [ + "bitcoin_hashes", + "rand 0.8.5", + "secp256k1-sys 0.10.1", + "serde", ] [[package]] @@ -4747,6 +6227,15 @@ dependencies = [ "cc", ] +[[package]] +name = "secp256k1-sys" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4387882333d3aa8cb20530a17c69a3752e97837832f34f6dccc760e715001d9" +dependencies = [ + "cc", +] + [[package]] name = "security-framework" version = "2.11.0" @@ -4783,6 +6272,15 @@ dependencies = [ "libc", ] +[[package]] +name = "semver" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f301af10236f6df4160f7c3f04eec6dbc70ace82d23326abad5edee88801c6b6" +dependencies = [ + "semver-parser", +] + [[package]] name = "semver" version = "1.0.27" @@ -4793,6 +6291,15 @@ dependencies = [ "serde_core", ] +[[package]] +name = "semver-parser" +version = "0.10.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9900206b54a3527fdc7b8a938bffd94a568bac4f4aa8113b209df75a09c0dec2" +dependencies = [ + "pest", +] + [[package]] name = "serde" version = "1.0.226" @@ -4917,7 +6424,7 @@ version = "3.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8d00caa5193a3c8362ac2b73be6b9e768aa5a4b2f721d8f4b339600c3cb51f8e" dependencies = [ - "darling", + "darling 0.20.10", "proc-macro2", "quote", "syn 2.0.106", @@ -4936,6 +6443,16 @@ dependencies = [ "unsafe-libyaml", ] +[[package]] +name = "serdect" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a84f14a19e9a014bb9f4512488d9829a68e04ecabffb0f9904cd1ace94598177" +dependencies = [ + "base16ct", + "serde", +] + [[package]] name = "sha-1" version = "0.9.8" @@ -4987,6 +6504,16 @@ dependencies = [ "keccak", ] +[[package]] +name = "sha3-asm" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c28efc5e327c837aa837c59eae585fc250715ef939ac32881bcc11677cd02d46" +dependencies = [ + "cc", + "cfg-if 1.0.0", +] + [[package]] name = "shellexpand" version = "3.1.1" @@ -5011,6 +6538,16 @@ dependencies = [ "libc", ] +[[package]] +name = "signature" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de" +dependencies = [ + "digest 0.10.7", + "rand_core 0.6.4", +] + [[package]] name = "siphasher" version = "0.3.11" @@ -5144,6 +6681,16 @@ version = "0.9.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" +[[package]] +name = "spki" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d91ed6c858b01f942cd56b37a94b3e0a1798290327d1236e4d9cf4eaca44d29d" +dependencies = [ + "base64ct", + "der", +] + [[package]] name = "sptr" version = "0.3.2" @@ -5231,6 +6778,15 @@ dependencies = [ "strum_macros 0.26.4", ] +[[package]] +name = "strum" +version = "0.27.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af23d6f6c1a224baef9d3f61e287d2761385a5b88fdab4eb4c6f11aeb54c4bcf" +dependencies = [ + "strum_macros 0.27.2", +] + [[package]] name = "strum_macros" version = "0.26.4" @@ -5362,6 +6918,18 @@ dependencies = [ "unicode-ident", ] +[[package]] +name = "syn-solidity" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f92d01b5de07eaf324f7fca61cc6bd3d82bbc1de5b6c963e6fe79e86f36580d" +dependencies = [ + "paste", + "proc-macro2", + "quote", + "syn 2.0.106", +] + [[package]] name = "sync_wrapper" version = "0.1.2" @@ -5536,6 +7104,15 @@ dependencies = [ "once_cell", ] +[[package]] +name = "threadpool" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaa" +dependencies = [ + "num_cpus", +] + [[package]] name = "time" version = "0.3.36" @@ -6135,6 +7712,12 @@ dependencies = [ "static_assertions", ] +[[package]] +name = "unarray" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" + [[package]] name = "unicase" version = "2.7.0" @@ -6261,6 +7844,12 @@ version = "1.15.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e0f540e3240398cce6128b64ba83fdbdd86129c16a3aa1a3a252efd66eb3d587" +[[package]] +name = "valuable" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba73ea9cf16a25df0c8caa16c51acb937d5712a8429db78a3ee29d5dcacd3a65" + [[package]] name = "vcpkg" version = "0.2.15" @@ -6273,6 +7862,15 @@ version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" +[[package]] +name = "wait-timeout" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09ac3b126d3914f9849036f826e054cbabdc8519970b8998ddaf3b5bd3c65f11" +dependencies = [ + "libc", +] + [[package]] name = "walkdir" version = "2.5.0" @@ -6432,7 +8030,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "77f1154f1ab868e2a01d9834a805faca7bf8b50d041b4ca714d005d0dab1c50c" dependencies = [ "indexmap 2.11.4", - "semver", + "semver 1.0.27", ] [[package]] @@ -6444,7 +8042,7 @@ dependencies = [ "bitflags 2.9.0", "hashbrown 0.15.2", "indexmap 2.11.4", - "semver", + "semver 1.0.27", "serde", ] @@ -6456,7 +8054,7 @@ checksum = "b51cb03afce7964bbfce46602d6cb358726f36430b6ba084ac6020d8ce5bc102" dependencies = [ "bitflags 2.9.0", "indexmap 2.11.4", - "semver", + "semver 1.0.27", ] [[package]] @@ -6500,7 +8098,7 @@ dependencies = [ "pulley-interpreter", "rayon", "rustix 1.0.7", - "semver", + "semver 1.0.27", "serde", "serde_derive", "serde_json", @@ -6591,7 +8189,7 @@ dependencies = [ "cranelift-frontend", "cranelift-native", "gimli 0.31.1", - "itertools", + "itertools 0.14.0", "log", "object", "pulley-interpreter", @@ -6619,7 +8217,7 @@ dependencies = [ "object", "postcard", "rustc-demangle", - "semver", + "semver 1.0.27", "serde", "serde_derive", "smallvec", @@ -6724,6 +8322,20 @@ dependencies = [ "wit-parser", ] +[[package]] +name = "wasmtimer" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1c598d6b99ea013e35844697fc4670d08339d5cda15588f193c6beedd12f644b" +dependencies = [ + "futures 0.3.31", + "js-sys", + "parking_lot", + "pin-utils", + "slab", + "wasm-bindgen", +] + [[package]] name = "wast" version = "233.0.0" @@ -6789,7 +8401,7 @@ dependencies = [ "pin-project", "reqwest", "rlp", - "secp256k1", + "secp256k1 0.21.3", "serde", "serde_json", "soketto", @@ -6813,6 +8425,24 @@ dependencies = [ "url", ] +[[package]] +name = "webpki-roots" +version = "0.26.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "521bc38abb08001b01866da9f51eb7c5d647a19260e00054a8c7fd5f9e57f7a9" +dependencies = [ + "webpki-roots 1.0.5", +] + +[[package]] +name = "webpki-roots" +version = "1.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "12bed680863276c63889429bfd6cab3b99943659923822de1c8a39c49e4d722c" +dependencies = [ + "rustls-pki-types", +] + [[package]] name = "which" version = "4.4.2" @@ -7181,6 +8811,9 @@ name = "winnow" version = "0.7.13" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "21a0236b59786fed61e2a80582dd500fe61f18b5dca67a4a067d0bc9039339cf" +dependencies = [ + "memchr", +] [[package]] name = "wiremock" @@ -7224,7 +8857,7 @@ dependencies = [ "id-arena", "indexmap 2.11.4", "log", - "semver", + "semver 1.0.27", "serde", "serde_derive", "serde_json", @@ -7315,6 +8948,20 @@ name = "zeroize" version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" +dependencies = [ + "zeroize_derive", +] + +[[package]] +name = "zeroize_derive" +version = "1.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85a5b4158499876c763cb03bc4e49185d3cccbabb15b33c627f7884f43db852e" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.106", +] [[package]] name = "zerovec" diff --git a/chain/ethereum/Cargo.toml b/chain/ethereum/Cargo.toml index 07348bf7a6b..e6a1bef5305 100644 --- a/chain/ethereum/Cargo.toml +++ b/chain/ethereum/Cargo.toml @@ -8,6 +8,7 @@ envconfig = "0.11.0" jsonrpc-core = "18.0.0" graph = { path = "../../graph" } serde = { workspace = true } +serde_json = { workspace = true } prost = { workspace = true } prost-types = { workspace = true } anyhow = "1.0" @@ -16,6 +17,9 @@ hex = "0.4.3" semver = "1.0.27" thiserror = { workspace = true } +# Alloy for compatibility testing - deserialize in parallel with rust-web3 +alloy = { version = "1.0", features = ["network", "rpc-types-eth"] } + itertools = "0.14.0" graph-runtime-wasm = { path = "../../runtime/wasm" } diff --git a/chain/ethereum/src/ethereum_adapter.rs b/chain/ethereum/src/ethereum_adapter.rs index 3ca046f359b..73c6f1f6073 100644 --- a/chain/ethereum/src/ethereum_adapter.rs +++ b/chain/ethereum/src/ethereum_adapter.rs @@ -1,3 +1,5 @@ +use alloy::network::AnyRpcBlock; +use alloy::rpc::types::Block as AlloyRpcBlock; use futures03::{future::BoxFuture, stream::FuturesUnordered}; use graph::blockchain::client::ChainClient; use graph::blockchain::BlockHash; @@ -73,6 +75,61 @@ use crate::{ ENV_VARS, }; +/// Test alloy deserialization compatibility with a block from block cache. +/// This is for debugging/validation - it deserializes the same block JSON with alloy +/// and logs whether it succeeds or fails, without affecting the actual block processing. +/// +/// Tests two types: +/// 1. AlloyRpcBlock (strict) - uses TxEnvelope, requires chainId for typed transactions +/// 2. AnyRpcBlock (lenient) - uses AnyTxEnvelope with fallback to Unknown variant +fn test_alloy_block_compat(logger: &Logger, value: &json::Value) { + // Extract block number/hash for logging before attempting deserialization + let block_num = value + .get("number") + .and_then(|v| v.as_str()) + .unwrap_or("unknown"); + let block_hash = value + .get("hash") + .and_then(|v| v.as_str()) + .map(|s| &s[..std::cmp::min(18, s.len())]) + .unwrap_or("unknown"); + + // Test 1: Strict type (AlloyRpcBlock) - will fail for blocks with typed txns missing chainId + let strict_result = serde_json::from_value::(value.clone()); + let strict_status = match &strict_result { + Ok(block) => format!("OK txs={}", block.transactions.len()), + Err(e) => format!("FAIL err={}", e), + }; + + // Test 2: Lenient type (AnyRpcBlock) - should always work via Unknown fallback + let any_result = serde_json::from_value::(value.clone()); + let any_status = match &any_result { + Ok(block) => format!("OK txs={}", block.transactions.len()), + Err(e) => format!("FAIL err={}", e), + }; + + // Log both results together + if strict_result.is_ok() && any_result.is_ok() { + debug!( + logger, + "alloy_compat block={} hash={} strict={} any={}", + block_num, + block_hash, + strict_status, + any_status + ); + } else { + warn!( + logger, + "alloy_compat block={} hash={} strict={} any={}", + block_num, + block_hash, + strict_status, + any_status + ); + } +} + #[derive(Debug, Clone)] pub struct EthereumAdapter { logger: Logger, @@ -1704,7 +1761,11 @@ impl EthereumAdapterTrait for EthereumAdapter { .map_err(|e| error!(&logger, "Error accessing block cache {}", e)) .unwrap_or_default() .into_iter() - .filter_map(|value| json::from_value(value).ok()) + .filter_map(|value| { + // Test alloy deserialization compatibility + test_alloy_block_compat(&logger, &value); + json::from_value(value).ok() + }) .map(Arc::new) .collect(); From 9a71bc0b0255dd65bb03e1be1f8d0a1bb2eae4e2 Mon Sep 17 00:00:00 2001 From: incrypto32 Date: Wed, 21 Jan 2026 10:46:15 +0400 Subject: [PATCH 06/10] log receipts stuff --- chain/ethereum/src/chain.rs | 16 ++++++-- chain/ethereum/src/ethereum_adapter.rs | 56 +++++++++++++++++++++++++- 2 files changed, 67 insertions(+), 5 deletions(-) diff --git a/chain/ethereum/src/chain.rs b/chain/ethereum/src/chain.rs index 35c155b9c0f..babef3f7321 100644 --- a/chain/ethereum/src/chain.rs +++ b/chain/ethereum/src/chain.rs @@ -56,7 +56,7 @@ use crate::{ data_source::{DataSource, UnresolvedDataSource}, ethereum_adapter::{ blocks_with_triggers, get_calls, parse_block_triggers, parse_call_triggers, - parse_log_triggers, + parse_log_triggers, test_alloy_block_compat, test_alloy_receipts_compat, }, SubgraphEthRpcMetrics, TriggerFilter, ENV_VARS, }; @@ -1049,7 +1049,12 @@ impl TriggersAdapterTrait for TriggersAdapter { .ancestor_block(ptr, offset, root) .await? .map(|x| x.0) - .map(json::from_value) + .map(|value| { + // Test alloy deserialization compatibility + test_alloy_block_compat(&self.logger, &value); + test_alloy_receipts_compat(&self.logger, &value); + json::from_value(value) + }) .transpose()?; Ok(block.map(|block| { BlockFinality::NonFinal(EthereumBlockWithCalls { @@ -1067,8 +1072,11 @@ impl TriggersAdapterTrait for TriggersAdapter { let chain_store = self.chain_store.cheap_clone(); // First try to get the block from the store if let Ok(blocks) = chain_store.blocks(vec![block.hash.clone()]).await { - if let Some(block) = blocks.first() { - if let Ok(block) = json::from_value::(block.clone()) { + if let Some(value) = blocks.first() { + // Test alloy deserialization compatibility + test_alloy_block_compat(&self.logger, value); + test_alloy_receipts_compat(&self.logger, value); + if let Ok(block) = json::from_value::(value.clone()) { return Ok(block.parent_ptr()); } } diff --git a/chain/ethereum/src/ethereum_adapter.rs b/chain/ethereum/src/ethereum_adapter.rs index 73c6f1f6073..a196531d0b9 100644 --- a/chain/ethereum/src/ethereum_adapter.rs +++ b/chain/ethereum/src/ethereum_adapter.rs @@ -1,5 +1,6 @@ use alloy::network::AnyRpcBlock; use alloy::rpc::types::Block as AlloyRpcBlock; +use alloy::rpc::types::TransactionReceipt as AlloyReceipt; use futures03::{future::BoxFuture, stream::FuturesUnordered}; use graph::blockchain::client::ChainClient; use graph::blockchain::BlockHash; @@ -82,7 +83,7 @@ use crate::{ /// Tests two types: /// 1. AlloyRpcBlock (strict) - uses TxEnvelope, requires chainId for typed transactions /// 2. AnyRpcBlock (lenient) - uses AnyTxEnvelope with fallback to Unknown variant -fn test_alloy_block_compat(logger: &Logger, value: &json::Value) { +pub(crate) fn test_alloy_block_compat(logger: &Logger, value: &json::Value) { // Extract block number/hash for logging before attempting deserialization let block_num = value .get("number") @@ -130,6 +131,58 @@ fn test_alloy_block_compat(logger: &Logger, value: &json::Value) { } } +/// Test alloy deserialization compatibility with receipts from block cache. +/// Extracts transaction_receipts from the block JSON and tests each with alloy. +pub(crate) fn test_alloy_receipts_compat(logger: &Logger, block_value: &json::Value) { + let block_num = block_value + .get("number") + .and_then(|v| v.as_str()) + .unwrap_or("unknown"); + + let receipts = match block_value.get("transaction_receipts") { + Some(json::Value::Array(arr)) if !arr.is_empty() => arr, + _ => { + debug!( + logger, + "alloy_compat_receipts block={} no_receipts_to_test", block_num + ); + return; + } + }; + + let mut ok_count = 0; + let mut fail_count = 0; + let mut first_error: Option = None; + + for receipt in receipts { + match serde_json::from_value::(receipt.clone()) { + Ok(_) => ok_count += 1, + Err(e) => { + fail_count += 1; + if first_error.is_none() { + first_error = Some(e.to_string()); + } + } + } + } + + if fail_count > 0 { + warn!( + logger, + "alloy_compat_receipts block={} ok={} fail={} first_err={}", + block_num, + ok_count, + fail_count, + first_error.unwrap_or_default() + ); + } else { + debug!( + logger, + "alloy_compat_receipts block={} ok={}", block_num, ok_count + ); + } +} + #[derive(Debug, Clone)] pub struct EthereumAdapter { logger: Logger, @@ -1764,6 +1817,7 @@ impl EthereumAdapterTrait for EthereumAdapter { .filter_map(|value| { // Test alloy deserialization compatibility test_alloy_block_compat(&logger, &value); + test_alloy_receipts_compat(&logger, &value); json::from_value(value).ok() }) .map(Arc::new) From 10934c9cbb45df052244dd1dacdd0d56ff49079e Mon Sep 17 00:00:00 2001 From: incrypto32 Date: Thu, 22 Jan 2026 17:31:21 +0400 Subject: [PATCH 07/10] improve_alloy_compat_logs --- chain/ethereum/src/chain.rs | 8 +- chain/ethereum/src/ethereum_adapter.rs | 105 ++++++++++++++++++++----- 2 files changed, 88 insertions(+), 25 deletions(-) diff --git a/chain/ethereum/src/chain.rs b/chain/ethereum/src/chain.rs index babef3f7321..a31a6cd6669 100644 --- a/chain/ethereum/src/chain.rs +++ b/chain/ethereum/src/chain.rs @@ -1051,8 +1051,8 @@ impl TriggersAdapterTrait for TriggersAdapter { .map(|x| x.0) .map(|value| { // Test alloy deserialization compatibility - test_alloy_block_compat(&self.logger, &value); - test_alloy_receipts_compat(&self.logger, &value); + test_alloy_block_compat(&self.logger, &value, "ancestor_block"); + test_alloy_receipts_compat(&self.logger, &value, "ancestor_block"); json::from_value(value) }) .transpose()?; @@ -1074,8 +1074,8 @@ impl TriggersAdapterTrait for TriggersAdapter { if let Ok(blocks) = chain_store.blocks(vec![block.hash.clone()]).await { if let Some(value) = blocks.first() { // Test alloy deserialization compatibility - test_alloy_block_compat(&self.logger, value); - test_alloy_receipts_compat(&self.logger, value); + test_alloy_block_compat(&self.logger, value, "parent_ptr"); + test_alloy_receipts_compat(&self.logger, value, "parent_ptr"); if let Ok(block) = json::from_value::(value.clone()) { return Ok(block.parent_ptr()); } diff --git a/chain/ethereum/src/ethereum_adapter.rs b/chain/ethereum/src/ethereum_adapter.rs index a196531d0b9..e1c8ec916b2 100644 --- a/chain/ethereum/src/ethereum_adapter.rs +++ b/chain/ethereum/src/ethereum_adapter.rs @@ -83,27 +83,62 @@ use crate::{ /// Tests two types: /// 1. AlloyRpcBlock (strict) - uses TxEnvelope, requires chainId for typed transactions /// 2. AnyRpcBlock (lenient) - uses AnyTxEnvelope with fallback to Unknown variant -pub(crate) fn test_alloy_block_compat(logger: &Logger, value: &json::Value) { - // Extract block number/hash for logging before attempting deserialization - let block_num = value +/// +/// `source` indicates which code path called this (e.g., "load_blocks", "ancestor_block", "parent_ptr") +pub(crate) fn test_alloy_block_compat(logger: &Logger, value: &json::Value, source: &str) { + // Check if we received wrapper format or inner block directly + let is_wrapper = value.get("block").is_some(); + let format = if is_wrapper { "wrapper" } else { "inner" }; + let inner_block = value.get("block").unwrap_or(value); + + // Extract block number/hash from the inner block + let block_num = inner_block .get("number") .and_then(|v| v.as_str()) .unwrap_or("unknown"); - let block_hash = value + let full_hash = inner_block .get("hash") .and_then(|v| v.as_str()) - .map(|s| &s[..std::cmp::min(18, s.len())]) .unwrap_or("unknown"); + // Debug: if both are unknown, log detailed info to help find in database + if block_num == "unknown" && full_hash == "unknown" { + let outer_keys: Vec<&str> = value + .as_object() + .map(|obj| obj.keys().map(|k| k.as_str()).collect()) + .unwrap_or_default(); + let inner_keys: Vec<&str> = inner_block + .as_object() + .map(|obj| obj.keys().map(|k| k.as_str()).collect()) + .unwrap_or_default(); + // Truncate JSON preview to avoid huge logs + let json_preview = inner_block.to_string(); + let json_preview = if json_preview.len() > 500 { + format!("{}...", &json_preview[..500]) + } else { + json_preview + }; + warn!( + logger, + "alloy_compat unexpected JSON structure"; + "source" => source, + "format" => format, + "outer_keys" => format!("{:?}", outer_keys), + "inner_keys" => format!("{:?}", inner_keys), + "json_preview" => json_preview + ); + return; // Skip further testing since structure is unexpected + } + // Test 1: Strict type (AlloyRpcBlock) - will fail for blocks with typed txns missing chainId - let strict_result = serde_json::from_value::(value.clone()); + let strict_result = serde_json::from_value::(inner_block.clone()); let strict_status = match &strict_result { Ok(block) => format!("OK txs={}", block.transactions.len()), Err(e) => format!("FAIL err={}", e), }; // Test 2: Lenient type (AnyRpcBlock) - should always work via Unknown fallback - let any_result = serde_json::from_value::(value.clone()); + let any_result = serde_json::from_value::(inner_block.clone()); let any_status = match &any_result { Ok(block) => format!("OK txs={}", block.transactions.len()), Err(e) => format!("FAIL err={}", e), @@ -113,38 +148,58 @@ pub(crate) fn test_alloy_block_compat(logger: &Logger, value: &json::Value) { if strict_result.is_ok() && any_result.is_ok() { debug!( logger, - "alloy_compat block={} hash={} strict={} any={}", + "alloy_compat path={} format={} block={} strict={} any={}", + source, + format, block_num, - block_hash, strict_status, - any_status + any_status; + "hash" => full_hash ); } else { warn!( logger, - "alloy_compat block={} hash={} strict={} any={}", + "alloy_compat path={} format={} block={} strict={} any={}", + source, + format, block_num, - block_hash, strict_status, - any_status + any_status; + "hash" => full_hash ); } } /// Test alloy deserialization compatibility with receipts from block cache. /// Extracts transaction_receipts from the block JSON and tests each with alloy. -pub(crate) fn test_alloy_receipts_compat(logger: &Logger, block_value: &json::Value) { - let block_num = block_value +/// +/// `source` indicates which code path called this (e.g., "load_blocks", "ancestor_block", "parent_ptr") +pub(crate) fn test_alloy_receipts_compat(logger: &Logger, block_value: &json::Value, source: &str) { + // Check if we received wrapper format or inner block directly + let is_wrapper = block_value.get("block").is_some(); + let format = if is_wrapper { "wrapper" } else { "inner" }; + let inner_block = block_value.get("block").unwrap_or(block_value); + + let block_num = inner_block .get("number") .and_then(|v| v.as_str()) .unwrap_or("unknown"); + let full_hash = inner_block + .get("hash") + .and_then(|v| v.as_str()) + .unwrap_or("unknown"); + // Receipts are at the outer level in EthereumBlock format let receipts = match block_value.get("transaction_receipts") { Some(json::Value::Array(arr)) if !arr.is_empty() => arr, _ => { debug!( logger, - "alloy_compat_receipts block={} no_receipts_to_test", block_num + "alloy_compat_receipts path={} format={} block={} no_receipts_to_test", + source, + format, + block_num; + "hash" => full_hash ); return; } @@ -169,16 +224,24 @@ pub(crate) fn test_alloy_receipts_compat(logger: &Logger, block_value: &json::Va if fail_count > 0 { warn!( logger, - "alloy_compat_receipts block={} ok={} fail={} first_err={}", + "alloy_compat_receipts path={} format={} block={} ok={} fail={} first_err={}", + source, + format, block_num, ok_count, fail_count, - first_error.unwrap_or_default() + first_error.unwrap_or_default(); + "hash" => full_hash ); } else { debug!( logger, - "alloy_compat_receipts block={} ok={}", block_num, ok_count + "alloy_compat_receipts path={} format={} block={} ok={}", + source, + format, + block_num, + ok_count; + "hash" => full_hash ); } } @@ -1816,8 +1879,8 @@ impl EthereumAdapterTrait for EthereumAdapter { .into_iter() .filter_map(|value| { // Test alloy deserialization compatibility - test_alloy_block_compat(&logger, &value); - test_alloy_receipts_compat(&logger, &value); + test_alloy_block_compat(&logger, &value, "load_blocks"); + test_alloy_receipts_compat(&logger, &value, "load_blocks"); json::from_value(value).ok() }) .map(Arc::new) From 543af6ec9488bed16a49da4013ba327445d13661 Mon Sep 17 00:00:00 2001 From: incrypto32 Date: Tue, 27 Jan 2026 17:27:38 +0400 Subject: [PATCH 08/10] alloy compat logs --- chain/ethereum/src/ethereum_adapter.rs | 152 +++++++++++++++++-------- 1 file changed, 106 insertions(+), 46 deletions(-) diff --git a/chain/ethereum/src/ethereum_adapter.rs b/chain/ethereum/src/ethereum_adapter.rs index e1c8ec916b2..53cdbed355d 100644 --- a/chain/ethereum/src/ethereum_adapter.rs +++ b/chain/ethereum/src/ethereum_adapter.rs @@ -1,4 +1,5 @@ use alloy::network::AnyRpcBlock; +use alloy::network::AnyTransactionReceipt; use alloy::rpc::types::Block as AlloyRpcBlock; use alloy::rpc::types::TransactionReceipt as AlloyReceipt; use futures03::{future::BoxFuture, stream::FuturesUnordered}; @@ -132,41 +133,56 @@ pub(crate) fn test_alloy_block_compat(logger: &Logger, value: &json::Value, sour // Test 1: Strict type (AlloyRpcBlock) - will fail for blocks with typed txns missing chainId let strict_result = serde_json::from_value::(inner_block.clone()); - let strict_status = match &strict_result { - Ok(block) => format!("OK txs={}", block.transactions.len()), - Err(e) => format!("FAIL err={}", e), - }; + match &strict_result { + Ok(block) => { + debug!( + logger, + "alloy_compat_strict path={} format={} block={} OK txs={}", + source, + format, + block_num, + block.transactions.len(); + "hash" => full_hash + ); + } + Err(e) => { + warn!( + logger, + "alloy_compat_strict path={} format={} block={} FAIL err={}", + source, + format, + block_num, + e; + "hash" => full_hash + ); + } + } // Test 2: Lenient type (AnyRpcBlock) - should always work via Unknown fallback let any_result = serde_json::from_value::(inner_block.clone()); - let any_status = match &any_result { - Ok(block) => format!("OK txs={}", block.transactions.len()), - Err(e) => format!("FAIL err={}", e), - }; - - // Log both results together - if strict_result.is_ok() && any_result.is_ok() { - debug!( - logger, - "alloy_compat path={} format={} block={} strict={} any={}", - source, - format, - block_num, - strict_status, - any_status; - "hash" => full_hash - ); - } else { - warn!( - logger, - "alloy_compat path={} format={} block={} strict={} any={}", - source, - format, - block_num, - strict_status, - any_status; - "hash" => full_hash - ); + match &any_result { + Ok(block) => { + debug!( + logger, + "alloy_compat_any path={} format={} block={} OK txs={}", + source, + format, + block_num, + block.transactions.len(); + "hash" => full_hash + ); + } + Err(e) => { + warn!( + logger, + "alloy_compat_any path={} format={} block={} FAIL err={}", + source, + format, + block_num, + e; + "hash" => full_hash + ); + } } } @@ -205,42 +221,86 @@ pub(crate) fn test_alloy_receipts_compat(logger: &Logger, block_value: &json::Va } }; - let mut ok_count = 0; - let mut fail_count = 0; - let mut first_error: Option = None; + // Test with strict AlloyReceipt (TransactionReceipt) + let mut strict_ok = 0; + let mut strict_fail = 0; + let mut strict_first_error: Option = None; + + // Test with lenient AnyTransactionReceipt + let mut any_ok = 0; + let mut any_fail = 0; + let mut any_first_error: Option = None; for receipt in receipts { + // Strict test match serde_json::from_value::(receipt.clone()) { - Ok(_) => ok_count += 1, + Ok(_) => strict_ok += 1, + Err(e) => { + strict_fail += 1; + if strict_first_error.is_none() { + strict_first_error = Some(e.to_string()); + } + } + } + + // Lenient test + match serde_json::from_value::(receipt.clone()) { + Ok(_) => any_ok += 1, Err(e) => { - fail_count += 1; - if first_error.is_none() { - first_error = Some(e.to_string()); + any_fail += 1; + if any_first_error.is_none() { + any_first_error = Some(e.to_string()); } } } } - if fail_count > 0 { + // Log strict results + if strict_fail > 0 { + warn!( + logger, + "alloy_compat_receipts_strict path={} format={} block={} ok={} fail={} first_err={}", + source, + format, + block_num, + strict_ok, + strict_fail, + strict_first_error.unwrap_or_default(); + "hash" => full_hash + ); + } else { + debug!( + logger, + "alloy_compat_receipts_strict path={} format={} block={} ok={}", + source, + format, + block_num, + strict_ok; + "hash" => full_hash + ); + } + + // Log lenient results + if any_fail > 0 { warn!( logger, - "alloy_compat_receipts path={} format={} block={} ok={} fail={} first_err={}", + "alloy_compat_receipts_any path={} format={} block={} ok={} fail={} first_err={}", source, format, block_num, - ok_count, - fail_count, - first_error.unwrap_or_default(); + any_ok, + any_fail, + any_first_error.unwrap_or_default(); "hash" => full_hash ); } else { debug!( logger, - "alloy_compat_receipts path={} format={} block={} ok={}", + "alloy_compat_receipts_any path={} format={} block={} ok={}", source, format, block_num, - ok_count; + any_ok; "hash" => full_hash ); } From 8d1835568e46f961c2c7c419d395bc525b95d7e8 Mon Sep 17 00:00:00 2001 From: incrypto32 Date: Wed, 28 Jan 2026 15:58:54 +0400 Subject: [PATCH 09/10] Add failed to deserialize logs --- chain/ethereum/src/chain.rs | 40 ++++++++++++++++++++++++-- chain/ethereum/src/ethereum_adapter.rs | 19 +++++++++++- 2 files changed, 55 insertions(+), 4 deletions(-) diff --git a/chain/ethereum/src/chain.rs b/chain/ethereum/src/chain.rs index a31a6cd6669..991637b0b47 100644 --- a/chain/ethereum/src/chain.rs +++ b/chain/ethereum/src/chain.rs @@ -1053,7 +1053,23 @@ impl TriggersAdapterTrait for TriggersAdapter { // Test alloy deserialization compatibility test_alloy_block_compat(&self.logger, &value, "ancestor_block"); test_alloy_receipts_compat(&self.logger, &value, "ancestor_block"); - json::from_value(value) + + json::from_value(value.clone()).map_err(|e| { + // Extract block info from inner block if wrapper format + let inner = value.get("block").unwrap_or(&value); + let block_num = inner.get("number").and_then(|n| n.as_str()); + let block_hash = inner.get("hash").and_then(|h| h.as_str()); + warn!( + self.logger, + "Failed to deserialize cached ancestor block #{:?} {:?}: {}. \ + This may indicate stale cache data from a previous version. \ + Block will be re-fetched.", + block_num, + block_hash, + e + ); + e + }) }) .transpose()?; Ok(block.map(|block| { @@ -1076,8 +1092,26 @@ impl TriggersAdapterTrait for TriggersAdapter { // Test alloy deserialization compatibility test_alloy_block_compat(&self.logger, value, "parent_ptr"); test_alloy_receipts_compat(&self.logger, value, "parent_ptr"); - if let Ok(block) = json::from_value::(value.clone()) { - return Ok(block.parent_ptr()); + + match json::from_value::(value.clone()) { + Ok(block) => { + return Ok(block.parent_ptr()); + } + Err(e) => { + // Extract block info from inner block if wrapper format + let inner = value.get("block").unwrap_or(value); + let block_num = inner.get("number").and_then(|n| n.as_str()); + let block_hash = inner.get("hash").and_then(|h| h.as_str()); + warn!( + self.logger, + "Failed to deserialize cached block #{:?} {:?}: {}. \ + This may indicate stale cache data from a previous version. \ + Falling back to Firehose.", + block_num, + block_hash, + e + ); + } } } } diff --git a/chain/ethereum/src/ethereum_adapter.rs b/chain/ethereum/src/ethereum_adapter.rs index 53cdbed355d..1c424d620ba 100644 --- a/chain/ethereum/src/ethereum_adapter.rs +++ b/chain/ethereum/src/ethereum_adapter.rs @@ -1941,7 +1941,24 @@ impl EthereumAdapterTrait for EthereumAdapter { // Test alloy deserialization compatibility test_alloy_block_compat(&logger, &value, "load_blocks"); test_alloy_receipts_compat(&logger, &value, "load_blocks"); - json::from_value(value).ok() + + json::from_value(value.clone()) + .map_err(|e| { + // Extract block info from inner block if wrapper format + let inner = value.get("block").unwrap_or(&value); + let block_num = inner.get("number").and_then(|n| n.as_str()); + let block_hash = inner.get("hash").and_then(|h| h.as_str()); + warn!( + &logger, + "Failed to deserialize cached block #{:?} {:?}: {}. \ + This may indicate stale cache data from a previous version. \ + Block will be re-fetched from RPC.", + block_num, + block_hash, + e + ); + }) + .ok() }) .map(Arc::new) .collect(); From 6a4fea91e4a8e35f4667340f029fb45ca164532d Mon Sep 17 00:00:00 2001 From: incrypto32 Date: Fri, 8 May 2026 16:32:50 +0530 Subject: [PATCH 10/10] Log block details on "Found no transaction for event" error --- chain/ethereum/src/data_source.rs | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/chain/ethereum/src/data_source.rs b/chain/ethereum/src/data_source.rs index 68a6f2371b9..987ebe50f1a 100644 --- a/chain/ethereum/src/data_source.rs +++ b/chain/ethereum/src/data_source.rs @@ -794,7 +794,20 @@ impl DataSource { // and is not a special zero hash, implying a real transaction associated with this log. block .transaction_for_log(&log) - .context("Found no transaction for event")? + .with_context(|| { + let tx_count = block.transactions.len(); + let first_tx = block.transactions.first().map(|t| t.hash); + let last_tx = block.transactions.last().map(|t| t.hash); + format!( + "Found no transaction for event. \ + log_tx_hash={:?}, log_block_hash={:?}, \ + block_hash={:?}, block_number={:?}, \ + block_tx_count={}, first_tx={:?}, last_tx={:?}", + log.transaction_hash, log.block_hash, + block.hash, block.number, + tx_count, first_tx, last_tx + ) + })? }; let logging_extras = Arc::new(o! {