Skip to content

Commit

Permalink
restored
Browse files Browse the repository at this point in the history
  • Loading branch information
akorchyn committed Mar 18, 2024
1 parent 17434f3 commit 61f8a19
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions snapshotter/stake.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ const processLockups = async (delegators) => {
.process(async (lockupAccount) => {
return pRetry(() => processLockup(lockupAccount).then((account_id) => {
return { lockupAccount, account_id };
}), { retries: 100, factor: 0, onFailedAttempt });
}), { retries: 100, factor: 0, onFailedAttempt, shouldRetry: (err) => !err.message.includes("doesn't exist") });
});

if (lockupErrors.length > 0) {
Expand Down Expand Up @@ -205,7 +205,7 @@ async function addToDatabase(client, accounts) {
}

const onFailedAttempt = (error) => {
if (error.attemptNumber > 5) {
if (error.attemptNumber > 20) {
console.log(`Failed attempt for ${error.attemptNumber}: ${error.message}$`)
}
};
Expand Down

0 comments on commit 61f8a19

Please sign in to comment.