Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 1.1.3 #501

Merged
merged 94 commits into from
Jul 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
94 commits
Select commit Hold shift + click to select a range
70a6524
Making the interface of params_builder more easy to use;
Jun 14, 2023
f642cdc
Fixing Lint error
Jun 14, 2023
a7cb537
Removing sender, recipient and from/to internal balance variables
Jun 15, 2023
bc4ad27
Merge remote-tracking branch 'origin/develop' into query-improvements
Jun 15, 2023
f68e4a9
Fixing "{" removed by mistake
Jun 16, 2023
6a17d8f
Updating Example, using Map instead of Object;
Jun 16, 2023
564d8cd
Initial addition of query contract. (Still has old functions remainin…
johngrantuk Jun 21, 2023
8f7e048
Remove Tenderly default config
brunoguerios Jun 21, 2023
f142077
Update tests
brunoguerios Jun 21, 2023
3453f55
Add GyroE V2 multicall.
johngrantuk Jun 22, 2023
2d6e800
Refactor/reorg.
johngrantuk Jun 22, 2023
a69c898
Add query contract to config.
johngrantuk Jun 22, 2023
16cc3cf
Switch to use new onchain method.
johngrantuk Jun 22, 2023
8e0b89d
Fix tests. Add global test block numbers.
johngrantuk Jun 22, 2023
23a72eb
Remove old multicall method.
johngrantuk Jun 22, 2023
16a7e6e
Fix lint.
johngrantuk Jun 22, 2023
7c13942
Update missing block numbers to global.
johngrantuk Jun 23, 2023
d2503c0
Updated multicall to ignore Managed pool.
johngrantuk Jul 1, 2023
a79d876
Merge pull request #478 from balancer/fix-mulicall
johngrantuk Jul 1, 2023
69629f4
chore: version bump v1.1.3-beta.0
johngrantuk Jul 1, 2023
16f6b71
Merge pull request #475 from balancer/remove-tenderly-default-config
johngrantuk Jul 5, 2023
7e86898
chore: version bump v1.1.3-beta.1
johngrantuk Jul 5, 2023
cd7a026
Fix merge conflict.
johngrantuk Jul 5, 2023
9673602
Update SOR to 4.1.1-beta.12.
johngrantuk Jul 5, 2023
fced123
Add FX pool to onchainData.
johngrantuk Jul 5, 2023
5ca9a3d
Use correct onchain method for FX.
johngrantuk Jul 5, 2023
2f4d803
Add Logger class.
johngrantuk Jul 5, 2023
e2541a9
Replace warnings with Logger.
johngrantuk Jul 5, 2023
b37e062
Replace console.logs with Logger.
johngrantuk Jul 5, 2023
184b22d
Fix up lints.
johngrantuk Jul 5, 2023
913c1d1
Merge pull request #481 from balancer/add-logger
johngrantuk Jul 6, 2023
0dabe3d
chore: version bump v1.1.3-beta.2
johngrantuk Jul 6, 2023
07cc3ec
Update Sepolia subgraph and multicall
timjrobinson Jul 6, 2023
7678e90
Enforce join and exit swap to happen only with weighted pools
brunoguerios Jul 6, 2023
d9a7e85
Merge pull request #483 from balancer/join-exit-hotfix
brunoguerios Jul 6, 2023
aaaa42f
chore: version bump v1.1.3-beta.3
johngrantuk Jul 6, 2023
da7b75d
Merge remote-tracking branch 'origin/develop' into balancer-pool-data…
brunoguerios Jul 7, 2023
ad5ce47
Replace console warn with logger warn
brunoguerios Jul 7, 2023
414cdba
Merge pull request #476 from balancer/balancer-pool-data-queries
brunoguerios Jul 7, 2023
5010799
chore: version bump v1.1.3-beta.4
johngrantuk Jul 7, 2023
ae8cfb5
Merge commit '50107999c837f6324ca3fddb4ac18f8fe9d4c923' into query-im…
Jul 7, 2023
b103ccb
Changing input of params_builder to map
Jul 7, 2023
f31cb6b
fixing prettier errors;
Jul 7, 2023
7be7c84
updating queries example;
Jul 10, 2023
9ac85d1
Merge pull request #473 from balancer/query-improvements
lgahdl Jul 10, 2023
2992c19
chore: version bump v1.1.3-beta.5
johngrantuk Jul 10, 2023
808abfd
Update BAL Address on Avalanche
timjrobinson Jul 12, 2023
e91e3d1
Merge remote-tracking branch 'origin/develop' into sor-update-4.1.1-b…
brunoguerios Jul 12, 2023
7d8eabc
Add protocolPercentFee as FX pool swapFee
brunoguerios Jul 12, 2023
f769d2e
adding config to hardhat nodes with zkevm network;
Jul 13, 2023
431e542
adding poolDataQueries address for goerli chain;
Jul 14, 2023
9844c15
Fixing logic check on getTokenPriceInNativeAsset function
Jul 17, 2023
605f231
Remove CS pool version check from join concern
brunoguerios Jul 17, 2023
be48f6b
Merge pull request #487 from balancer/add-goerli-pool-data-queries-ad…
brunoguerios Jul 17, 2023
a4cc843
chore: version bump v1.1.3-beta.6
johngrantuk Jul 17, 2023
8a06e46
Merge pull request #484 from balancer/update-bal-avalanche
brunoguerios Jul 17, 2023
f83d643
chore: version bump v1.1.3-beta.7
johngrantuk Jul 17, 2023
6b41579
Merge remote-tracking branch 'origin/develop' into feat/sepolia
brunoguerios Jul 17, 2023
3941002
Merge pull request #489 from balancer/composable-v5
brunoguerios Jul 17, 2023
657e2b4
chore: version bump v1.1.3-beta.8
johngrantuk Jul 17, 2023
19240b8
Merge pull request #482 from balancer/feat/sepolia
brunoguerios Jul 17, 2023
49d028e
chore: version bump v1.1.3-beta.9
johngrantuk Jul 17, 2023
a894740
Fixing lint;
Jul 17, 2023
1bd16e0
Merge pull request #488 from balancer/fix-get-token-price-native-asset
brunoguerios Jul 17, 2023
449da22
chore: version bump v1.1.3-beta.10
johngrantuk Jul 17, 2023
62facae
adding ZkEVM config to RPC_URL and FORK_NODES;
Jul 17, 2023
9062ed0
Merge pull request #486 from balancer/add-zkevm-hardhat-config
brunoguerios Jul 17, 2023
13abe78
chore: version bump v1.1.3-beta.11
johngrantuk Jul 17, 2023
aac90ec
Merge pull request #480 from balancer/sor-update-4.1.1-beta.12
brunoguerios Jul 18, 2023
ec97344
chore: version bump v1.1.3-beta.12
johngrantuk Jul 18, 2023
d3148ce
Sor update 4.1.1 beta.13
brunoguerios Jul 18, 2023
74529a0
Merge pull request #490 from balancer/sor-update-4.1.1-beta.13
brunoguerios Jul 18, 2023
006d0b7
chore: version bump v1.1.3-beta.13
johngrantuk Jul 18, 2023
0d9f8ca
fix: bump block number to pool helper contract deployment
gmbronco Jul 19, 2023
8e407da
Rolling back to use multicall instead of poolDataQueries contract;
Jul 19, 2023
eb43925
Redefining blocknumber to pass in the tests;
Jul 19, 2023
1a9a8f2
fix: swap example can use subset of pools
gmbronco Jul 19, 2023
9a3b79e
Merge pull request #493 from balancer/rollback-to-multicall
brunoguerios Jul 20, 2023
7b7aac5
chore: version bump v1.1.3-beta.14
johngrantuk Jul 20, 2023
01c12c3
Throw error when static result decode fails by any reason
brunoguerios Jul 21, 2023
2db644f
Ignore gyro pool
brunoguerios Jul 21, 2023
7b2bb26
Merge pull request #495 from balancer/generalised-join-overflow
johngrantuk Jul 24, 2023
8745ba6
Merge pull request #496 from balancer/ignore-gyro-pool
johngrantuk Jul 24, 2023
8f830e9
chore: version bump v1.1.3-beta.15
johngrantuk Jul 24, 2023
0834d9a
adding subgraph urls on optimism
gmbronco Jul 24, 2023
719981b
prettified examples
gmbronco Jul 24, 2023
084276c
Merge pull request #497 from balancer/optimism-config
johngrantuk Jul 25, 2023
8815d04
chore: version bump v1.1.3-beta.16
johngrantuk Jul 25, 2023
f0493a2
Add gauge SG and example.
Jul 26, 2023
ab0a0a1
Merge pull request #498 from balancer/avalanche-gauges
johngrantuk Jul 26, 2023
512b460
chore: version bump v1.1.3-beta.17
johngrantuk Jul 26, 2023
0c9e559
Merge pull request #492 from balancer/examples-fix
johngrantuk Jul 28, 2023
cea2eae
chore: version bump v1.1.3-beta.18
johngrantuk Jul 28, 2023
e727a97
Update version to 1.1.3 for release.
johngrantuk Jul 28, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion balancer-js/.eslintignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
node_modules
dist
examples
**/generated
10 changes: 5 additions & 5 deletions balancer-js/examples/contracts/veBAL-proxy.ts
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
/**
* This example shows how to the adjusted veBAL balance from the active boost delegation contract
*
*
* How to run:
* yarn run example examples/contracts/veBAL-proxy.ts
*/
import { BalancerSDK, Network } from '@balancer-labs/sdk';

const sdk = new BalancerSDK({
network: Network.GOERLI,
rpcUrl: 'https://rpc.ankr.com/eth_goerli'
const sdk = new BalancerSDK({
network: Network.GOERLI,
rpcUrl: 'https://rpc.ankr.com/eth_goerli',
});

const { veBalProxy } = sdk.contracts;

async function main() {
const USER = "0x91F450602455564A64207414c7Fbd1F1F0EbB425";
const USER = '0x91F450602455564A64207414c7Fbd1F1F0EbB425';
const balance = await veBalProxy?.getAdjustedBalance(USER);
console.log("User's veBAL adjusted balance", balance);
}
Expand Down
8 changes: 4 additions & 4 deletions balancer-js/examples/contracts/veBAL.ts
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
/**
* Shows how to interact with the veBAL contract
*
*
* How to run:
* yarn run example examples/contracts/veBAL.ts
*/
import { BalancerSDK, Network } from '@balancer-labs/sdk';

const sdk = new BalancerSDK({
network: Network.GOERLI,
rpcUrl: 'https://rpc.ankr.com/eth_goerli'
rpcUrl: 'https://rpc.ankr.com/eth_goerli',
});

const { veBal } = sdk.contracts;

async function main() {
if (!veBal) throw new Error('veBal address must be defined');

const USER = "0x91F450602455564A64207414c7Fbd1F1F0EbB425";
const USER = '0x91F450602455564A64207414c7Fbd1F1F0EbB425';

const lockInfo = await veBal.getLockInfo(USER);
console.log("veBAL lock info for user", lockInfo);
console.log('veBAL lock info for user', lockInfo);
}

main();
20 changes: 12 additions & 8 deletions balancer-js/examples/data/fee-distributor.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
/**
* This example shows how to use the FeeDistributor contract to claim rewards
*
*
* How to run:
* yarn example examples/data/fee-distributor.ts
*/
import { BalancerSDK, Network } from "@balancer-labs/sdk";
import { BalancerSDK, Network } from '@balancer-labs/sdk';

const sdk = new BalancerSDK({
network: Network.MAINNET,
rpcUrl: 'https://rpc.ankr.com/eth'
rpcUrl: 'https://rpc.ankr.com/eth',
});

const { feeDistributor } = sdk.data;
Expand All @@ -22,15 +22,19 @@ const claimableTokens: string[] = [
const userAddress = '0x549c660ce2B988F588769d6AD87BE801695b2be3';

(async function () {
if (!feeDistributor) throw new Error("feeDistributor not defined");
const data = await feeDistributor.getClaimableBalances(userAddress, claimableTokens);
if (!feeDistributor) throw new Error('feeDistributor not defined');
const data = await feeDistributor.getClaimableBalances(
userAddress,
claimableTokens
);
console.table(data);

const callData = feeDistributor.claimBalances(userAddress, claimableTokens);
console.log(`Encoded Callable: ${callData.slice(0, 10)}...${callData.slice(-5)}`);
console.log(
`Encoded Callable: ${callData.slice(0, 10)}...${callData.slice(-5)}`
);
console.log(`
const tx = { to: '${sdk.networkConfig.addresses.contracts.feeDistributor}', data: callData };
const receipt = await (await signer.sendTransaction(tx)).wait();
`)

`);
})();
16 changes: 9 additions & 7 deletions balancer-js/examples/data/gauge-shares.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,19 @@ import { BalancerSDK, Network } from '@balancer-labs/sdk';

const sdk = new BalancerSDK({
network: Network.MAINNET,
rpcUrl: ''
rpcUrl: '',
});

const { gaugeShares } = sdk.data;

(async function() {
(async function () {
if (!gaugeShares) throw 'Gauge Subgraph must be initialized';

const USER_ADDR = '0x00676e437f1945b85ec3a3c90aae35e0352115ed';
const GAUGE_ID = '0xc5f8b1de80145e3a74524a3d1a772a31ed2b50cc';
const GAUGESHARE_ID = `${USER_ADDR}-${GAUGE_ID}`;
const GAUGESHARE_ID2 = "0x79c17982020abb9a2214aa952308e104e5840e2d-0xc5f8b1de80145e3a74524a3d1a772a31ed2b50cc";
const GAUGESHARE_ID2 =
'0x79c17982020abb9a2214aa952308e104e5840e2d-0xc5f8b1de80145e3a74524a3d1a772a31ed2b50cc';

let result;

Expand All @@ -31,12 +32,13 @@ const { gaugeShares } = sdk.data;

result = await gaugeShares.findByGauge(GAUGE_ID, 5);
console.log('Gauge shares by gauge (first 5)', result);

result = await gaugeShares.findByGauge(GAUGE_ID, 2, 1);
console.log('Gauge shares by gauge (#2 & #3)', result);

result = await gaugeShares.query({ where: { id_in: [ GAUGESHARE_ID, GAUGESHARE_ID2 ] }});
console.log('Gauge shares subgraph query', result);
result = await gaugeShares.query({
where: { id_in: [GAUGESHARE_ID, GAUGESHARE_ID2] },
});
console.log('Gauge shares subgraph query', result);
// Gauges subgraph : https://thegraph.com/hosted-service/subgraph/balancer-labs/balancer-gauges

})();
12 changes: 8 additions & 4 deletions balancer-js/examples/data/liquidity-gauges.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/**
* Example retrieves all the gauges for the pools and shows one example with BAL and one example with BAL and another reward token (LIDO)
*
*
* Run with:
* yarn example ./examples/data/liquidity-gauges.ts
*/
import { BalancerSDK, Network } from "@balancer-labs/sdk";
import { BalancerSDK, Network } from '@balancer-labs/sdk';

const sdk = new BalancerSDK({
network: Network.ARBITRUM,
Expand All @@ -16,6 +16,10 @@ const { liquidityGauges } = sdk.data;
if (!liquidityGauges) throw 'Gauge Subgraph must be initialized';
const gauges = await liquidityGauges.fetch();
console.log(`Gauges: `, gauges.length);
console.log(gauges.find((it) => it.id === '0x914ec5f93ccd6362ba925bedd0bd68107b85d2ca'));
console.log(gauges.find((it) => it.id === '0xcf9f895296f5e1d66a7d4dcf1d92e1b435e9f999'));
console.log(
gauges.find((it) => it.id === '0x914ec5f93ccd6362ba925bedd0bd68107b85d2ca')
);
console.log(
gauges.find((it) => it.id === '0xcf9f895296f5e1d66a7d4dcf1d92e1b435e9f999')
);
})();
30 changes: 16 additions & 14 deletions balancer-js/examples/data/pool-shares.ts
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
/**
* Example of using the poolShares data source
*
*
* Run with:
* yarn example ./examples/data/pool-shares.ts
*/
import { BalancerSDK, Network } from '@balancer-labs/sdk';

const sdk = new BalancerSDK(
{
network: Network.MAINNET,
rpcUrl: ''
});
const sdk = new BalancerSDK({
network: Network.MAINNET,
rpcUrl: '',
});
const { poolShares } = sdk.data;

(async function() {

const POOLSHARE_ID = '0x01abc00e86c7e258823b9a055fd62ca6cf61a163-0x2da1bcb14be26be6812e0e871e8dc4f4c0d92629';
const POOL_ID = '0x01abc00e86c7e258823b9a055fd62ca6cf61a16300010000000000000000003b'
(async function () {
const POOLSHARE_ID =
'0x01abc00e86c7e258823b9a055fd62ca6cf61a163-0x2da1bcb14be26be6812e0e871e8dc4f4c0d92629';
const POOL_ID =
'0x01abc00e86c7e258823b9a055fd62ca6cf61a16300010000000000000000003b';
const USER_ADDR = '0xba12222222228d8ba445958a75a0704d566bf2c8';

let result;

result = await poolShares.find(POOLSHARE_ID);
Expand All @@ -35,9 +35,11 @@ const { poolShares } = sdk.data;

result = await poolShares.findByPool(POOL_ID, 2, 1);
console.log('Pool shares by pool (#2 & #3)', result);

result = await poolShares.query({ where: { poolId: POOL_ID, balance_gt: '0' }, first: 3 });

result = await poolShares.query({
where: { poolId: POOL_ID, balance_gt: '0' },
first: 3,
});
console.log('Pool shares subgraph query', result);
// Balancer subgraph : https://thegraph.com/hosted-service/subgraph/balancer-labs/balancer-v2

})();
30 changes: 17 additions & 13 deletions balancer-js/examples/data/pools.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
import { BalancerSDK, Network } from '@balancer-labs/sdk';

const sdk = new BalancerSDK({
network: Network.MAINNET,
rpcUrl: 'https://rpc.ankr.com/eth'
const sdk = new BalancerSDK({
network: Network.MAINNET,
rpcUrl: 'https://rpc.ankr.com/eth',
});

const { pools, poolsOnChain } = sdk.data;

async function main() {

const POOL_ID1 = '0x2d011adf89f0576c9b722c28269fcb5d50c2d17900020000000000000000024d';
const POOL_ID2 = '0x4aa462d59361fc0115b3ab7e447627534a8642ae000100000000000000000158';
const POOL_IDs = [ POOL_ID1, POOL_ID2 ];
const POOL_ID1 =
'0x2d011adf89f0576c9b722c28269fcb5d50c2d17900020000000000000000024d';
const POOL_ID2 =
'0x4aa462d59361fc0115b3ab7e447627534a8642ae000100000000000000000158';
const POOL_IDs = [POOL_ID1, POOL_ID2];

let result;

Expand All @@ -21,18 +22,21 @@ async function main() {
result = await pools.all();
console.log('Fetch all pools', result);

result = await pools.where(pool => POOL_IDs.includes(pool.id));
result = await pools.where((pool) => POOL_IDs.includes(pool.id));
console.log('Filter pools by attributes', result);

// Fefetch on-chain balances for a given pool
// Refetch on-chain balances for a given pool
const pool = await pools.find(POOL_ID1);
for (const idx in pool!.tokens) {
pool!.tokens[idx].balance = '0';
if (!pool) {
throw new Error('Pool not found');
}
for (const idx in pool.tokens) {
pool.tokens[idx].balance = '0';
}
const onchain = await poolsOnChain.refresh(pool!);
const onchain = await poolsOnChain.refresh(pool);
console.log('onchain pool', onchain);
}

main();

// yarn example ./examples/data/pools.ts
// yarn example ./examples/data/pools.ts
13 changes: 12 additions & 1 deletion balancer-js/examples/data/token-prices.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,18 @@ const tetuBal = '0x7fc9e0aa043787bfad28e29632ada302c790ce33';

(async () => {
// It will be just one request to coingecko
const ps = [eth, weth, dai, ohm, tetuBal, matic, eth, dai, tetuBal, matic].map((t) => data.tokenPrices.find(t));
const ps = [
eth,
weth,
dai,
ohm,
tetuBal,
matic,
eth,
dai,
tetuBal,
matic,
].map((t) => data.tokenPrices.find(t));
const price = await Promise.all(ps);

console.log(price);
Expand Down
44 changes: 22 additions & 22 deletions balancer-js/examples/helpers/erc20.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { hexlify, zeroPad } from '@ethersproject/bytes'
import { keccak256 } from '@ethersproject/solidity'
import { BigNumber } from '@ethersproject/bignumber'
import { Contract } from '@ethersproject/contracts'
import { JsonRpcProvider, JsonRpcSigner } from '@ethersproject/providers'
import { hexlify, zeroPad } from '@ethersproject/bytes';
import { keccak256 } from '@ethersproject/solidity';
import { BigNumber } from '@ethersproject/bignumber';
import { Contract } from '@ethersproject/contracts';
import { JsonRpcProvider, JsonRpcSigner } from '@ethersproject/providers';

/**
* Set token balance for a given account
Expand All @@ -23,14 +23,16 @@ export const setTokenBalance = async (
isVyperMapping = false
): Promise<void> => {
// Get storage slot index
const slotFormat = isVyperMapping ? [slot, account] : [account, slot]
const slotValue = keccak256(['uint256', 'uint256'], slotFormat)
const slotFormat = isVyperMapping ? [slot, account] : [account, slot];
const slotValue = keccak256(['uint256', 'uint256'], slotFormat);

// Manipulate local balance (needs to be bytes32 string)
const value = hexlify(zeroPad(BigNumber.from(String(BigInt(balance))).toHexString(), 32))
const value = hexlify(
zeroPad(BigNumber.from(String(BigInt(balance))).toHexString(), 32)
);

await provider.send('hardhat_setStorageAt', [token, slotValue, value])
}
await provider.send('hardhat_setStorageAt', [token, slotValue, value]);
};

/**
* Approve token balance for vault contract
Expand All @@ -48,17 +50,15 @@ export const approveToken = async (
): Promise<boolean> => {
const iERC20 = [
'function approve(address spender, uint256 amount) external returns (bool)',
]
const erc20 = new Contract(token, iERC20, signer)
const txReceipt = await (
await erc20.approve(spender, amount)
).wait()
return txReceipt.status === 1
}
];
const erc20 = new Contract(token, iERC20, signer);
const txReceipt = await (await erc20.approve(spender, amount)).wait();
return txReceipt.status === 1;
};

/**
* Get ERC20 token balance for a given account
*
*
* @param token Token address to get balance of
* @param account Account to get balance for
* @param provider JsonRpcProvider
Expand All @@ -71,7 +71,7 @@ export const getTokenBalance = async (
): Promise<string> => {
const iERC20 = [
'function balanceOf(address account) external view returns (uint256)',
]
const erc20 = new Contract(token, iERC20, provider)
return erc20.balanceOf(account)
}
];
const erc20 = new Contract(token, iERC20, provider);
return erc20.balanceOf(account);
};
14 changes: 9 additions & 5 deletions balancer-js/examples/helpers/forked-utils.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,21 @@
import { JsonRpcProvider } from '@ethersproject/providers'
import { JsonRpcProvider } from '@ethersproject/providers';

/**
* Resets the fork to a given block number
*
* @param provider JsonRpcProvider
* @param blockNumber Block number to reset fork to
*/
export const reset = (provider: JsonRpcProvider, blockNumber: number, jsonRpcUrl = 'https://rpc.ankr.com/eth'): Promise<void> =>
export const reset = (
provider: JsonRpcProvider,
blockNumber?: number,
jsonRpcUrl = 'https://rpc.ankr.com/eth'
): Promise<void> =>
provider.send('hardhat_reset', [
{
forking: {
jsonRpcUrl,
blockNumber
}
}
blockNumber,
},
},
]);
Loading
Loading