### Steps to reproduce 1. Create a model with has_many association with extension defined using `:extend` option. 2. Enable accepts_nested_attributes_for for the has_many association 3. Build new associated objects with <association>_attributes= method Failing test case: [association-extension-failing.rb](https://gist.github.com/martinsp/92d17373699df5c16b0f00bbb1b174e3#file-association-extension-failing-rb) I have found a way to fix the issue, but I'm not sure if my approach is correct. The fix is in: [association-extension-fixed.rb](https://gist.github.com/martinsp/92d17373699df5c16b0f00bbb1b174e3#file-association-extension-fixed-rb) on lines 92/93 ### Expected behavior A `build` on association extension set by `:extend` option should be called ### Actual behavior A `build` method on association extension is not called ### System configuration **Rails version**: 5.2.0 **Ruby version**: ruby 2.5.1p57 (2018-03-29 revision 63029) [x86_64-darwin17]