File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -9,12 +9,12 @@ import {
9
9
DisputeKitClassic ,
10
10
ChainlinkRNG ,
11
11
} from "../typechain-types" ;
12
- import request from "graphql-request" ;
13
12
import env from "./utils/env" ;
14
13
import loggerFactory from "./utils/logger" ;
15
14
import { toBigInt , BigNumberish , getNumber } from "ethers" ;
16
15
import hre = require( "hardhat" ) ;
17
16
17
+ let request : < T > ( url : string , query : string ) => Promise < T > ; // Workaround graphql-request ESM import
18
18
const { ethers } = hre ;
19
19
const MAX_DRAW_ITERATIONS = 30 ;
20
20
const MAX_EXECUTE_ITERATIONS = 20 ;
@@ -478,6 +478,8 @@ const sendHeartbeat = async () => {
478
478
} ;
479
479
480
480
async function main ( ) {
481
+ const graphqlRequest = await import ( "graphql-request" ) ; // Workaround graphql-request ESM import
482
+ request = graphqlRequest . request ;
481
483
const { core, sortition, disputeKitClassic } = await getContracts ( ) ;
482
484
483
485
const getBlockTime = async ( ) => {
You can’t perform that action at this time.
0 commit comments