yarn
This repository uses Matchstick for subgraph testing.
- PostgreSQL 14 must be installed and running on your machine. Matchstick requires this for its testing environment.
Tests are available for select packages and can be run using the following commands:
# Run tests for all packages with test suites
yarn test
# Run tests in parallel (faster)
yarn test:parallel
# Run full CI pipeline (prepare and test)
yarn ci
The yarn test
command runs tests for the following packages (when available):
managed-optimistic-oracle-v2-subgraph
optimistic-oracle-subgraph
optimistic-oracle-v2-subgraph
optimistic-oracle-v3-subgraph
skinny-optimistic-oracle-subgraph
votingV2-subgraph
To run tests for a specific package, navigate to the package directory and run yarn test
or graph test
directly.
This subgraph indexes events emitted by the core Oracle contracts. The code can be found in packages/voting
- Mainnet
- (testnet) Sepolia
This subgraph indexes events emitted by the "Skinny Optimistic Oracle" contracts. The code can be found in packages/skinny-optimistic-oracle
- Mainnet
- TheGraph: https://thegraph.com/studio/subgraph/mainnet-skinny-oo
- Goldsky:
- (testnet) Sepolia
- TheGraph: https://thegraph.com/studio/subgraph/sepolia-skinny-oo
- Goldsky:
This subgraph indexes events emitted by the "Optimistic Oracle" contracts. The code can be found in packages/optimistic-oracle
- Mainnet
- TheGraph: https://thegraph.com/studio/subgraph/mainnet-optimistic-oracle
- Goldsky:
- Polygon
- TheGraph: https://thegraph.com/studio/subgraph/polygon-optimistic-oracle
- Goldsky:
- Arbitrum
- TheGraph: https://thegraph.com/studio/subgraph/arbitrum-optimistic-oracle
- Goldsky:
- Optimism
- TheGraph: https://thegraph.com/studio/subgraph/optimism-optimistic-oracle
- Goldsky:
- Boba
- TheGraph: https://thegraph.com/studio/subgraph/boba-optimistic-oracle
- Goldsky:
- (staging) Goerli
- TheGraph: https://thegraph.com/hosted-service/subgraph/md0x/goerli-optimistic-oracle
- Goldsky:
- (staging) Core Testnet
- Core
- (testnet) Sepolia
- TheGraph: https://thegraph.com/studio/subgraph/sepolia-optimistic-oracle
- Goldsky:
- Base
- TheGraph: https://thegraph.com/studio/subgraph/base-optimistic-oracle
- Goldsky:
- Blast
- TheGraph: https://thegraph.com/studio/subgraph/blast-optimistic-oracle
- Goldsky:
- Story
This subgraph indexes events and function calls by the "Optimistic Oracle V2" contracts. The code can be found in packages/optimistic-oracle-v2
Note: L2 chains does not support callHandlers
. This means we cannot use callHandlers to index the setBond
, setCustomLiveness
, and setEventBased
function calls. These properties are also not available via events. Our compromise here is that in the case of L2 chains, we read this data from the contract state in the event handler instead. This workaround works when setCustomLiveness
and setEventBased
are called in the same transaction as requestPrice
. So it doesn't work for all cases. Ideally we should have callHandlers
in the chains that support this. We therefore must also remove the call handlers from the subgraph.yaml file for Polygon. See scripts/remove-call-handlers.js
for implementation.
- Mainnet
- TheGraph: https://thegraph.com/studio/subgraph/mainnet-optimistic-oracle-v2
- Goldsky: <>
- Polygon
- Arbitrum
- Optimism
- Boba
- TheGraph: https://thegraph.com/studio/subgraph/boba-optimistic-oracle-v2
- Goldsky:
- (staging) Core Testnet
- Core
- (testnet) Sepolia
- Base
- (staging) Base Sepolia
- Blast
- Story
This subgraph indexes events and function calls by the "Managed Optimistic Oracle V2" contracts. We reuse the code from packages/optimistic-oracle-v2
because the events emitted are the same.
- Amoy
- Polygon
This subgraph indexes events emitted by the ExpiringMultiParty and Perpetual contracts. The code can be found in packages/financial-contracts
- Mainnet
- TheGraph: https://thegraph.com/explorer/subgraph/umaprotocol/mainnet-contracts
- Goldsky:
- (staging) Mainnet
- TheGraph: https://thegraph.com/explorer/subgraph/nicholaspai/mainnet-contracts-staging
- Goldsky:
This subgraph indexes events emitted by the UMA voting token contracts. The code can be found in packages/token
- Mainnet
- TheGraph: https://thegraph.com/explorer/subgraph/umaprotocol/mainnet-token
- Goldsky:
- (staging) Mainnet
- TheGraph: https://thegraph.com/explorer/subgraph/nicholaspai/mainnet-token-staging
- Goldsky:
This subgraph indexes events emitted by the core Oracle contracts. The code can be found in packages/votingV2
- Mainnet
- (testnet) Sepolia
This subgraph indexes events emitted by the "Optimistic Oracle V3" contracts. The code can be found in packages/optimistic-oracle-v3
- Mainnet
- Polygon
- Arbitrum
- Optimism
- Boba
- TheGraph: https://thegraph.com/studio/subgraph/boba-optimistic-oracle-v3
- Goldsky:
- Avalanche
- TheGraph: https://thegraph.com/studio/subgraph/avalanche-optimistic-oracle-v3
- Goldsky:
- Gnosis
- TheGraph: https://thegraph.com/studio/subgraph/gnosis-optimistic-oracle-v3
- Goldsky:
- (staging) Core Testnet
- Core
- (testnet) Sepolia
- Base
- (testnet) Base Sepolia
- TheGraph: https://thegraph.com/studio/subgraph/base-sepolia-oo-v3
- Goldsky:
- Blast
- Story
This subgraph indexes events emitted by all the Optimistic Governor deployments.
- Mainnet
- Polygon
- Arbitrum
- Optimism
- Avalanche
- Gnosis
- (testnet) Goerli
- (staging) Core Testnet
- Core
- Base
- (testnet) Sepolia
-
Really well done subgraph repository: aragon/connect
-
Run a local graph node: graph-node