You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This subgraph is failing with the error below during initialisation.
✖ Failed to create subgraph scaffold: ',' expected. (3:41)
1 |
2 | import { assert, describe, test, clearStore, beforeAll, afterAll } from "matchstick-as/assembly/index"
> 3 | import { Bytes, Address, BigInt, Array<Bytes } from "@graphprotocol/graph-ts"
| ^
4 | import { AddNomineeHash } from "../generated/schema"
5 | import { AddNomineeHash as AddNomineeHashEvent } from "../generated/Contract/Contract"
6 | import { handleAddNomineeHash } from "../src/contract"
SyntaxError: ',' expected. (3:41)
1 |
2 | import { assert, describe, test, clearStore, beforeAll, afterAll } from "matchstick-as/assembly/index"
> 3 | import { Bytes, Address, BigInt, Array<Bytes } from "@graphprotocol/graph-ts"
| ^
4 | import { AddNomineeHash } from "../generated/schema"
5 | import { AddNomineeHash as AddNomineeHashEvent } from "../generated/Contract/Contract"
6 | import { handleAddNomineeHash } from "../src/contract"
@shiyasmohd came up with a workaround where you change the input type in the abi temporarily from uint256[][] to uint256[] and then after the initialisation process or contract is added with the modified abi, you then change the input type back to its initial types, then running graph codegen .
itsjerryokolo
changed the title
graph-cli failing to generate types for multi-dimensional arrays
graph-cli failing to generate types for multi-dimensional arrays on graph init and graph add
Jul 30, 2024
Which packages are impacted by your issue?
@graphprotocol/graph-cli
Describe the issue
This subgraph is failing with the error below during initialisation.
@shiyasmohd came up with a workaround where you change the input type in the abi temporarily from
uint256[][]
touint256[]
and then after the initialisation process or contract is added with the modified abi, you then change the input type back to its initial types, then runninggraph codegen
.Reproduction
https://github.com/itsjerryokolo/autonolas-subgraph
Steps to Reproduce the Bug or Issue
Initialise a subgraph using this contract: 0x5650300fCBab43A0D7D02F8Cb5d0f039402593f0.
Expected behavior
Initialisation process should be successful.
Screenshots or Videos
No response
Platform
nil
Subgraph Manifest
No response
Subgraph GraphQL Schema
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: