graphprotocol / graphprotocol/graph-node
[Bug] graphman sometimes creates the wrong index
Offen
@incrypto32 arbeitet bereits daran.
Seit 10.1.2024.
bug
- Vorherrschende Sprache
- Rust
- Sterne
- 3.2k
- Forks
- 1.1k
- Ø Merge
- 4 T. 1 Std.
- Gemergte PRs (30 T.)
- 1
Beschreibung
Bug report
The following graphman command resulted in an unexpected index:
graphman index create sgd647572 pool_hour_data pool
Index creation started. Please wait.
Index creation completed.
Listing information about the table in the DB showed the following index having been created:
=> \d sgd647572.pool_hour_data
Table "sgd647572.pool_hour_data"
Column | Type | Collation | Nullable | Default
-------------------------+-----------+-----------+----------+-------------------------------------------------------
vid | bigint | | not null | nextval('sgd647572.pool_hour_data_vid_seq'::regclass)
block_range | int4range | | not null |
id | text | | not null |
period_start_unix | integer | | not null |
pool | text | | not null |
[...]
Indexes:
"pool_hour_data_pkey" PRIMARY KEY, btree (vid)
"attr_15_0_pool_hour_data_id" btree (id)
[...]
"attr_15_9_pool_hour_data_fee_growth_global_1x128" btree (fee_growth_global_1x128)
"brin_pool_hour_data" brin (lower(block_range) int4_minmax_multi_ops, COALESCE(upper(block_range), 2147483647) int4_minmax_multi_ops, vid int8_minmax_multi_ops)
"manual_pool_hour_data_pool" btree (pool, block_range)
"pool_hour_data_block_range_closed" btree (COALESCE(upper(block_range), 2147483647)) WHERE COALESCE(upper(block_range), 2147483647) < 2147483647
"pool_hour_data_id_block_range_excl" gist (id, block_range)
I saw this behaviour earlier on other SGs as well, in one case on a token table.
Relevant log output
No response
IPFS hash
QmZeCuoZeadgHkGwLwMeguyqUKz1WPWQYKcKyMCeQqGhsF
Subgraph name or link to explorer
No response
Some information to help us out
- Tick this box if this bug is caused by a regression found in the latest release.
- Tick this box if this bug is specific to the hosted service.
- I have searched the issue tracker to make sure this issue is not a duplicate.
OS information
None
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Bewertung
Dieses Issue wurde noch nicht bewertet.