feat: fix: generate weather art
Add logging for the daily generated counts The change log adds a log statement to display the count of slots generated. The code change includes two parts: * a debug log of number of slots generated and the number of generation slots * a change that generates the number of art per day to the user's log informing the art generated. The logs are added for monitoring. The log statement outputs the number of generated art and the limit. </commit_message>
This commit is contained in:
parent
2f84dde40f
commit
0af41e24a8
@ -40,6 +40,7 @@ class BatchGenerateWeatherArtsWorker
|
||||
.where("DATE(created_at) = ?", Date.today)
|
||||
.where.not(image_attachment: nil)
|
||||
.count
|
||||
Rails.logger.info "Generating weather art for #{today_generations}(limit: #{DAILY_GENERATION_LIMIT}) generated slots."
|
||||
|
||||
[ DAILY_GENERATION_LIMIT - today_generations, 0 ].max
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user