adamwiggins / clockwork

A scheduler process to replace cron
663 stars 185 forks source link

Numeric clash with ree-1.8.7-2010.02 / Rails 2.3.12 #5

Closed rslifka closed 7 years ago

rslifka commented 13 years ago

Hi Adam,

When dropping clockwork into our environment (before enabling it, just including the gem) we see some failures in our specs and a hard lock in one of them. When commenting out the Numeric freedom patch, these issues go away.

Doing a timeboxed investigation at the moment, just curious if this rings any bells, thanks!

Rob

rslifka commented 13 years ago

Looks like a collision with ActiveSupport::CoreExtensions::Numeric::Time. The methods there appear to do the same thing.

rslifka commented 13 years ago

Deleting Numeric from clockwork.rb while running clockwork_tests.rb under the rails 2.3.12 environment does the trick.

lukaskonarovsky commented 13 years ago

It is fixed in several forks of this gems, they basicly remove top-level Numeric class extension.

https://github.com/loe/clockwork/commit/7e4900d52294360aa2cb541ec0d481085824d58a

Ok, so I created somewhat smarter fix, where you can run test and extend Numeric only, when no other oxtension is present - https://github.com/daeltar/clockwork/commit/ff51d303cd3d27700f56b37a1df930032f215fd3

lukaskonarovsky commented 13 years ago

This can be closed (fix is present in v0.2.4).