Skip to content
This repository has been archived by the owner on May 5, 2021. It is now read-only.

Commit

Permalink
Stop considering database errors as stop the bus errors; instead put …
Browse files Browse the repository at this point in the history
…command on end of queue and keep going
  • Loading branch information
hyandell committed Nov 2, 2018
1 parent 28d1349 commit 35f132f
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions github-sync-tng/sync.rb
Expand Up @@ -81,6 +81,16 @@ def eval_queue(queue, context, sync_db)
else
fail=fail+1
end
rescue Sequel::DatabaseError => msg
# Repository access blocked (Octokit::ClientError)
puts "Database error, pushing command back on queue: #{msg}"
queue.push(cmd)
if(fail > limit)
return_code=false
break
else
fail=fail+1
end
end

end
Expand Down

0 comments on commit 35f132f

Please sign in to comment.