floraison / et-orbi

Time zones for fugit and rufus-scheduler. Urbi et Orbi.
MIT License
24 stars 11 forks source link

stack level too deep in `now` on Windows #12

Closed jmettraux closed 6 years ago

jmettraux commented 6 years ago

As reported for rufus-scheduler at https://github.com/jmettraux/rufus-scheduler/issues/269

Reproduced on Appveyor at https://ci.appveyor.com/project/jmettraux/et-orbi/build/job/p80wb2e7flbbd6oo?fullLog=true#L202 :

[00:00:17]   2) EtOrbi.make_time turns a Date instance into an EoTime instance
[00:00:17]      Failure/Error:
[00:00:17]        tabbs = (-6..5)
[00:00:17]          .collect { |i| (Time.now + i * 30 * 24 * 3600).zone }
[00:00:17]          .uniq
[00:00:17]          .sort
[00:00:17]          .join('|')
[00:00:17] 
[00:00:17]      SystemStackError:
[00:00:17]        stack level too deep
[00:00:17]      # ./lib/et-orbi.rb:697:in `now'
[00:00:17]      # ./lib/et-orbi.rb:697:in `block in determine_local_tzones'
[00:00:17]      # ./lib/et-orbi.rb:697:in `each'
[00:00:17]      # ./lib/et-orbi.rb:697:in `collect'
[00:00:17]      # ./lib/et-orbi.rb:697:in `determine_local_tzones'
[00:00:17]      # ./lib/et-orbi.rb:630:in `determine_local_tzone'
[00:00:17]      # ./lib/et-orbi.rb:146:in `get_tzone'
[00:00:17]      # ./lib/et-orbi.rb:262:in `get_tzone'
[00:00:17]      # ./lib/et-orbi.rb:300:in `initialize'
[00:00:17]      # ./lib/et-orbi.rb:19:in `new'
[00:00:17]      # ./lib/et-orbi.rb:19:in `now'
[00:00:17]      # ./lib/et-orbi.rb:252:in `now'
[00:00:17]      # ./lib/et-orbi.rb:188:in `platform_info'
[00:00:17]      # ./lib/et-orbi.rb:305:in `initialize'
[00:00:17]      # ./lib/et-orbi.rb:19:in `new'
[00:00:17]      # ./lib/et-orbi.rb:19:in `now'
[00:00:17]      # ./lib/et-orbi.rb:252:in `now'
[00:00:17]      # ./lib/et-orbi.rb:188:in `platform_info'
[00:00:17]      # ...

for

[00:00:17] rspec './spec/module_spec.rb[1:8:6]' # EtOrbi.make_time turns a Date instance into an EoTime instance