From 19edcf46052bd673cfd4ca08d9b46523654e1cac Mon Sep 17 00:00:00 2001 From: Miles Zhang Date: Fri, 10 Jan 2025 11:51:27 +0900 Subject: [PATCH] fix: remove rescue error in sidekiq job (#2401) Signed-off-by: Miles Zhang --- app/services/charts/daily_statistic_generator.rb | 2 -- app/workers/charts/daily_statistic.rb | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/app/services/charts/daily_statistic_generator.rb b/app/services/charts/daily_statistic_generator.rb index 80b7ac6e3..af106b6cd 100644 --- a/app/services/charts/daily_statistic_generator.rb +++ b/app/services/charts/daily_statistic_generator.rb @@ -16,8 +16,6 @@ def call daily_statistic.from_scratch = from_scratch daily_statistic.reset!(updated_attrs) daily_statistic - rescue StandardError => e - Rails.logger.error "Error occurred during DailyStatisticGenerator error: #{e.message}" end private diff --git a/app/workers/charts/daily_statistic.rb b/app/workers/charts/daily_statistic.rb index d6010e453..6435d68f9 100644 --- a/app/workers/charts/daily_statistic.rb +++ b/app/workers/charts/daily_statistic.rb @@ -1,7 +1,7 @@ module Charts class DailyStatistic include Sidekiq::Worker - sidekiq_options queue: "critical", backtrace: 20 + sidekiq_options queue: "critical" # iterate from the creation timestamp of last daily statistic record to now day by day # and generate daily statistic record for each day