@@ -254,7 +254,7 @@ export const main = async (_config, _options, justKill) => {
254
254
await awaitCommand ( 'deploy' , config . deployCommand )
255
255
256
256
// wait for anvil deploy to finish
257
- await new Promise ( ( resolve ) => setTimeout ( resolve , 5000 ) )
257
+ await new Promise ( ( resolve ) => setTimeout ( resolve , 100 ) )
258
258
259
259
// remove block timestamp interval after deploy
260
260
await rpcFetch ( 'anvil_removeBlockTimestampInterval' , [ ] )
@@ -283,7 +283,14 @@ export const main = async (_config, _options, justKill) => {
283
283
284
284
if ( options . graph ) {
285
285
try {
286
- await compose . upAll ( opts )
286
+ console . log ( 'Starting postgres...' )
287
+ await compose . upOne ( 'postgres' , opts )
288
+ console . log ( 'Starting ipfs...' )
289
+ await compose . upOne ( 'ipfs' , opts )
290
+ console . log ( 'Starting graph-node...' )
291
+ await compose . upOne ( 'graph-node' , opts )
292
+ console . log ( 'Starting metadata...' )
293
+ // await compose.upOne('metadata', opts)
287
294
} catch { }
288
295
289
296
await waitOn ( { resources : [ 'http://localhost:8040' ] } )
@@ -372,13 +379,19 @@ export const main = async (_config, _options, justKill) => {
372
379
} )
373
380
. catch ( ( ) => 0 )
374
381
do {
382
+ const index = await getCurrentIndex ( )
383
+ console . log ( 'current index:' , index )
375
384
indexArray . push ( await getCurrentIndex ( ) )
376
385
if ( indexArray . length > 10 ) indexArray . shift ( )
377
- await new Promise ( ( resolve ) => setTimeout ( resolve , 100 ) )
386
+ await new Promise ( ( resolve ) => setTimeout ( resolve , 1000 ) )
387
+ if ( indexArray . every ( ( i ) => i === indexArray [ 0 ] ) && indexArray . length === 10 ) {
388
+ return cleanup ( undefined , 0 )
389
+ }
378
390
} while (
379
- ! indexArray . every ( ( i ) => i === indexArray [ 0 ] ) ||
380
- indexArray . length < 2 ||
381
- indexArray [ 0 ] === 0
391
+ indexArray [ indexArray . length - 1 ] < 326
392
+ // !indexArray.every((i) => i === indexArray[0]) ||
393
+ // indexArray.length < 2 ||
394
+ // indexArray[0] === 0
382
395
)
383
396
}
384
397
/**
0 commit comments