Skip to content

Commit d655f60

Browse files
committed
all: address bugs in auto-graft from v0.24.2 release
1 parent 9768bb2 commit d655f60

File tree

16 files changed

+135
-28
lines changed

16 files changed

+135
-28
lines changed

CLAUDE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ Tests require:
131131
```
132132

133133
## Current State
134-
- Version: v0.24.2
134+
- Version: v0.24.3
135135
- Active branch: release-v0.24
136136
- Main branch: main
137137
- Uncommitted changes in docs/ and config/

docs/auto-graft.md

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,30 @@
22

33
## Quick Start
44

5-
Auto-graft automatically handles subgraph dependencies when deploying grafted subgraphs. It requires an IPFS endpoint to fetch dependency manifests.
5+
Auto-graft automatically handles subgraph dependencies when deploying grafted subgraphs. It requires an IPFS endpoint to fetch dependency manifests and must be explicitly enabled.
66

77
### Prerequisites
88

9-
**Required Configuration - IPFS Endpoint:**
9+
**Required Configuration:**
1010

11+
1. **Enable Auto-Graft (New in v0.24.3):**
12+
```bash
13+
# Option 1: Command-line argument
14+
graph-indexer-agent start --enable-auto-graft
15+
16+
# Option 2: Environment variable
17+
export INDEXER_AGENT_ENABLE_AUTO_GRAFT=true
18+
```
19+
Default: `false` (disabled - must be explicitly enabled)
20+
21+
2. **IPFS Endpoint:**
1122
```bash
1223
# Option 1: Environment variable
1324
export INDEXER_AGENT_IPFS_ENDPOINT=https://ipfs.thegraph.com
1425

1526
# Option 2: Command-line argument
1627
graph-indexer-agent start --ipfs-endpoint https://ipfs.thegraph.com
1728
```
18-
1929
Default: `https://ipfs.network.thegraph.com` (if not specified)
2030

2131
## Introduction
@@ -62,11 +72,12 @@ Before using auto-graft, ensure you have:
6272

6373
- **Graph Node**: Running with grafting support enabled (grafting is supported on all networks)
6474
- **IPFS Access**: The indexer must be able to fetch subgraph manifests from IPFS (configured via `--ipfs-endpoint` or `INDEXER_AGENT_IPFS_ENDPOINT` environment variable)
75+
- **Auto-Graft Enabled**: Starting from v0.24.3, auto-graft must be explicitly enabled via `--enable-auto-graft` flag or `INDEXER_AGENT_ENABLE_AUTO_GRAFT=true`
6576
- **Indexer Infrastructure**: Standard indexer setup with indexer-agent and indexer-service
6677

6778
## Using Auto-Graft
6879

69-
The beauty of auto-graft is that it requires no configuration or special commands. Simply deploy your grafted subgraph as you would any other subgraph, and auto-graft handles the rest.
80+
Once enabled with the `--enable-auto-graft` flag, auto-graft requires no additional configuration or special commands. Simply deploy your grafted subgraph as you would any other subgraph, and auto-graft handles the rest.
7081

7182
### Example Subgraph Manifest with Graft
7283

@@ -170,7 +181,7 @@ When a dependency reaches its target block, auto-graft will:
170181
- Continue indexing past the graft point to ensure the dependency remains available
171182
- Allow the main subgraph to successfully graft from this dependency
172183

173-
*Note: Prior to v0.24.2, dependencies were automatically paused after reaching their target block. This behavior was removed to ensure better availability and prevent issues with allocations.*
184+
*Note: Prior to v0.24.3, auto-graft was enabled by default when an IPFS endpoint was configured. Starting from v0.24.3, it must be explicitly enabled with the `--enable-auto-graft` flag.*
174185

175186
## Monitoring Auto-Graft
176187

docs/networks/arbitrum-sepolia.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ The Graph Network's testnet is on Arbitrum Sepolia (eip155:421614). Sepolia netw
77
| Component | Release |
88
| ------------------ | ------------------------------------------------------------------------------------ |
99
| contracts | [5.3.3](https://github.com/graphprotocol/contracts/releases/tag/v5.3.3) |
10-
| indexer-agent | [0.24.2](https://github.com/graphprotocol/indexer/releases/tag/v0.24.2) |
11-
| indexer-cli | [0.24.2](https://github.com/graphprotocol/indexer/releases/tag/v0.24.2) |
10+
| indexer-agent | [0.24.3](https://github.com/graphprotocol/indexer/releases/tag/v0.24.3) |
11+
| indexer-cli | [0.24.3](https://github.com/graphprotocol/indexer/releases/tag/v0.24.3) |
1212
| indexer-service-rs | [1.0.0](https://github.com/graphprotocol/indexer-rs/releases/tag/v1.0.0) |
1313
| tap-agent | [1.0.0](https://github.com/graphprotocol/indexer-rs/releases/tag/v1.0.0) |
1414
| graph-node | [0.35.1](https://github.com/graphprotocol/graph-node/releases/tag/v0.35.1) |

lerna.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@
44
],
55
"npmClient": "yarn",
66
"useWorkspaces": true,
7-
"version": "0.24.2"
7+
"version": "0.24.3"
88
}

packages/indexer-agent/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@graphprotocol/indexer-agent",
3-
"version": "0.24.2",
3+
"version": "0.24.3",
44
"description": "Indexer agent",
55
"main": "./dist/index.js",
66
"types": "./dist/index.d.ts",
@@ -30,7 +30,7 @@
3030
},
3131
"dependencies": {
3232
"@graphprotocol/common-ts": "2.0.11",
33-
"@graphprotocol/indexer-common": "^0.24.2",
33+
"@graphprotocol/indexer-common": "^0.24.3",
3434
"@thi.ng/heaps": "^1.3.1",
3535
"axios": "0.26.1",
3636
"bs58": "5.0.0",

packages/indexer-agent/src/__tests__/indexer.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,7 @@ const setup = async () => {
140140
'https://test-query-endpoint.xyz',
141141
'https://test-status-endpoint.xyz',
142142
'https://test-ipfs-endpoint.xyz',
143+
false, // disable auto-graft for tests
143144
)
144145

145146
const yamlObj = loadTestYamlConfig()

packages/indexer-agent/src/commands/common-options.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,14 @@ export function injectCommonStartupOptions(argv: Argv): Argv {
108108
group: 'Indexer Infrastructure',
109109
default: 'https://ipfs.network.thegraph.com',
110110
})
111+
.option('enable-auto-graft', {
112+
description:
113+
'Automatically deploy and sync graft dependencies for subgraphs',
114+
type: 'boolean',
115+
required: false,
116+
group: 'Indexer Infrastructure',
117+
default: false,
118+
})
111119
.option('graph-node-query-endpoint', {
112120
description: 'Graph Node endpoint for querying subgraphs',
113121
type: 'string',

packages/indexer-agent/src/commands/start.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -503,6 +503,7 @@ export async function run(
503503
argv.graphNodeQueryEndpoint,
504504
argv.graphNodeStatusEndpoint,
505505
argv.ipfsEndpoint,
506+
argv.enableAutoGraft,
506507
)
507508

508509
// --------------------------------------------------------------------------------

packages/indexer-cli/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@graphprotocol/indexer-cli",
3-
"version": "0.24.2",
3+
"version": "0.24.3",
44
"description": "Indexer CLI for The Graph Network",
55
"main": "./dist/cli.js",
66
"files": [
@@ -27,7 +27,7 @@
2727
},
2828
"dependencies": {
2929
"@graphprotocol/common-ts": "2.0.11",
30-
"@graphprotocol/indexer-common": "^0.24.2",
30+
"@graphprotocol/indexer-common": "^0.24.3",
3131
"@iarna/toml": "2.2.5",
3232
"@thi.ng/iterators": "5.1.74",
3333
"@urql/core": "3.1.0",

packages/indexer-common/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@graphprotocol/indexer-common",
3-
"version": "0.24.2",
3+
"version": "0.24.3",
44
"description": "Common library for Graph Protocol indexer components",
55
"main": "./dist/index.js",
66
"types": "./dist/index.d.ts",

0 commit comments

Comments
 (0)