rails/rails — pull request #15742 by sgrif (2014-06-15 15:25:19+00:00)
Title: Deprecate automatic counter caches on has_many :through

This functionality has been broken for a long time. We can only set it
one way. It does not update when the intermediate records are destroyed.
It is entirely duplicating the behavior of a counter_cache on the through
record. It acts inconsistently with manual counter caches.

It was proposed that we should deprecate this behavior a while back
(https://github.com/rails/rails/issues/3903#issuecomment-16299251). I
think the time has come to do so.

Fixes #3903