Skip to content

Commit 6c66a91

Browse files
committed
chore: requested changes
1 parent 92f0247 commit 6c66a91

File tree

1 file changed

+1
-16
lines changed

1 file changed

+1
-16
lines changed

starter/src/index.js

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -27,21 +27,10 @@ Apify.main(async () => {
2727
checkerFinished: false,
2828
};
2929

30-
Apify.events.on('migrating', async () => {
31-
await Apify.setValue('STATE', state);
32-
});
33-
3430
Apify.events.on('persistState', async () => {
3531
await Apify.setValue('STATE', state);
3632
});
3733

38-
setInterval(async () => {
39-
await Apify.setValue('STATE', state);
40-
41-
log.debug('Internal state:');
42-
log.debug(inspect(state, false, 3));
43-
}, 10_000);
44-
4534
// If we haven't initialized the state yet, do it now
4635
if (state.runConfigurations.length === 0 && !state.checkerFinished) {
4736
state.runConfigurations = convertInputToActorConfigs(input);
@@ -83,16 +72,12 @@ Apify.main(async () => {
8372
);
8473
log.info(`You can monitor the status of the run by going to https://console.apify.com/actors/runs/${result.id}`);
8574
actorInput.runId = result.id;
86-
87-
// Save the state now
88-
// TODO(vladfrangu): ask Lukas if this is needed
89-
await Apify.setValue('STATE', state);
9075
}
9176

9277
// Wait for the run to finish
9378
await waitForRunToFinishAndPushData(actorInput);
9479
},
95-
handleRequestTimeoutSecs: 2_147_483_647,
80+
handleRequestTimeoutSecs: 2_147_483,
9681
});
9782

9883
// Run the checker

0 commit comments

Comments
 (0)