@headius here’s your script: ```ruby require 'biz' ​ class BizThreadLeak def self.biz_schedule Biz::Schedule.new do |config| config.hours = { mon: { '00:00' => '00:01' } } config.time_zone = "Europe/Paris" end end ​ def self.time_segments(earliest_start, latest_end) biz_schedule .periods .after(earliest_start) .timeline .until(latest_end) .to_a end end ​ DAYS_IN_SECONDS = 86400 # 24 * 60 * 60 ​ ​ ​ earliest_start = Time.now latest_end = Time.now + (15 * DAYS_IN_SECONDS) ​ ​ loop do res = BizThreadLeak.time_segments(earliest_start, latest_end) puts "res is : #{res}" sleep 1 end ```