Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

Array Extension Standalone

#3589

As referenced on the rails-core mailing list, doing a:

require 'activesupport/core_ext/array'

Does not require all the necessary components for all the extensions in activesupport to function correctly. This behaviour was tested on 2.3 and 3.0, yielding similar results:

irb(main):001:0> require 'active_support/array'
irb(main):002:0> [1].to_sentence
NameError: uninitialized constant Array::I18n

As you can see here, the array core extensions are not including I18n by default. Without it, to_sentence is broken.

Reported by Ryan Bigg · December 17th, 2009 @ 04:41 AM

State: committed
Milestone: 3.0.2
Assigned to: nobody
Importance: High

Activity

  1. Yehuda Katz (wycats)
    Yehuda Katz (wycats)
    • Milestone cleared.
    • Tag changed from activesupport to activesupport, standalone

    December 17th, 2009 @ 05:15 PM

  2. Xavier Noria
    Xavier Noria

    I am doing a systematic pass through AS core extensions checking this.

    December 20th, 2009 @ 12:39 AM

  3. Xavier Noria
    Xavier Noria

    I finished the pass and found about 30 missing requires.

    Jeremy just merged it, I think this ticket can be closed.

    January 1st, 2010 @ 10:45 PM

  4. Jeremy Kemper
    Jeremy Kemper
    • State changed from new to committed

    January 1st, 2010 @ 11:42 PM

  5. Jeremy Kemper
    Jeremy Kemper
    • Milestone set to 3.0.2
    • Importance changed from to High

    October 15th, 2010 @ 11:01 PM