statsample icon indicating copy to clipboard operation
statsample copied to clipboard

statsample override of array#sum conflicts with gem activerecord-import

Open lentesta opened this issue 2 years ago • 1 comments

In debugging this issue with activerecord-import, it appears that statsample overrides Array in a way that breaks activerecord-import.

That issue contains a small sample program that reproduces the issue. It seems specific to Array#sum.

The temporary solution I have is to monkey patch the insert_many method in ActiveRecord::Import::MysqlAdapter.

I think the long-term solution would be a fix in statsample. Happy to help with this, if needed.

lentesta avatar Jul 05 '22 22:07 lentesta

Yeah, this gem breaks rails. Don't use until this gets fixed.

HansHauge avatar Mar 14 '24 21:03 HansHauge