Skip to content

Commit

Permalink
chore: bump ignition version to 0.15.7
Browse files Browse the repository at this point in the history
Signed-off-by: Tomás Migone <[email protected]>
  • Loading branch information
tmigone committed Nov 14, 2024
1 parent a256d74 commit ba40a74
Show file tree
Hide file tree
Showing 8 changed files with 74 additions and 50 deletions.
8 changes: 5 additions & 3 deletions packages/horizon/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,16 @@ Graph Horizon is the next evolution of the Graph Protocol.

## Deployment

We use Hardhat Ignition to deploy the contracts. To build and deploy the contracts run the following commands:
We use Hardhat Ignition to deploy the contracts. To build and deploy Graph Horizon run the following commands:

```bash
yarn install
yarn build
npx hardhat ignition deploy ./ignition/modules/horizon.ts \
--parameters ./ignition/configs/horizon.hardhat.json \
--parameters ./ignition/configs/horizon.hardhat.json5 \
--network hardhat
```

You can use any network defined in `hardhat.config.ts` by replacing `hardhat` with the network name.
You can use any network defined in `hardhat.config.ts` by replacing `hardhat` with the network name.

Note that this will deploy a standalone version of Graph Horizon contracts, meaning the Subgraph Service will not be deployed. If you want to deploy both please refer to the [Subgraph Service README](../subgraph-service/README.md) for deploy instructions.
Original file line number Diff line number Diff line change
@@ -1,37 +1,27 @@
{
"GraphProxyAdmin": {
"governor": "0xFFcf8FDEE72ac11b5c542428B35EEF5769C409f0"
},
"Controller": {
"$global": {
"governor": "0xFFcf8FDEE72ac11b5c542428B35EEF5769C409f0",
"pauseGuardian": "0x95cED938F7991cd0dFcb48F0a06a40FA1aF46EBC"
},
"RewardsManager": {
"pauseGuardian": "0x95cED938F7991cd0dFcb48F0a06a40FA1aF46EBC",
"subgraphAvailabilityOracle": "0xd03ea8624C8C5987235048901fB614fDcA89b117",
"issuancePerBlock": "114155251141552511415n",
// Placeholder address for a standalone Horizon deployment, see README.md for more detals
"subgraphServiceAddress": "0x0000000000000000000000000000000000000000"
},
"RewardsManager": {
"issuancePerBlock": "114155251141552511415n"
},
"EpochManager": {
"epochLength": 60
},
"GraphTokenGateway": {
"pauseGuardian": "0x95cED938F7991cd0dFcb48F0a06a40FA1aF46EBC"
},
"Curation": {
"curationTaxPercentage": 10000,
"minimumCurationDeposit": 1
},
"GraphToken": {
"initialSupply": "10000000000000000000000000000n",
"governor": "0xFFcf8FDEE72ac11b5c542428B35EEF5769C409f0"
"initialSupply": "10000000000000000000000000000n"
},
"HorizonStaking": {
"subgraphServiceAddress": "0x0000000000000000000000000000000000000000",
"maxThawingPeriod": 2419200
},
"HorizonStakingExtension": {
"subgraphServiceAddress": "0x0000000000000000000000000000000000000000"
},
"GraphPayments": {
"protocolPaymentCut": 10000
},
Expand Down
2 changes: 1 addition & 1 deletion packages/horizon/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"@nomicfoundation/hardhat-chai-matchers": "^2.0.0",
"@nomicfoundation/hardhat-ethers": "^3.0.8",
"@nomicfoundation/hardhat-foundry": "^1.1.1",
"@nomicfoundation/hardhat-ignition": "^0.15.5",
"@nomicfoundation/hardhat-ignition": "^0.15.7",
"@nomicfoundation/hardhat-ignition-ethers": "^0.15.5",
"@nomicfoundation/hardhat-network-helpers": "^1.0.0",
"@nomicfoundation/hardhat-toolbox": "^4.0.0",
Expand Down
16 changes: 0 additions & 16 deletions packages/horizon/scripts/deploy.ts

This file was deleted.

22 changes: 13 additions & 9 deletions packages/subgraph-service/README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
# Sample Hardhat Project
# 🌅 Subgraph Service 🌅

This project demonstrates a basic Hardhat use case. It comes with a sample contract, a test for that contract, and a script that deploys that contract.
The Subgraph Service is a data service designed to work with Graph Horizon that supports indexing subgraphs and serving queries to consumers.

Try running some of the following tasks:
## Deployment

```shell
npx hardhat help
npx hardhat test
REPORT_GAS=true npx hardhat test
npx hardhat node
npx hardhat run scripts/deploy.ts
We use Hardhat Ignition to deploy the contracts. To build and deploy the Subgraph Service run the following commands:

```bash
yarn install
yarn build
npx hardhat run scripts/deploy.ts --network hardhat
```

You can use any network defined in `hardhat.config.ts` by replacing `hardhat` with the network name.

Note that this will deploy and configure Graph Horizon contracts as well as the Subgraph Service.
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$global": {
"arbitrator": "0xFFcf8FDEE72ac11b5c542428B35EEF5769C409f0"
},
"DisputeManager": {
"arbitrator": "0xFFcf8FDEE72ac11b5c542428B35EEF5769C409f0",
"disputePeriod": 2419200,
"disputeDeposit": "10000000000000000000000n",
"fishermanRewardCut": 500000,
Expand Down
4 changes: 2 additions & 2 deletions packages/subgraph-service/scripts/deploy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ import SubgraphServiceProxiesModule from '../ignition/modules/Proxies'
// - Deploy SubgraphService and DisputeManager implementations
async function main() {
// TODO: Dynamically load config file based on the hardhat --network value
const HorizonConfig = removeNFromBigInts(require('@graphprotocol/horizon/ignition/configs/horizon.hardhat.json'))
const SubgraphServiceConfig = removeNFromBigInts(require('../ignition/configs/subgraph-service.hardhat.json'))
const HorizonConfig = removeNFromBigInts(require('@graphprotocol/horizon/ignition/configs/horizon.hardhat.json5'))
const SubgraphServiceConfig = removeNFromBigInts(require('../ignition/configs/subgraph-service.hardhat.json5'))

// Deploy proxies
const { DisputeManagerProxy, DisputeManagerProxyAdmin, SubgraphServiceProxy, SubgraphServiceProxyAdmin } = await ignition.deploy(SubgraphServiceProxiesModule)
Expand Down
44 changes: 43 additions & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2933,7 +2933,7 @@ __metadata:
"@nomicfoundation/hardhat-chai-matchers": "npm:^2.0.0"
"@nomicfoundation/hardhat-ethers": "npm:^3.0.8"
"@nomicfoundation/hardhat-foundry": "npm:^1.1.1"
"@nomicfoundation/hardhat-ignition": "npm:^0.15.5"
"@nomicfoundation/hardhat-ignition": "npm:^0.15.7"
"@nomicfoundation/hardhat-ignition-ethers": "npm:^0.15.5"
"@nomicfoundation/hardhat-network-helpers": "npm:^1.0.0"
"@nomicfoundation/hardhat-toolbox": "npm:^4.0.0"
Expand Down Expand Up @@ -4707,6 +4707,24 @@ __metadata:
languageName: node
linkType: hard

"@nomicfoundation/hardhat-ignition@npm:^0.15.7":
version: 0.15.7
resolution: "@nomicfoundation/hardhat-ignition@npm:0.15.7"
dependencies:
"@nomicfoundation/ignition-core": "npm:^0.15.7"
"@nomicfoundation/ignition-ui": "npm:^0.15.7"
chalk: "npm:^4.0.0"
debug: "npm:^4.3.2"
fs-extra: "npm:^10.0.0"
json5: "npm:^2.2.3"
prompts: "npm:^2.4.2"
peerDependencies:
"@nomicfoundation/hardhat-verify": ^2.0.1
hardhat: ^2.18.0
checksum: a5ed2b4fb862185d25c7b718faacafb23b818bc22c4c80c9bab6baaa228cf430196058a9374649de99dd831b98b9088b7b337ef44e4cadbf370d75a8a325ced9
languageName: node
linkType: hard

"@nomicfoundation/hardhat-network-helpers@npm:^1.0.0, @nomicfoundation/hardhat-network-helpers@npm:^1.0.9":
version: 1.0.10
resolution: "@nomicfoundation/hardhat-network-helpers@npm:1.0.10"
Expand Down Expand Up @@ -4779,13 +4797,37 @@ __metadata:
languageName: node
linkType: hard

"@nomicfoundation/ignition-core@npm:^0.15.7":
version: 0.15.7
resolution: "@nomicfoundation/ignition-core@npm:0.15.7"
dependencies:
"@ethersproject/address": "npm:5.6.1"
"@nomicfoundation/solidity-analyzer": "npm:^0.1.1"
cbor: "npm:^9.0.0"
debug: "npm:^4.3.2"
ethers: "npm:^6.7.0"
fs-extra: "npm:^10.0.0"
immer: "npm:10.0.2"
lodash: "npm:4.17.21"
ndjson: "npm:2.0.0"
checksum: b0d5717e7835da76595886e2729a0ee34536699091ad509b63fe2ec96b186495886c313c1c748dcc658524a5f409840031186f3af76975250be424248369c495
languageName: node
linkType: hard

"@nomicfoundation/ignition-ui@npm:^0.15.5":
version: 0.15.5
resolution: "@nomicfoundation/ignition-ui@npm:0.15.5"
checksum: 7d10e30c3078731e4feb91bd7959dfb5a0eeac6f34f6261fada2bf330ff8057ecd576ce0fb3fe856867af2d7c67f31bd75a896110b58d93ff3f27f04f6771278
languageName: node
linkType: hard

"@nomicfoundation/ignition-ui@npm:^0.15.7":
version: 0.15.7
resolution: "@nomicfoundation/ignition-ui@npm:0.15.7"
checksum: 4e53ff1e5267e9882ee3f7bae3d39c0e0552e9600fd2ff12ccc49f22436e1b97e9cec215999fda0ebcfbdf6db054a1ad8c0d940641d97de5998dbb4c864ce649
languageName: node
linkType: hard

"@nomicfoundation/solidity-analyzer-darwin-arm64@npm:0.1.1":
version: 0.1.1
resolution: "@nomicfoundation/solidity-analyzer-darwin-arm64@npm:0.1.1"
Expand Down

0 comments on commit ba40a74

Please sign in to comment.